-
-
Notifications
You must be signed in to change notification settings - Fork 566
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
[Plugin] Custom flags in external plugins not discovered when enabled using kwargs #871
Comments
Hi, Is there any update to this or more details regarding implementing the workaround for the skeleton app example? https://github.com/abhinavsingh/proxy.py/tree/develop/skeleton |
Figured it out. def run_proxy() -> None:
with proxy.Proxy(
enable_web_server=True,
port=9000,
input_args=["--plugin", "<plugin name>"]
) as _:
proxy.sleep_loop() This then correctly loads the plugin and resolves the plugins flags and their default values. I would imagine for any utilisation of the flags (outside of default) you'd probably need to add those to the |
Describe the bug
DOES NOT WORK
proxy.Proxy(plugins=["...", "...",])
will not result in discovering custom flags defined in the external plugins.FOLLOWING 2 SCENARIO WORKS
proxy.Plugin(*("--plugin", "...", "--plugin", "..."))
or
proxy --plugin ....
FIX
args.plugins
must be resolved prior to callingFlags.parse
for custom flag discovery.The text was updated successfully, but these errors were encountered: