Skip to content

Commit 8488577

Browse files
authored
Merge pull request #62 from case/generated-per-tld
Add per-tld data files
2 parents fd40ea4 + 268283c commit 8488577

1,639 files changed

Lines changed: 215809 additions & 4307 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/tests.yaml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,15 @@ jobs:
3939
enable-cache: true
4040
version-file: "pyproject.toml"
4141

42+
- uses: pnpm/action-setup@0e279bb959325dab635dd2c09392533439d90093 # v6.0.8
43+
4244
- name: Install dependencies
43-
run: make deps
45+
run: bin/setup
4446

4547
- name: Run tests
4648
run: |
4749
set -o pipefail
48-
make test 2>&1 | tee test-output.log
50+
bin/test 2>&1 | tee test-output.log
4951
5052
- name: Capture build logs
5153
if: always()

.github/workflows/update-data.yaml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,10 @@ jobs:
2828
enable-cache: true
2929
version-file: "pyproject.toml"
3030

31+
- uses: pnpm/action-setup@0e279bb959325dab635dd2c09392533439d90093 # v6.0.8
32+
3133
- name: Install dependencies
32-
run: make deps
34+
run: bin/setup
3335

3436
# Download core IANA files
3537
- name: Download core data (RDAP, TLD list, root zone DB)
@@ -206,7 +208,7 @@ jobs:
206208
if: steps.source-check.outputs.source_changed == 'true'
207209
run: |
208210
set -o pipefail
209-
make test 2>&1 | tee test-output.log
211+
bin/test 2>&1 | tee test-output.log
210212
211213
- name: Notification if tests fail
212214
if: failure() && steps.run-tests.outcome == 'failure'

AGENTS.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# iana-data
2+
3+
A compilation of IANA- and ICANN-published, canonical data about the domain ecosystem. See [`docs/memory/product.md`](docs/memory/product.md) for what this is, [`docs/memory/architecture.md`](docs/memory/architecture.md) for how it's currently built.
4+
5+
<!-- project-memory:start -->
6+
## Project memory
7+
8+
Project memory lives in `docs/memory/`. The index is at [`docs/memory/memory-index.md`](docs/memory/memory-index.md).
9+
10+
**Before suggesting** file layout, naming, dependencies, vendor choices, or conventions: read the index, then read the matching entry. The codebase is the source of truth - verify against it before relying on a specific path or name in memory.
11+
12+
**When a new decision is made**: write or update the relevant memory entry in the same conversation, and surface the diff. Memory updates review like any other code change. **Exception**: if the entry changes how the memory system itself works (conventions, schema, naming, structure), draft the body inline in chat first and wait for explicit go-ahead before writing.
13+
14+
**Entries are concise**: bigger than a commit message, smaller than a design doc. Short rationales per decision.
15+
16+
**Log filenames**: use a 1-3 word slug after the date. Topic distillation, not a sentence.
17+
18+
**When memory contradicts the code**: surface the conflict. Trust the code after verifying, then update or remove the stale entry.
19+
20+
**Monorepos**: if this repo contains subprojects with their own `docs/memory/`, treat each subproject's memory as authoritative for work inside that subproject. The root `docs/memory/` covers concerns that span subprojects. See [`docs/memory/product.md`](docs/memory/product.md#monorepos) for the rationale.
21+
<!-- project-memory:end -->

CLAUDE.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@AGENTS.md

Makefile

Lines changed: 5 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -11,20 +11,16 @@ help:
1111
@echo " make checkly-info Show Checkly info"
1212
@echo " make checkly-preview-deploy Deploy Checkly checks (preview)"
1313
@echo " make checkly-test Run Checkly tests"
14-
@echo " make coverage Run tests with coverage report"
15-
@echo " make deps Install dependencies (uv sync, npm install)"
1614
@echo " make download-core Download core IANA data files"
1715
@echo " make download-iptoasn Download iptoasn data for ASN lookups"
1816
@echo " make download-tld-pages Download TLD pages (optional GROUPS=...)"
1917
@echo " make generate-idn-mapping Generate IDN script mapping"
20-
@echo " make lint Run ruff linter"
21-
@echo " make test Run linter, typecheck, and tests"
2218
@echo " make typecheck Run pyright type checker"
23-
24-
.PHONY: deps
25-
deps:
26-
uv sync
27-
npm install
19+
@echo ""
20+
@echo "Scripts (run directly, not via make):"
21+
@echo " bin/setup Install dependencies (uv sync, pnpm install)"
22+
@echo " bin/lint Run ruff check, ruff format check, pyright"
23+
@echo " bin/test Run lint then pytest"
2824

2925
.PHONY: download-core
3026
download-core:
@@ -62,10 +58,6 @@ analyze-registry-agreements:
6258
analyze-tlds-json:
6359
uv run python scripts/analyze_tlds_json.py
6460

65-
.PHONY: lint
66-
lint:
67-
uv run ruff check src/ tests/
68-
6961
.PHONY: typecheck
7062
typecheck:
7163
uv run pyright src/
@@ -74,14 +66,6 @@ typecheck:
7466
check-circular-imports:
7567
uv run pydeps src --no-output
7668

77-
.PHONY: test
78-
test: lint typecheck
79-
uv run pytest
80-
81-
.PHONY: coverage
82-
coverage: lint
83-
uv run pytest --cov=src --cov-report=term-missing
84-
8569
.PHONY: checkly-test
8670
checkly-test:
8771
npx checkly test --config monitoring/checkly/checkly.config.ts

bin/lint

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
#!/usr/bin/env bash
2+
set -euo pipefail
3+
cd "$(dirname "$0")/.."
4+
5+
paths=("$@")
6+
if [ ${#paths[@]} -eq 0 ]; then
7+
paths=(src/ tests/)
8+
fi
9+
10+
# Run all three linters even if an earlier one fails, so the developer
11+
# sees the full set of findings in one pass instead of round-tripping.
12+
exit_code=0
13+
uv run ruff check "${paths[@]}" || exit_code=$?
14+
uv run ruff format --check "${paths[@]}" || exit_code=$?
15+
uv run pyright "${paths[@]}" || exit_code=$?
16+
exit $exit_code

bin/setup

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/usr/bin/env bash
2+
set -euo pipefail
3+
cd "$(dirname "$0")/.."
4+
5+
# No "$@" forwarding: two sub-tools, no unambiguous destination for args.
6+
uv sync
7+
pnpm install

bin/test

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#!/usr/bin/env bash
2+
set -euo pipefail
3+
cd "$(dirname "$0")/.."
4+
5+
bin/lint
6+
uv run pytest --cov=src --cov-report=term-missing "$@"

data/generated/tld/aaa.json

Lines changed: 153 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,153 @@
1+
{
2+
"description": "Per-TLD bootstrap data, from IANA sources",
3+
"publication": "2026-05-15T19:11:17Z",
4+
"sources": {
5+
"iana_root_db": "https://www.iana.org/domains/root/db",
6+
"iana_rdap": "https://data.iana.org/rdap/dns.json"
7+
},
8+
"tld": {
9+
"tld": "aaa",
10+
"delegated": true,
11+
"iana_tag": "generic",
12+
"type": "gtld",
13+
"orgs": {
14+
"tld_manager": "American Automobile Association, Inc.",
15+
"admin": "Markmonitor Inc.",
16+
"tech": "GoDaddy Registry"
17+
},
18+
"nameservers": [
19+
{
20+
"hostname": "a.nic.aaa",
21+
"ipv4": [
22+
{
23+
"ip": "37.209.192.9",
24+
"asn": 12008,
25+
"as_org": "SECURITYSERVICES",
26+
"as_country": "US"
27+
}
28+
],
29+
"ipv6": [
30+
{
31+
"ip": "2001:dcd:1::9",
32+
"asn": 12008,
33+
"as_org": "SECURITYSERVICES",
34+
"as_country": "US"
35+
}
36+
]
37+
},
38+
{
39+
"hostname": "b.nic.aaa",
40+
"ipv4": [
41+
{
42+
"ip": "37.209.194.9",
43+
"asn": 12008,
44+
"as_org": "SECURITYSERVICES",
45+
"as_country": "US"
46+
}
47+
],
48+
"ipv6": [
49+
{
50+
"ip": "2001:dcd:2::9",
51+
"asn": 12008,
52+
"as_org": "SECURITYSERVICES",
53+
"as_country": "US"
54+
}
55+
]
56+
},
57+
{
58+
"hostname": "c.nic.aaa",
59+
"ipv4": [
60+
{
61+
"ip": "37.209.196.9",
62+
"asn": 12008,
63+
"as_org": "SECURITYSERVICES",
64+
"as_country": "US"
65+
}
66+
],
67+
"ipv6": [
68+
{
69+
"ip": "2001:dcd:3::9",
70+
"asn": 12008,
71+
"as_org": "SECURITYSERVICES",
72+
"as_country": "US"
73+
}
74+
]
75+
},
76+
{
77+
"hostname": "ns1.dns.nic.aaa",
78+
"ipv4": [
79+
{
80+
"ip": "156.154.144.2",
81+
"asn": 12008,
82+
"as_org": "SECURITYSERVICES",
83+
"as_country": "US"
84+
}
85+
],
86+
"ipv6": [
87+
{
88+
"ip": "2610:a1:1071::2",
89+
"asn": 12008,
90+
"as_org": "SECURITYSERVICES",
91+
"as_country": "US"
92+
}
93+
]
94+
},
95+
{
96+
"hostname": "ns2.dns.nic.aaa",
97+
"ipv4": [
98+
{
99+
"ip": "156.154.145.2",
100+
"asn": 12008,
101+
"as_org": "SECURITYSERVICES",
102+
"as_country": "US"
103+
}
104+
],
105+
"ipv6": [
106+
{
107+
"ip": "2610:a1:1072::2",
108+
"asn": 12008,
109+
"as_org": "SECURITYSERVICES",
110+
"as_country": "US"
111+
}
112+
]
113+
},
114+
{
115+
"hostname": "ns3.dns.nic.aaa",
116+
"ipv4": [
117+
{
118+
"ip": "156.154.159.2",
119+
"asn": 12008,
120+
"as_org": "SECURITYSERVICES",
121+
"as_country": "US"
122+
}
123+
],
124+
"ipv6": [
125+
{
126+
"ip": "2610:a1:1073::2",
127+
"asn": 12008,
128+
"as_org": "SECURITYSERVICES",
129+
"as_country": "US"
130+
}
131+
]
132+
}
133+
],
134+
"registry_url": "http://www.aaa.com",
135+
"whois_server": "whois.nic.aaa",
136+
"rdap_server": "https://rdap.nic.aaa/",
137+
"tld_created": "2015-08-13",
138+
"tld_updated": [
139+
"2024-12-11"
140+
],
141+
"annotations": {
142+
"rdap_source": "IANA",
143+
"registry_agreement_types": [
144+
"base",
145+
"brand",
146+
"non_sponsored"
147+
],
148+
"as_org_aliases": [
149+
"UltraDNS"
150+
]
151+
}
152+
}
153+
}

0 commit comments

Comments
 (0)