open-contracting / credere-backend

A tool that facilitates the participation of Micro, Small, and Medium businesses (MSMEs) in the Colombian public procurement market.
https://credere.readthedocs.io
BSD 3-Clause "New" or "Revised" License
5 stars 0 forks source link

update get borrower email method #307

Closed yolile closed 1 month ago

yolile commented 1 month ago

correo_entidad is now correo_electr_nico

│ /workdir/app/sources/colombia.py:252 in <genexpr>                            │
│                                                                              │
│   249 │                                                                      │
│   250 │   if len_borrower_response_email_json > 1:                           │
│   251 │   │   email = Counter(                                               │
│ ❱ 252 │   │   │   borrower_email["correo_entidad"] for borrower_email in bor │
│   253 │   │   ).most_common(1)[0][0]                                         │
│   254 │                                                                      │
│   255 │   if not sources.is_valid_email(email):                              │
│                                                                              │
│ ╭──────────────────────────────── locals ─────────────────────────────────╮  │
│ │             .0 = <list_iterator object at 0x7fd3f63a7d00>               │  │
│ │ borrower_email = {                                                      │  │
│ │                  │   'nombre_entidad': 'xxx',            │  │
│ │                  │   'nit': 'xxx',                                │  │
│ │                  │   'tel_fono_entidad': 'xxx',                     │  │
│ │                  │   'producto': 'xxxx',              │  │
│ │                  │   'usuario': 'xxx',                    │  │
│ │                  │   'login': 'xxx,                      │  │
│ │                  │   'm_vil_usuario': 'xxx',                     │  │
│ │                  │   'correo_electr_nico': '[xxx)', │  │
│ │                  │   'entidad_proveedor': 'Proveedor',                  │  │
│ │                  │   'usuario_responsable': 'No',                       │  │
│ │                  │   ... +3                                             │  │
│ │                  }                                                      │  │
│ ╰─────────────────────────────────────────────────────────────────────────╯  │
╰──────────────────────────────────────────────────────────────────────────────╯
KeyError: 'correo_entidad'