1
0
mirror of https://github.com/MarlinFirmware/Marlin.git synced 2024-11-26 21:36:21 +00:00

🔧 Schema catch missing pip

This commit is contained in:
Scott Lahteine 2022-08-06 03:48:24 -05:00
parent e33dafeb80
commit 9c86ca3a19

View File

@ -393,8 +393,12 @@ def main():
except ImportError:
print("Installing YAML module ...")
import subprocess
subprocess.run(['python3', '-m', 'pip', 'install', 'pyyaml'])
import yaml
try:
subprocess.run(['python3', '-m', 'pip', 'install', 'pyyaml'])
import yaml
except:
print("Failed to install YAML module")
return
print("Generating YML ...")
dump_yaml(schema, Path('schema.yml'))