symphony-bdk-python icon indicating copy to clipboard operation
symphony-bdk-python copied to clipboard

Datahose config: disabling datafeed in yml causes a NoneType error

Open Alex-Nalin opened this issue 1 year ago • 0 comments

Bug Report

Steps to Reproduce:

Use the following in config.yml:

datafeed: enabled: false

datahose: enabled: true tag: fancyTag # optional tag that will be used when creating or reusing a datahose feed eventTypes: # mandatory field, events you want to receive - MESSAGESENT

Expected Result:

The datahose should be used going forward

Actual Result:

Logs shows this trace:

Traceback (most recent call last): File "C:\Users\Alex.Nalin\PycharmProjects\SFDC-FED-NWI\main.py", line 728, in asyncio.run(run()) File "C:\Users\Alex.Nalin\AppData\Local\Programs\Python\Python310\lib\asyncio\runners.py", line 44, in run return loop.run_until_complete(main) File "C:\Users\Alex.Nalin\AppData\Local\Programs\Python\Python310\lib\asyncio\base_events.py", line 649, in run_until_complete return future.result() File "C:\Users\Alex.Nalin\PycharmProjects\SFDC-FED-NWI\main.py", line 53, in run async with SymphonyBdk(config) as bdk: File "C:\Users\Alex.Nalin\AppData\Local\Programs\Python\Python310\lib\site-packages\symphony\bdk\core\symphony_bdk.py", line 102, in init self._initialize_bot_services() File "C:\Users\Alex.Nalin\AppData\Local\Programs\Python\Python310\lib\site-packages\symphony\bdk\core\symphony_bdk.py", line 117, in _initialize_bot_services self._datafeed_loop = self._service_factory.get_datafeed_loop() File "C:\Users\Alex.Nalin\AppData\Local\Programs\Python\Python310\lib\site-packages\symphony\bdk\core\service_factory.py", line 156, in get_datafeed_loop if df_version.lower() == DatafeedVersion.V1.value.lower(): AttributeError: 'NoneType' object has no attribute 'lower'

Environment:

This issue occurs on all deployment, locally, via docker, on GKE...

Additional Context:

If removing the datafeed part and leaving the config.yml as below, then no error:

datahose: enabled: true tag: fancyTag # optional tag that will be used when creating or reusing a datahose feed eventTypes: # mandatory field, events you want to receive - MESSAGESENT

Alex-Nalin avatar Mar 21 '24 18:03 Alex-Nalin