Skip to content

tldextract used with a file url caches the file #351

@mimi89999

Description

@mimi89999
  1. Delete the cache if it exists (~/.cache/python-tldextract/)
  2. Initialize and use tldextract with the list from a file: import tldextract; tldextract.TLDExtract(suffix_list_urls=("file:///usr/share/publicsuffix/public_suffix_list.dat",))("debian.org")
  3. Notice that ~/.cache/python-tldextract/ is created or that tldextract logs a warning on read only systems

I think that it makes little sense to copy the specified file to cache. It does however create several issues:

  1. On read only systems cache needs to be explicitly disabled to avoid warnings
  2. More importantly, modifications in the suffix file don't immediately affect the results of tldextract leading to a lot of confusion

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions