chore(assets): drop vestigial tags.tag_type column (#14248)

tag_type was always "user" in practice — no code path ever set it to anything
else (no system/seeded classification was wired up) and nothing queried it. The
column, its ix_tags_tag_type index, and the TagUsage.type API field were dead
weight, so they're removed. Adds alembic migration 0004 to drop the column and
index.

Verified: asset-seeder tests pass; migration applies cleanly on a fresh SQLite
(tags retains only name; tag_type column + index dropped).

Co-authored-by: guill <jacob.e.segal@gmail.com>
This commit is contained in:
Matt Miller
2026-06-09 21:07:10 -07:00
committed by GitHub
co-authored by guill
parent f350acdf21
commit a76bb4380e
11 changed files with 66 additions and 42 deletions
+2 -2
View File
@@ -575,8 +575,8 @@ async def get_tags(request: web.Request) -> web.Response:
)
tags = [
schemas_out.TagUsage(name=name, count=count, type=tag_type)
for (name, tag_type, count) in rows
schemas_out.TagUsage(name=name, count=count)
for (name, count) in rows
]
payload = schemas_out.TagsList(
tags=tags, total=total, has_more=(query.offset + len(tags)) < total
-1
View File
@@ -46,7 +46,6 @@ class AssetsList(BaseModel):
class TagUsage(BaseModel):
name: str
count: int
type: str
class TagsList(BaseModel):