Skip to content

yaml.safe_load(open_file) deprecated #11

Description

@finbaromahony

yaml.safe_load(open_file) has been deprecated
a loader is required as of PyYAML 6.0

Traceback (most recent call last):
  File "/home/vagrant/.pyenv/versions/3.6.11/lib/python3.6/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/home/vagrant/.pyenv/versions/3.6.11/lib/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/home/vagrant/.pyenv/versions/3.6.11/lib/python3.6/site-packages/terrafile/__main__.py", line 11, in <module>
    update_modules(path)
  File "/home/vagrant/.pyenv/versions/3.6.11/lib/python3.6/site-packages/terrafile/__init__.py", line 98, in update_modules
    terrafile = read_terrafile(terrafile_path)
  File "/home/vagrant/.pyenv/versions/3.6.11/lib/python3.6/site-packages/terrafile/__init__.py", line 61, in read_terrafile
    terrafile = yaml.load(open_file)
TypeError: load() missing 1 required positional argument: 'Loader'
make[1]: *** [Makefile:5: import] Error 1

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions