UNIQUE constraint failed due to geonames insert
Categories
(Application Services :: Suggest, defect, P2)
Tracking
(Not tracked)
People
(Reporter: adw, Assigned: adw)
References
Details
(Whiteboard: [sng])
Attachments
(1 file)
[mozilla/application-services] Bug 1952407 - UNIQUE constraint failed due to geonames insert (#6644)
57 bytes,
text/x-github-pull-request
|
Details | Review |
This is logged several times when running test_quicksuggest_yelp_ml.js:
[ERROR error_support::handling] suggest-unexpected: Error executing SQL: UNIQUE constraint failed: geonames.id (context: geoname insert)
console.error: URLBar - QuickSuggest.SuggestBackendRust: "Ingest error" ({type:"Weather", error:(new Error("reason: Error executing SQL: UNIQUE constraint failed: geonames.id (context: geoname insert)", "resource://gre/modules/RustSuggest.sys.mjs", 2466)), reason:"Error executing SQL: UNIQUE constraint failed: geonames.id (context: geoname insert)"})
It's because geoname IDs are a stable part of the geonames data -- they aren't just an int in the Sqlite table that's incremented on insert -- and GeonameInsertStatement doesn't handle inserting a geoname with an existing ID, i.e., the same geoname again.
We've changed geonames once or twice so it's entirely possible this has prevented those changes from being ingested, although it hasn't been noticeable and geonames are recognized correctly in queries. And I'm not sure if we keep trying to ingest them every ingest period due to the failure.
It's also possible this prevents other RS data ingested at the same time as geonames from being ingested properly.
Assignee | ||
Updated•11 days ago
|
Updated•11 days ago
|
Comment 1•11 days ago
|
||
Comment 2•4 days ago
|
||
Authored by https://github.com/0c0w3
https://github.com/mozilla/application-services/commit/7712c4f88fd70ee9b71bb9bcfae3dab8b2420a56
[main] Bug 1952407 - UNIQUE constraint failed due to geonames insert
Description
•