Bokeh serve not modifying the arguments passed to app_hooks.py?

According to this page https://docs.bokeh.org/en/latest/docs/reference/command/subcommands/serve.html when using

bokeh serve --args foo

Only content after --args (foo in this case) is passed down to your program. However, if my application has a directory format, then if I access sys.argv in app_hooks.py, then the full command shows up. I think I can work around it with some effort, but it is annoying. Is this expected behavior?

The args are only available in the app code, i.e. main.py for a directory style app. The app hooks are separate.