election_day.formats.imports.ech
Functions
|
Tries to import the given eCH XML file. |
Module Contents
- election_day.formats.imports.ech.import_ech(principal: Canton | Municipality, file: IO[bytes], session: sqlalchemy.orm.Session, default_locale: str) onegov.election_day.formats.imports.common.ECHImportResultType [source]
Tries to import the given eCH XML file.
This function is typically called automatically every few minutes during an election day - we use bulk inserts to speed up the import.
- Returns:
A tuple consisting of a list with errors and a set with updated votes.