Skip to content

FIX account_ebics_oca_statement_import type error#164

Open
jans23 wants to merge 1 commit into
Noviat:18.0from
Nitrokey:18.0-fix-account_ebics_oca_statement_import-type-error
Open

FIX account_ebics_oca_statement_import type error#164
jans23 wants to merge 1 commit into
Noviat:18.0from
Nitrokey:18.0-fix-account_ebics_oca_statement_import-type-error

Conversation

@jans23
Copy link
Copy Markdown
Contributor

@jans23 jans23 commented May 12, 2026

This fixes the following error.

Odoo Server Error

Occured on shop.nitrokey.com on model account.statement.import on 2026-05-12 11:44:00 GMT

Traceback (most recent call last):
File "/srv/odoo/odoo/parts/odoo/odoo/http.py", line 2167, in _transactioning
return service_model.retrying(func, env=self.env)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/srv/odoo/odoo/parts/odoo/odoo/service/model.py", line 157, in retrying
result = func()
^^^^^^
File "/srv/odoo/odoo/parts/odoo/odoo/http.py", line 2134, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/srv/odoo/odoo/parts/odoo/odoo/http.py", line 2382, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/srv/odoo/odoo/parts/odoo/odoo/addons/base/models/ir_http.py", line 333, in _dispatch
result = endpoint(**request.params)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/srv/odoo/odoo/parts/odoo/odoo/http.py", line 754, in route_wrapper
result = endpoint(self, *args, **params_ok)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/addons/web/controllers/dataset.py", line 42, in call_button
action = call_kw(request.env[model], method, args, kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/srv/odoo/odoo/parts/odoo/odoo/api.py", line 535, in call_kw
result = getattr(recs, name)(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/addons/account_statement_import_file/wizard/account_statement_import.py", line 53, in import_file_button
result = self._import_file()
^^^^^^^^^^^^^^^^^^^
File "/tmp/addons/account_statement_import_file/wizard/account_statement_import.py", line 33, in _import_file
self.import_single_file(file_data, result)
File "/tmp/addons/account_statement_import_file/wizard/account_statement_import.py", line 99, in import_single_file
self.import_single_statement(single_statement_data, result)
File "/tmp/addons/account_statement_import_file/wizard/account_statement_import.py", line 118, in import_single_statement
journal = self._match_journal(account_number, currency)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/addons/account_ebics_oca_statement_import/wizards/account_statement_import.py", line 19, in _match_journal
sanitized_account_number = self._sanitize_account_number(account_number)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/addons/account_ebics_oca_statement_import/wizards/account_statement_import.py", line 40, in _sanitize_account_number
check_curr = sanitized_number[-3:]
~~~~~~~~~~~~~~~~^^^^^
TypeError: 'bool' object is not subscriptable

The above server error caused the following client error:
RPC_ERROR: Odoo Server Error
RPCError@https://shop.nitrokey.com/web/assets/4bb4d25/web.assets_web.min.js:3174:338
makeErrorFromResponse@https://shop.nitrokey.com/web/assets/4bb4d25/web.assets_web.min.js:3178:165
rpc._rpc/promise</<@https://shop.nitrokey.com/web/assets/4bb4d25/web.assets_web.min.js:3184:34

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant