privacy-for-safari icon indicating copy to clipboard operation
privacy-for-safari copied to clipboard

Update tlds.json from the latest PSL

Open groundcat opened this issue 4 months ago • 0 comments

Task/Issue URL: Tech Design URL: CC:

Description:

This PR is to update the copy of the Public Suffix List to the latest version which is sourced from https://publicsuffix.org/list/public_suffix_list.dat

Steps to test this PR:

Reproduction

import requests
import json

url = "https://publicsuffix.org/list/public_suffix_list.dat"

response = requests.get(url)
response.raise_for_status()
data = response.text

lines = data.splitlines()
entries = [line.strip() for line in lines if line.strip() and not line.strip().startswith('//')]

with open('public_suffix_list.json', 'w', encoding='utf-8') as f:
    json.dump(entries, f, indent=4, ensure_ascii=False)


Internal references:

Software Engineering Expectations Technical Design Template

groundcat avatar Oct 13 '24 07:10 groundcat