ssb: Remove log noise.
All checks were successful
Build Tilde Friends / Build-All (push) Successful in 8m43s
All checks were successful
Build Tilde Friends / Build-All (push) Successful in 8m43s
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"type": "tildefriends-app",
|
||||
"emoji": "🦀",
|
||||
"previous": "&HrNj+ya8UIHQIy0MgoaKBcW+MU56iKLqpNpOnUiKTZg=.sha256"
|
||||
"previous": "&W1tVCm6k+sTaIprqugaZlifh/FPQWCqGXXHn1hojCHI=.sha256"
|
||||
}
|
||||
|
||||
@@ -79,11 +79,13 @@ tfrpc.register(async function query(sql, args, options) {
|
||||
}
|
||||
}
|
||||
let end = new Date();
|
||||
print(
|
||||
(end - start) / 1000,
|
||||
entry ? 'from cache' : 'from db',
|
||||
sql.replaceAll(/\s+/g, ' ').trim()
|
||||
);
|
||||
if (end - start > 1000) {
|
||||
print(
|
||||
(end - start) / 1000,
|
||||
entry ? 'from cache' : 'from db',
|
||||
sql.replaceAll(/\s+/g, ' ').trim()
|
||||
);
|
||||
}
|
||||
return result;
|
||||
});
|
||||
tfrpc.register(async function appendMessage(id, message) {
|
||||
|
||||
@@ -435,7 +435,6 @@ class TfElement extends LitElement {
|
||||
}
|
||||
|
||||
async load_channels_latest(following) {
|
||||
let start_time = new Date();
|
||||
let latest_private = this.get_latest_private(following);
|
||||
const k_args = [
|
||||
JSON.stringify(this.channels),
|
||||
@@ -510,9 +509,7 @@ class TfElement extends LitElement {
|
||||
}
|
||||
}
|
||||
this.channels_latest = latest;
|
||||
console.log('channels took', (new Date() - start_time) / 1000.0);
|
||||
let self = this;
|
||||
start_time = new Date();
|
||||
latest_private.then(async function (latest) {
|
||||
let grouped = await self.group_private_messages(latest[1]);
|
||||
self.channels_latest = Object.assign({}, self.channels_latest, {
|
||||
@@ -520,7 +517,6 @@ class TfElement extends LitElement {
|
||||
});
|
||||
self.private_messages = latest[1];
|
||||
self.grouped_private_messages = grouped;
|
||||
console.log('private took', (new Date() - start_time) / 1000.0);
|
||||
});
|
||||
}
|
||||
|
||||
@@ -597,7 +593,6 @@ class TfElement extends LitElement {
|
||||
this.loading_latest = true;
|
||||
this.reset_progress();
|
||||
try {
|
||||
let start_time = new Date();
|
||||
let whoami = this.whoami;
|
||||
let following = await tfrpc.rpc.following([whoami], 2);
|
||||
let old_users = this.users ?? {};
|
||||
@@ -622,30 +617,13 @@ class TfElement extends LitElement {
|
||||
(await tfrpc.rpc.databaseGet('unread')) ?? '{}'
|
||||
);
|
||||
this.following = Object.keys(following);
|
||||
let about_start_time = new Date();
|
||||
start_time = new Date();
|
||||
users = await this.fetch_user_info(users);
|
||||
console.log(
|
||||
'user info took',
|
||||
(new Date() - start_time) / 1000.0,
|
||||
'seconds'
|
||||
);
|
||||
this.users = users;
|
||||
|
||||
let self = this;
|
||||
this.fetch_about(following, users).then(function (result) {
|
||||
self.users = result;
|
||||
console.log(
|
||||
'about took',
|
||||
(new Date() - about_start_time) / 1000.0,
|
||||
'seconds for',
|
||||
Object.keys(users).length,
|
||||
'users'
|
||||
);
|
||||
});
|
||||
console.log(
|
||||
`load finished ${whoami} => ${this.whoami} in ${(new Date() - start_time) / 1000}`
|
||||
);
|
||||
await reactions;
|
||||
this.whoami = whoami;
|
||||
this.loaded = whoami;
|
||||
|
||||
@@ -37,8 +37,6 @@ class TfNewsElement extends LitElement {
|
||||
let self = this;
|
||||
let messages_by_id = {};
|
||||
|
||||
console.log('processing', messages.length, 'messages');
|
||||
|
||||
function ensure_message(id, rowid) {
|
||||
let found = messages_by_id[id];
|
||||
if (found) {
|
||||
|
||||
@@ -396,7 +396,6 @@ class TfTabNewsFeedElement extends LitElement {
|
||||
)
|
||||
)
|
||||
);
|
||||
console.log('done loading latest messages.');
|
||||
}
|
||||
|
||||
async load_messages() {
|
||||
@@ -434,9 +433,6 @@ class TfTabNewsFeedElement extends LitElement {
|
||||
this.messages = this.merge_messages(this.messages, messages);
|
||||
}
|
||||
this.time_loading = undefined;
|
||||
console.log(
|
||||
`loading ${messages.length} messages done for ${self.whoami} in ${(new Date() - start_time) / 1000}s`
|
||||
);
|
||||
}
|
||||
|
||||
mark_all_read() {
|
||||
|
||||
Reference in New Issue
Block a user