mirror of
https://github.com/thegeneralist01/archivr
synced 2026-07-22 03:05:32 +02:00
fix(core+frontend): exclude avatar blobs from tweet % cached display
tweet/tweet_thread entries have avatar artifacts that are always deduplicated from the first capture of each author. Counting them in the cached-bytes percentage makes it artificially high (or incorrect when the real media content is new but avatars are cached). database.rs: - refresh_entry_cached_bytes: AND ea.artifact_role != 'avatar' - cascade_cached_bytes_after_delete: same filter - cascade_cached_bytes_after_subtree_delete: same filter - Initial cached_bytes migration: same filter - Re-migration (else branch): recomputes cached_bytes for existing entries that have avatar artifacts, scoped to only those entries archive.rs: - EntrySummary gains cacheable_bytes: i64 — non-avatar total bytes, computed inline in every SQL query as the denominator for % cached - ENTRY_SELECT_COLS adds cacheable_bytes at index 13 (with children subquery, same as total_artifact_bytes) - list_root_entries adds same expression - All 6 row-mapping closures include cacheable_bytes: row.get(13)? EntryRow.jsx: - SIZE display stays: formatBytes(entry.total_artifact_bytes) - % cached badge uses cacheable_bytes as denominator: cached_bytes / cacheable_bytes * 100
This commit is contained in:
parent
916146b4a8
commit
b8cec96256
5 changed files with 49 additions and 7 deletions
|
|
@ -4,7 +4,7 @@
|
|||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>Archivr</title>
|
||||
<script type="module" crossorigin src="/assets/index-BlDAGZHO.js"></script>
|
||||
<script type="module" crossorigin src="/assets/index-C9dla3pB.js"></script>
|
||||
<link rel="stylesheet" crossorigin href="/assets/index-D8ic-z4p.css">
|
||||
</head>
|
||||
<body>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue