-
Notifications
You must be signed in to change notification settings - Fork 7
Description
In Windows 10, Powershell with Wsl installed (Windows System for Linux, which uses Ubuntu)
I cloned PySysML2 with git to /opt
After install I tested pysysml2 with command
pysysml2 export --help
which brought up the following Errormessage
Traceback (most recent call last):
File "/home/user1/.local/bin/pysysml2", line 8, in
sys.exit(app())
^^^^^
TypeError: TyperArgument.make_metavar() takes 1 positional argument but 2 were given
Fix:
change to PySysML2 directory
make pyproject.toml writeable, e.g. by sudo chmod +777 pyproject.toml
Upddate the following entries
python = "^3.10"
numpy = "^1.26.2"
antlr4-python3-runtime = "4.13"
After Typer ≥ 0.7.0 add line
Click ≥ 8.1
save and continue with the following commands
sudo poetry lock
poetry update
poetry install
pipx install . --force
cd ..
sudo chmod +777 PySysML2/
für out directory
cd PySysML2/
test now with:
pysysml2 export --help
pysysml2 export examples/models/model_test_1.sysml2 --output-dir out/ --format txt
Supported formats: json,txt,csv,xlsx,dot,png
[default: json]
sudo apt install graphviz
for export of png
It works now and gives me a wonderful tool to examine various Sysml V2 models to be found e.g. in
https://github.com/Systems-Modeling/SysML-v2-Release/tree/master/sysml/src/examples