Bulk Upload: tables with foreign keys must be uploaded in dependency order, and nothing says so
I maintainer di solito rispondono entro 3 giorni
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 35/100
- Tipo di issue
- Documentazione
- Chiarezza
- Da chiarire
- Stato di attività
- Attiva
- Ambito
- api, database, documentation
Direzione di ricerca
Start with the Bulk Upload documentation and API reference, and review related issue #2362 to determine whether the project wants documentation or pre-streaming validation. Done should either explain parent-first dependency order and unsupported mutual references, or specify a clear 400 response naming referenced tables.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
A Bulk Upload loads a CSV into one table with COPY. If that table has a foreign key to another table, every referenced row must already exist, otherwise the whole upload fails and is rolled back. So a set of related tables can only be uploaded one table at a time, in dependency order (parents first), and two tables that reference each other cannot be bulk-uploaded at all. Raised in a comment on #2362 (2026-07-06).
Nothing tells a user this today: the error is the foreign-key violation from Postgres, at the end of a possibly long upload.
Options:
- Document it in the Bulk Upload docs and the API reference: upload in dependency order. Cheapest, and covers the common case.
- Check before streaming: look up the table's foreign keys and answer with a clear 400 that names the referenced table(s), before the body is consumed. That needs no data check, only the catalog.
- Deferred constraints: if the foreign keys were created
DEFERRABLE, the upload transaction couldSET CONSTRAINTS ALL DEFERRED. That only helps within one transaction, so it would not by itself solve uploads of several tables, which arrive as separate requests.
Related: #2362.
- Lingua principale
- Python
- Stelle
- 65
- Fork
- 28
- Merge medio
- 4g 7h
- PR unite (30g)
- 25
Preparare l'ambiente
Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di OpenEnergyPlatform/oeplatform
-
API bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
OpenEnergyPlatform/oeplatform#2580 ·
I maintainer di solito rispondono entro 3 giorni
-
Redesign the database page to support dataset creationForse già presa @bmlancien l’ha presa 4 giorni fa. Apertadata-upload
OpenEnergyPlatform/oeplatform#2762 · 1 commento · 3 assegnatari ·
I maintainer di solito rispondono entro 3 giorni
-
Improve navigation links in Core Features and Integrated WorkflowsForse già presa @tomi-rli l’ha presa 19 giorni fa. ApertaHomepage
OpenEnergyPlatform/oeplatform#2746 · 1 assegnatario ·
I maintainer di solito rispondono entro 3 giorni
-
Enhance the new OEP homepageForse già presa @jh-RLI l’ha presa 19 giorni fa. ApertaHomepage
OpenEnergyPlatform/oeplatform#2745 · 2 assegnatari ·
I maintainer di solito rispondono entro 3 giorni
-
Display child nodes in the OEO Viewer Graph ViewForse già presa @jh-RLI l’ha presa 23 giorni fa. Apertaoeo viewer
OpenEnergyPlatform/oeplatform#2739 · 1 assegnatario ·
I maintainer di solito rispondono entro 3 giorni
Tutte le issue di OpenEnergyPlatform/oeplatform
Issue simili
-
needs-triage
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 88/100
flashinfer-ai/flashinfer#9803 ·
I maintainer di solito rispondono entro 1 giorno
-
bug frontend good first issue help wanted
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
oscarbol09/thesisforge#61 ·
-
api bug performance
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
oscarbol09/audiobard#159 ·
-
area:web p2 product:business triage:active type:bug
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 89/100
cuadrao-ai/argus#2328 ·
I maintainer di solito rispondono entro 1 giorno
-
bug frontend good first issue help wanted
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
nikhilb2/simple_invoicing#907 ·