This commit is contained in:
2026-08-16 18:36:56 +02:00
parent d981147ff2
commit a94a5aaad7
26 changed files with 904 additions and 507 deletions
+13 -6
View File
@@ -31,15 +31,22 @@ Category assignment (dump -> PG):
mapped_data.category from a MySQL dump when available.
Dump path (first match wins):
1. -mysql-dump flag
2. SEED_A1_MYSQL_DUMP
3. Auto-detect: ~/Downloads/descrybe_new (1).sql or descrybe_new.sql
1. -mysql-dump flag / admin body mysql_dump
2. SEED_A1_MYSQL_DUMP (API process env on Git-Syncer)
3. Auto-detect: scripts/seed/descrybe_new.sql (deploy root),
~/Downloads/descrybe_new (1).sql or descrybe_new.sql
One-off without wipe:
Git-Syncer / production: copy the dump onto the API host, e.g.
<deploy-root>/scripts/seed/descrybe_new.sql
or set SEED_A1_MYSQL_DUMP=/absolute/path/descrybe_new.sql in the API env.
Then use Admin → Companies → Sync A1 (no CLI DATABASE_URL needed).
One-off without wipe (CLI; loads monorepo-root .env when unset):
go run ./cmd/seed-a1 -mode backfill-categories
That also deletes Postman Elkotex fixture EANs (5905575903198, 6970995789942)
from non-A1 tenants (Platform Demo must not mirror them).
Admin Sync A1 = dump category backfill (when dump present) + Fix hygiene
(prompts, weak hashes, bidirectional category backfill, attr sanitize).
It does NOT wipe/reimport the ~25k catalog.
Note: MySQL processed description/attributes are usually NULL; feed-origin
original description + specs live on raw_products.mapped_data in the archive.