Skip to content

Deprecated warning while parsing the .cz.yaml file #336

@vinayvennela

Description

@vinayvennela

Description

When using .cz.yaml configuration file, getting a warning as below.

YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details.
parser = yaml.load(yaml_file)

Steps to reproduce

  1. Add a .cz.yaml file to a repo
  2. Add some changes to a repo and commit with a relevant message (feat/fix).
  3. Run "cz bump"

Current behavior

Throws deprecated warning for yaml.load()

Desired behavior

There shouldn't be a warning, we should be using safe and recommended way of loading yaml file

Environment

  • commitizen version: 2.14.0
  • python version: 3.8.1
  • operating system: mac OS

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions