control fallback_to_snapshot behavior from cli
Closed this issue · 2 comments
mcooperman commented
there is no command line option to toggle the fallback_to_snapshot behavior (True|False) of TLDExtract. At least from a testing perspective, to force URL fetch(es), it should be there.
john-kurkowski commented
I'm not sure about maintaining every possible Python API in the CLI. The CLI is just for quick, one-off queries. CLI users can do the following to set fallback_to_snapshot
, yeah? Not too verbose.
$ python -c 'import tldextract; print(" ".join(tldextract.TLDExtract(fallback_to_snapshot=False)("forums.bbc.co.uk")))'
forums bbc co.uk
john-kurkowski commented