You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using hass.get_history() I get an error saying that I have used 2 positional arguements - but I haven't, I have used one (the entity ID), and a keyword arguement (start_time). I have tried using the days keyword arguement and get the same error. I am using python 3.11 on ubuntu 22.04, appdaemon 4.4.2
Version
4.4.2
Installation type
Python virtual environment
Relevant log output
2024-04-14 18:59:00.012400 WARNING pi3_check: ------------------------------------------------------------
TypeError: Hass.get_history() takes 1 positional argument but 2 were given
^^^^^^^^^^^^^^^^^^^^^
return await coro(*args, **kwargs)
File "/opt/appdaemon/lib/python3.11/site-packages/appdaemon/plugins/hass/hassapi.py", line 30, in coro_wrapper
raise self._exception
File "/usr/lib/python3.11/concurrent/futures/_base.py", line 401, in __get_result
^^^^^^^^^^^^^^^^^^^
returnself.__get_result()
File "/usr/lib/python3.11/concurrent/futures/_base.py", line 456, in result
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
result = future.result(self.AD.internal_function_timeout)
File "/opt/appdaemon/lib/python3.11/site-packages/appdaemon/utils.py", line 313, in run_coroutine_threadsafe
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
f = run_coroutine_threadsafe(self, coro(self, *args, **kwargs))
File "/opt/appdaemon/lib/python3.11/site-packages/appdaemon/utils.py", line 231, in inner_sync_wrapper
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
H1 = self.get_history('climate.play_room_radiator_1_heat_demand', start_time = history_start_time)
File "/opt/appdaemon/apps/heating.py", line 29, in run_check
funcref(self.AD.sched.sanitize_timer_kwargs(app, args["kwargs"]))
File "/opt/appdaemon/lib/python3.11/site-packages/appdaemon/threading.py", line 1022, in worker
2024-04-14 18:59:00.011949 WARNING pi3_check: Traceback (most recent call last):
2024-04-14 18:59:00.009854 WARNING pi3_check: ------------------------------------------------------------
2024-04-14 18:59:00.009480 WARNING pi3_check: Worker Ags: {'id': 'f43d438c36f84b76b7ec134a0425c33c', 'name': 'pi3_check', 'objectid': 'a071accc286141dabdf1bdcfefc9bb38', 'type': 'scheduler', 'function': <bound method check_pi3.run_check of <heating.check_pi3 object at 0x7f8da826ed10>>, 'pin_app': True, 'pin_thread': 8, 'kwargs': {'interval': 86400, '__thread_id': 'thread-8'}}
2024-04-14 18:59:00.009051 WARNING pi3_check: Unexpected error in worker for App pi3_check:
2024-04-14 18:59:00.008573 WARNING pi3_check: ------------------------------------------------------------
Relevant code in the app or config file that caused the issue
What happened?
When using hass.get_history() I get an error saying that I have used 2 positional arguements - but I haven't, I have used one (the entity ID), and a keyword arguement (start_time). I have tried using the days keyword arguement and get the same error. I am using python 3.11 on ubuntu 22.04, appdaemon 4.4.2
Version
4.4.2
Installation type
Python virtual environment
Relevant log output
Relevant code in the app or config file that caused the issue
Anything else?
No response
The text was updated successfully, but these errors were encountered: