Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

run() requires argparse shim, can't be called directly #139

Open
aaronrudkin opened this issue Sep 29, 2021 · 0 comments
Open

run() requires argparse shim, can't be called directly #139

aaronrudkin opened this issue Sep 29, 2021 · 0 comments
Labels
bug Something isn't working

Comments

@aaronrudkin
Copy link

The run() method in ffsubsync.py expects as an argument an argparse.Namespace. As a result, any attempt to call ffsubsync as a Python module rather than a standalone process requires shimming the arguments into an argparse.Namespace first. This means there's no easy way to run a full cycle of ffsubsync and get the return values.

Probably this would best be fixed by changing the code in all of the main modules to take kwargs instead of an argparser.Namespace that gets passed around, and then unpack the parser into a dict in the external loop.

@aaronrudkin aaronrudkin added the bug Something isn't working label Sep 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant