Home › Forums › FABRIC General Questions and Discussion › Error message: strptime() argument 1 must be str, not None
- This topic has 5 replies, 2 voices, and was last updated 1 month, 3 weeks ago by
Vaneshi Ramdhony.
-
AuthorPosts
-
February 3, 2025 at 5:30 pm #8154
Hello FABRIC Team,
We are trying to run this command in one of our codes and getting an error as below, while running with fabrictestbed-extensions 1.8.0
Command:
sites_connectx_json = fablib.list_sites(output=”json”,quiet=”true”,filter_function=lambda x: x[cx6_column_name] > 0 or x[cx5_column_name] > 0,latlon=False,)Error:
File “…/fabric-jupyter/lib/python3.10/site-packages/fabrictestbed_extensions/fablib/resources.py”, line 630, in update
raise Exception(
Exception: Failed to get advertised_topology: Status.FAILURE, strptime() argument 1 must be str, not NoneWe also ran the same command with fabrictestbed-extension 1.7.2 and this error was not showing up. Kindly advise what changes could cause the strptime() to fail and if there is any modifications we can make on our side for it to work.
This is my output of pip3 list | grep fab
fabric-credmgr-client 1.6.1
fabric_fim 1.8.0
fabric_fss_utils 1.6.0
fabric-orchestrator-client 1.8.0
fabric-paramiko-expect 1.0
fabrictestbed 1.8.0
fabrictestbed-extensions 1.8.1Thank you team,
Regards,
Vaneshi
February 4, 2025 at 1:30 pm #8157Hi Vaneshi,
I am unable to reproduce this with any of the JH containers. I do notice a small error in the API posted above.
quiet
parameter is a boolean.Could you please check the following?
- You have a valid token in
~/.tokens.json
- Try the snippet below
from fabrictestbed_extensions.fablib.fablib import FablibManager as fablib_manager
fablib = fablib_manager()
cx5_column_name = 'nic_connectx_5_available'
cx6_column_name = 'nic_connectx_6_available'
sites_connectx_json = fablib.list_sites(
output="json",
quiet=True,
filter_function=lambda x: x[cx6_column_name] > 0 or x[cx5_column_name] > 0,
latlon=False,
)
print(sites_connectx_json)
Please let me know if you still run into errors.
Thanks,
Komal
February 4, 2025 at 8:41 pm #8177Hello Komal,
The token used is valid and I tried the suggested code snippet and also changed (quiet=True,) I am still getting the same error as before and in the same location; sites_connectx_json = fablib.list_sites( )
Kindly let me know what else I can do/share from my end to help facilitate the debugging.
Thank you for the assistance,
Regards,
VaneshiFebruary 5, 2025 at 12:28 pm #8183Reached out to Vaneshi via email to request a meeting to work to resolve this!
Thanks,
Komal
February 5, 2025 at 3:31 pm #8188Issue resolved over zoom meeting, the issue was the token.
Token file only had
id_token
instead of the entire token contents. Downloading the token file and using that resolved the issue.Please let us know if you run into any other issues. I have taken a note to return a more user friendly error. We will address this in the next release.
Thanks,
Komal
February 5, 2025 at 3:35 pm #8189Thank you for your support Komal. I shall ensure to include the entire token contents for next projects.
- You have a valid token in
-
AuthorPosts
- You must be logged in to reply to this topic.