feat: Introduce bot-digitador service for automated data entry in Integración Total. Add CLI and GUI interfaces for CSV processing, implement auto-start functionality on Windows, and enhance README with setup instructions and usage details. Include necessary configurations in docker-compose for service integration.

This commit is contained in:
erik
2026-08-09 21:26:56 -05:00
parent a3b4c7fc47
commit e9b766281a
74 changed files with 11177 additions and 115 deletions
@@ -194,21 +194,25 @@ class MinioStorage:
Si el manifest falta, falla o queda vacío, hace fallback a list_keys
bajo el prefijo (cubre varias carpetas NIT planas).
En corridas distribuidas varios shards sobrescriben el manifest parcial:
siempre se fusiona con list_keys del prefijo.
"""
prefix = prefix or downloads_prefix(job_id)
files: List[dict] = []
by_key: dict[str, dict] = {}
try:
raw = self.get_bytes(manifest_key(job_id))
payload = json.loads(raw.decode("utf-8"))
for key in payload.get("files") or []:
entry = self._file_entry(str(key))
if entry is not None:
files.append(entry)
by_key[entry["key"]] = entry
except Exception:
files = []
pass
if not files:
files = self._list_pdf_entries(prefix)
for entry in self._list_pdf_entries(prefix):
by_key[entry["key"]] = entry
files = list(by_key.values())
return {"job_id": job_id, "prefix": prefix, "files": files, "count": len(files)}
def _list_pdf_entries(self, prefix: str) -> List[dict]: