Answer the question
In order to leave comments, you need to log in
How to properly pass arguments to CLI using Argh (Python)?
Hello!
There is the following problem:
There is a file with a class.
There is a file run.py
There is a file with a class instance.
So, with the help of run.py, I have to run a file with a class instance, passing its name as a command line argument and passing some parameter (validation code) for the method of this class.
That is, python run.py -d my_module, -v 777
you need to use the argh library.
So far, there is no way to do it in such a way as to import the necessary file with the instance, and even pass the value to the method of this instance.
Hope you can help, thanks!
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question