psa_car_controller icon indicating copy to clipboard operation
psa_car_controller copied to clipboard

Update Charge price

Open CWfFO opened this issue 2 years ago • 2 comments

Describe the bug If i want to update the charge price i get this error:

Callback error updating empty-div.children

Traceback (most recent call last) File "/usr/local/lib/python3.7/dist-packages/psa_car_controller/web/view/views.py", line 94, in capture_diffs_in_battery_table charge = Charge(changed_line['start_at']) File "/usr/local/lib/python3.7/dist-packages/psa_car_controller/psacc/model/charge.py", line 19, in init assert isinstance(start_at, datetime)

Traceback (most recent call last): File "/usr/local/lib/python3.7/dist-packages/psa_car_controller/web/view/views.py", line 94, in capture_diffs_in_battery_table charge = Charge(changed_line['start_at']) File "/usr/local/lib/python3.7/dist-packages/psa_car_controller/psacc/model/charge.py", line 19, in init assert isinstance(start_at, datetime) AssertionError

To Reproduce Steps to reproduce the behavior:

  1. what command did you use
  2. when the bug append ?
  3. Does it persist after restarting the program?
  4. Does it persist after recreate config by going to http://server_address:port/config?

Config file Give the anonymize content of the config file

Environment (please complete the following information):

  • OS: Raspbian
  • Brand and model of car: Corsa
  • Application version (commit number, branch or tag): v3.0.3
  • Log from http://server_address:port/log and browser console log

Additional context Add any other context about the problem here.

CWfFO avatar May 19 '22 04:05 CWfFO

I have same problem.

stevoh6 avatar Jun 07 '22 09:06 stevoh6

Me too, both in version 3.0.4 and 3.0.3

I'm using docker version.

thanks, Speck

Speck81 avatar Jun 30 '22 13:06 Speck81

Same here, i can't update a price charges:

2022-12-30 12:11:34,781 :: ERROR :: Exception on /_dash-update-component [POST] Traceback (most recent call last): File "/usr/lib/python3/dist-packages/flask/app.py", line 2447, in wsgi_app response = self.full_dispatch_request() File "/usr/lib/python3/dist-packages/flask/app.py", line 1952, in full_dispatch_request rv = self.handle_user_exception(e) File "/usr/lib/python3/dist-packages/flask/app.py", line 1821, in handle_user_exception reraise(exc_type, exc_value, tb) File "/usr/lib/python3/dist-packages/flask/_compat.py", line 39, in reraise raise value File "/usr/lib/python3/dist-packages/flask/app.py", line 1950, in full_dispatch_request rv = self.dispatch_request() File "/usr/lib/python3/dist-packages/flask/app.py", line 1936, in dispatch_request return self.view_functionsrule.endpoint File "/usr/local/lib/python3.9/dist-packages/dash/dash.py", line 1274, in dispatch ctx.run( File "/usr/local/lib/python3.9/dist-packages/dash/_callback.py", line 440, in add_context output_value = func(*func_args, **func_kwargs) # %% callback invoked %% File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/web/view/views.py", line 94, in capture_diffs_in_battery_table charge = Charge(changed_line['start_at']) File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psacc/model/charge.py", line 19, in init assert isinstance(start_at, datetime)

gerar19 avatar Dec 30 '22 11:12 gerar19

Hi someone can test my PR ?

Mikado8231 avatar Nov 10 '23 20:11 Mikado8231

fixed

flobz avatar Jan 14 '24 10:01 flobz