Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use yaml.safe_load instead of deprecated yaml.load #180

Merged
merged 1 commit into from
Mar 28, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions ros1_bridge/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ def get_ros2_messages():
continue
rule_file = os.path.join(package_path, export.attributes['mapping_rules'])
with open(rule_file, 'r') as h:
content = yaml.load(h)
content = yaml.safe_load(h)
if not isinstance(content, list):
print(
"The content of the mapping rules in '%s' is not a list" % rule_file,
Expand Down Expand Up @@ -273,7 +273,7 @@ def get_ros2_services():
continue
rule_file = os.path.join(package_path, export.attributes['mapping_rules'])
with open(rule_file, 'r') as h:
content = yaml.load(h)
content = yaml.safe_load(h)
if not isinstance(content, list):
print(
"The content of the mapping rules in '%s' is not a list" % rule_file,
Expand Down