Missing Query Tag (ARCH2057)
هذا المحتوى غير متوفر بلغتك بعد.
Key python.orm.missing-query-tag · Severity info · Category orm
Leaving terminal queries without a tag or comment for log/APM correlation makes slow-query attribution harder. Annotate the query with a descriptive tag.
Incorrect
Section titled “Incorrect”def monthly_report(): return Order.objects.filter(status="paid") # untagged, source unclear in logsCorrect
Section titled “Correct”def monthly_report(): return Order.objects.filter(status="paid").annotate( _tag=RawSQL("/* monthly_report */ 0", []) )Add a query tag/comment (TagWith / SQL comment) to terminal queries to ease log and APM correlation.