I've grumbled about this before, it is bad form to take over the command line
and logging, etc, at import time without so much as an init() call.
To work around it in my app, I put all the kivy stuff into its own modules.
Meaning the main.py only has standard python in it, with kivy deferred. Use
argparse's parse_known_args:
https://docs.python.org/3/library/argparse.html#partial-parsing
This will return any extras, which you can pass to kivy when loading it later,
by importing kivy-using modules under a main() function for example. There is
also an environment variable to shut off the logging config.
How I did it (inelegant but works):
args, unknown = parser.parse_known_args()
sys.argv[1:] = unknown
# load kivy app later
Also, I do the argparsing in a loading script that happens before main.py on
linux, but that is skipped on android for example, allowing it to work easily in
both contexts.