mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-06-26 01:15:28 -06:00
Use yaml.safe_load instead of yaml.load
CURA-12548 Note that this is not technically required, because external contributors can change it anyway. However, making this change will silent a security warning raised by an automatic analysis tool, and it doesn't hurt.
This commit is contained in:
parent
da9bcd0239
commit
90115808ee
1 changed files with 2 additions and 2 deletions
|
@ -21,7 +21,7 @@ def main() -> None:
|
||||||
parser.add_argument("--diagnose", action="store_true", help="Diagnose the files")
|
parser.add_argument("--diagnose", action="store_true", help="Diagnose the files")
|
||||||
parser.add_argument("--deleted", action="store_true", help="Check for deleted files")
|
parser.add_argument("--deleted", action="store_true", help="Check for deleted files")
|
||||||
parser.add_argument("--fix", action="store_true", help="Attempt to apply the suggested fixes on the files")
|
parser.add_argument("--fix", action="store_true", help="Attempt to apply the suggested fixes on the files")
|
||||||
parser.add_argument("Files", metavar="F", type=Path, nargs="+", help="Files or directories to format")
|
parser.add_argument("Files", type=Path, nargs="+", help="Files or directories to format")
|
||||||
|
|
||||||
args = parser.parse_args()
|
args = parser.parse_args()
|
||||||
files = extractFilePaths(args.Files)
|
files = extractFilePaths(args.Files)
|
||||||
|
@ -39,7 +39,7 @@ def main() -> None:
|
||||||
return
|
return
|
||||||
|
|
||||||
with open(setting_path, "r") as f:
|
with open(setting_path, "r") as f:
|
||||||
settings = yaml.load(f, yaml.FullLoader)
|
settings = yaml.safe_load(f)
|
||||||
|
|
||||||
full_body_check = {"Diagnostics": []}
|
full_body_check = {"Diagnostics": []}
|
||||||
comments_check = {"Error Files": []}
|
comments_check = {"Error Files": []}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue