fix(22d): register scrape_kn_catalog_objects in celery include list #339
No reviewers
Labels
No labels
admin
analytics
auth
automation
bug
business
chore
ci
compliance
data
data-moat
docs
duplicate
dx
enhancement
Fable 5 ревью
feedback/max
generative
GG-форсайт
needs-discussion
needs-human
observability
pause-bots
performance
priority/p0
priority/p1
priority/p2
priority/p3
scope/backend
scope/db
scope/devops
scope/frontend
scope/qa
scrapers
security
site-finder
stage/1
stage/2
status/blocked
status/done
status/needs-analysis
status/needs-fix
status/qa
status/ready
status/review
status/wip
tech-debt
tradein
ux
week ревью 1
wontfix
вторичка
ИРД
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: lekss361/gendesign#339
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "fix/22d-register-catalog-objects-task"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
PR #335 добавил task
scrape_kn_catalog_objects, ноcelery_app.pyимеет explicitinclude=[]список (а не autodiscover). Новый модуль не был добавлен → worker не импортировал task →apply_asyncиз admin endpoint валился с:One-line add to
includelist.Test plan
POST /admin/scrape/kn-catalog-objects {"max_objects":3}→ должно вернуть task_id и выполниться (не упасть)SELECT wall_type, energy_eff FROM domrf_kn_objects WHERE catalog_scraped_at IS NOT NULL LIMIT 3returns dataDeep Code Review — verdict ✅ APPROVE
Net effect vs main
One-line surgical fix.
Diff size note
PR diff shows +36/-0, but that's against stale
merge_base 7611287(forked before #338). The branch contains 2 commits:1e08cd0— admin endpoint (duplicate of #338 already on main)f370771— the include-list fixVerified via
git merge-tree forgejo/main forgejo/fix/22d-...→ resulting tree differs from main by exactly +1 line in celery_app.py. 3-way merge correctly deduplicates the endpoint hunk (identical text) and preserveslanding.pyadded on main (#331).Verification
app.workers.tasks.scrape_kn_catalog_objects— module exists on main (c3b96d2, added by #335)@celery_app.task→def scrape_kn_catalog_objects(...)scrape_kn, before unrelated tasks)Conventions
Why this is needed
PR #335 added the task module, but
celery_app.pyuses explicitinclude=[...](not autodiscover). Worker silently doesn't import →apply_asyncfrom #338 endpoint hitsKeyError: 'tasks.scrape_kn_catalog_objects...'. This PR closes the loop.Post-merge test plan (from PR body)
POST /admin/scrape/kn-catalog-objects {"max_objects":3}→ expect 200 + task_id, no KeyErrorSELECT wall_type, energy_eff FROM domrf_kn_objects WHERE catalog_scraped_at IS NOT NULL LIMIT 3Merging via deep-code-reviewer.