ydb-python-sdk icon indicating copy to clipboard operation
ydb-python-sdk copied to clipboard

bug: TypeError: BaseJWTCredentials.from_content() got multiple values for argument 'iam_endpoint'

Open Zapzatron opened this issue 8 months ago • 0 comments

Bug Report

YDB Python SDK version:

ydb[yc]==3.12.0

Environment

Windows 10 Pro 64-bit Python 3.10.11 CPU: AMD Ryzen 3 2200G Raven Ridge 14nm Technology

Related code:

credentials = ydb.iam.ServiceAccountCredentials.from_file(auth_key_path)

Other information:

Traceback (most recent call last):
  File "F:\Games\Programming_Projects\Python\Zapzatron_Club\Zapzatron_Bot\.venv\lib\site-packages\starlette\routing.py", line 732, in lifespan
    async with self.lifespan_context(app) as maybe_state:
  File "contextlib.py", line 199, in __aenter__
  File "F:\Games\Programming_Projects\Python\Zapzatron_Club\Zapzatron_Bot\source\tg\run_tg.py", line 1660, in lifespan
    await on_startup()
  File "F:\Games\Programming_Projects\Python\Zapzatron_Club\Zapzatron_Bot\source\tg\run_tg.py", line 1613, in on_startup
    await user_config_manager.create_user_data_db()
  File "F:\Games\Programming_Projects\Python\Zapzatron_Club\Zapzatron_Bot\source\general\db\user_data_yql.py", line 35, in create_user_data_db
    await create_yql_table_if_not_exist(self.error_manager, self.user_data_db_name, create_db_sql, self.endpoint,
  File "F:\Games\Programming_Projects\Python\Zapzatron_Club\Zapzatron_Bot\source\general\db\con_yql.py", line 98, in create_yql_table_if_not_exist
    await work_with_yql_db(error_manager, db_name, check_db_sql, endpoint, database, auth_key_path)
  File "F:\Games\Programming_Projects\Python\Zapzatron_Club\Zapzatron_Bot\source\general\db\con_yql.py", line 64, in work_with_yql_db
    token, = await func_retry(error_manager, get_ydb_auth_token,
  File "F:\Games\Programming_Projects\Python\Zapzatron_Club\Zapzatron_Bot\source\general\function_operation.py", line 41, in func_retry
    return await func_run(func, params)
  File "F:\Games\Programming_Projects\Python\Zapzatron_Club\Zapzatron_Bot\source\general\function_operation.py", line 11, in func_run
    func_response = await func(**params)
  File "F:\Games\Programming_Projects\Python\Zapzatron_Club\Zapzatron_Bot\source\general\db\con_yql.py", line 19, in get_ydb_auth_token
    credentials = ydb.iam.ServiceAccountCredentials.from_file(auth_key_path)
  File "F:\Games\Programming_Projects\Python\Zapzatron_Club\Zapzatron_Bot\.venv\lib\site-packages\ydb\iam\auth.py", line 104, in from_file
    return BaseJWTCredentials.from_content(
TypeError: BaseJWTCredentials.from_content() got multiple values for argument 'iam_endpoint'

Zapzatron avatar Jun 10 '24 21:06 Zapzatron