Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug when creating a budget (Button SAVE) #33

Open
utillity opened this issue Sep 28, 2019 · 1 comment
Open

Bug when creating a budget (Button SAVE) #33

utillity opened this issue Sep 28, 2019 · 1 comment

Comments

@utillity
Copy link

Hi,

I just installed this module on my Odoo 12 CE (on premise). Going to Invoices > Accounting > Budget and creating a test budget, the following error message appeared on pressing SAVE:

Error:
Odoo Server Error

Traceback (most recent call last):
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/api.py", line 1039, in get
    value = self._data[key][field][record.id]
KeyError: 1

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/fields.py", line 963, in __get__
    value = record.env.cache.get(record, self)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/api.py", line 1041, in get
    raise CacheMiss(record, field)
odoo.exceptions.CacheMiss: ('crossovered.budget.lines(1,).practical_amount', None)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/http.py", line 654, in _handle_exception
    return super(JsonRequest, self)._handle_exception(exception)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/http.py", line 312, in _handle_exception
    raise pycompat.reraise(type(exception), exception, sys.exc_info()[2])
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/tools/pycompat.py", line 87, in reraise
    raise value
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/http.py", line 696, in dispatch
    result = self._call_function(**self.params)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/http.py", line 344, in _call_function
    return checked_call(self.db, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/service/model.py", line 97, in wrapper
    return f(dbname, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/http.py", line 337, in checked_call
    result = self.endpoint(*a, **kw)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/http.py", line 939, in __call__
    return self.method(*args, **kw)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/http.py", line 517, in response_wrap
    response = f(*args, **kw)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/addons/web/controllers/main.py", line 962, in call_kw
    return self._call_kw(model, method, args, kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/addons/web/controllers/main.py", line 954, in _call_kw
    return call_kw(request.env[model], method, args, kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/api.py", line 749, in call_kw
    return _call_kw_multi(method, model, args, kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/api.py", line 736, in _call_kw_multi
    result = method(recs, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/models.py", line 2780, in read
    data[record][name] = convert(record[name], record, use_name_get)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/models.py", line 5065, in __getitem__
    return self._fields[key].__get__(self, type(self))
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/fields.py", line 967, in __get__
    self.determine_value(record)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/fields.py", line 1078, in determine_value
    self.compute_value(recs)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/fields.py", line 1034, in compute_value
    self._compute_value(records)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/fields.py", line 1025, in _compute_value
    getattr(records, self.compute)()
  File "/opt/bitnami/apps/odoo/data/addons/12.0/account_budget_oca/models/account_budget.py", line 154, in _compute_practical_amount
    (line.analytic_account_id.id, date_from, date_to, acc_ids,)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/sql_db.py", line 148, in wrapper
    return f(self, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-12.0.post20190118-py3.7.egg/odoo/sql_db.py", line 225, in execute
    res = self._obj.execute(query, params)
psycopg2.ProgrammingError: function to_date(date, unknown) does not exist
LINE 5:                         AND (date between to_date('2019-06-0...
                                                  ^
HINT:  No function matches the given name and argument types. You might need to add explicit type casts.
@utillity
Copy link
Author

grafik

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

No branches or pull requests

1 participant