I have a python script, that i am able to call it from the command line, and i pass the parameters to it, through flags on the terminal. For example:
Now, i want to be able to call that script from inside flask.
I can easily wrap the python script in a function, but what i do now know, is how will i be able to pass the parameters to it?
Keep in mind, that the python script handles parameters with
How will i be able to pass the flags, as function parameters (or something like that)?
1 |
python my_program.py - - parameter1 "0.4" - - parameter2 "none" |
I can easily wrap the python script in a function, but what i do now know, is how will i be able to pass the parameters to it?
Keep in mind, that the python script handles parameters with
1 |
parser.add_argument() |