yunruse / Noether

Just another units package
MIT License
9 stars 0 forks source link

`noether -m -10degC` causes "unrecognized arguments" #65

Closed yunruse closed 11 months ago

yunruse commented 11 months ago

Python 3.11.1 noether==1.0.1

When running e.g. python -m noether -10degC, an "unrecognised arguments" error occurs as the figure begins with a dash.

This should be fixed in argparse if possible. If not, I guess recommend -- in the alias.

yunruse commented 11 months ago

Easy fix is to throw unrecognised arguments back into terms:

args, unknown = parser.parse_known_args()
args.terms += unknown