Skip to content

safe_load() got an unexpected keyword argument 'Loader' #42

@uberstar100

Description

@uberstar100

I'm not sure if this is an issue that matters, because I got my GPU fans spinning anyways despite the error, I thought of reporting it anyway:

Traceback (most recent call last):
  File "/usr/bin/amdgpu-fan", line 33, in <module>
    sys.exit(load_entry_point('amdgpu_fan==0.0.23', 'console_scripts', 'amdgpu-fan')())
             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/amdgpu_fan/controller.py", line 83, in main
    config = load_config(location)
  File "/usr/lib/python3.13/site-packages/amdgpu_fan/controller.py", line 57, in load_config
    return yaml.safe_load(f, Loader=yaml.FullLoader)
           ~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: safe_load() got an unexpected keyword argument 'Loader'

Quickly looking at the documentation reveals that the method only accepts a file stream:

https://pyyaml.org/wiki/PyYAMLDocumentation

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions