Repository navigation
feat: publication files, drop counts and release workflow (spec 006) - #45
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Adapters report dropped records as RawDrop items in the parse stream. The pipeline counts lines, records and forms per source, warns through its own logger and ingest stores the counts in the observations.parquet metadata. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Each manifest source gains name, observations and dropped (null when the observations file predates the drop metadata), and the manifest gains data_license. SCHEMA_VERSION goes to 1.3.0. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
ATTRIBUTION.txt lists every source used in a release with its licence and its attribution text verbatim, followed by the notices some licences require (the Statistics Canada conditions notice). DATA_LICENSE gains the dataset's own attribution line. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
DATASET_CARD.md describes the files, fields, sources, coverage, suppression, known limitations, licence and citation of a release, from the manifest, sources.yaml and the per-country rows. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
build and run now also write DATA_LICENSE (copied from --data-license), ATTRIBUTION.txt, DATASET_CARD.md, a deterministic by_country.zip and a GNU-format SHA256SUMS covering every top-level file, all inside the same atomic temporary directory. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
tools/release.sh checks the CalVer name, builds offline, verifies SHA256SUMS and uploads the assets to a draft release without overwriting, then removes the raw source cache from the draft. The release workflow runs it on CalVer tags; manual dispatch and CI run a dry run on the fixture samples. Nothing publishes a release or creates a tag. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
README gains the release layout, verification, citation and the local dry run; AGENTS.md gains the step-by-step release procedure; spec 001 gains notes pointing to spec 006 and ADR 0015. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
GH_TOKEN and GH_REPO reach only the two steps that call gh, checkout no longer persists credentials, every action is pinned by commit SHA and the release job runs setup-uv without cache. release.sh lists the draft's assets without a grep pipe, fails if the listing fails, confirms the source cache is gone after deleting it, and only treats 'release not found' as a missing draft. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
The owner decided to keep legacy/ as a frozen historical archive. ADR 0015 is rewritten as accepted with that decision, and spec 006, its plan and tasks, spec 001 and the roadmap follow it. README mentions sha256sum --ignore-missing and AGENTS.md uses <saída>. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This was referenced Oct 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Spec 006 (publicação): o build passa a gerar uma release publicável, os descartes por fonte entram no manifesto e um workflow monta a release a partir do cache sem publicá-la. Spec, plano e tarefas em
docs/specs/006-publicacao/; ADRs 0014 (processo de release) e 0015 (retirada do legado).Status: Em implementação.
O que mudou
RawDrop(name, count)no protocolo do adaptador. O pipeline conta linhas, registros e formas por fonte, avisa no loggernamescommons.pipeline, eingestgrava os números nos metadados doobservations.parquet(namescommons.dropped), quebuildlê. Onz-dia-birthsdeixou de usarlogging.data_license: "CC-BY-4.0"e, por fonte,name,observationsedropped(nullquando o Parquet é anterior).filescontinua só com as tabelas.SCHEMA_VERSION1.3.0.ATTRIBUTION.txtgerado desources.yaml: linha de atribuição do dataset, um bloco por fonte usada com oattributionsem edição, e a seção de avisos com o aviso de condições da Statistics Canada só quando ela está na release. Tabela de licenças com uma entrada por licença aceita; licença sem entrada faz o build falhar.DATA_LICENSEganhou o preâmbulo com a linha de atribuição do dataset.DATASET_CARD.md(inglês): resumo, arquivos, campos, fontes (com supressão e descartes), cobertura por país, supressão, limitações conhecidas (fontes sem acento, caixa uniforme, nomes corrompidos descartados,group_idpor release, retrato do Wikidata no QLever,female_share), licença com os avisos da Statistics Canada e citação.build/rungravam tambémDATA_LICENSE(opção--data-license),ATTRIBUTION.txt,DATASET_CARD.md,by_country.zipdeterminístico eSHA256SUMSno formato GNU, tudo no mesmo diretório temporário atômico. Layout compatível com a seção 5 do plano da spec 001 do tools-dataset (R5, R6, R9 de lá); entradas de benchmark continuam na Export deterministic benchmark inputs for catalog-algorithms #24.tools/release.sh(check,fixture-cache,fetch-cache,build,verify,upload) e.github/workflows/release.yml: na tag CalVer, baixasource-cache.tar.gzdo rascunho, build offline, confere somas, envia ao rascunho sem sobrescrever e só então remove o cache do rascunho. Oworkflow_dispatché sempre ensaio sobre as amostras; a CI roda o mesmo ensaio em todo PR. Nada publica release nem cria tag..gitignore(Spec 006: README, licença e .gitignore (pendências da 001) #5). Linha em branco dupla e.venv/da seção do mypy removidos; Parquet permitido emtests/fixtures/.AGENTS.md(procedimento de release passo a passo, incluindo conferir a licença da Statistics Canada), notas na spec 001, ROADMAP (006 Em PR; 007 marcada Mesclada).Critérios de aceite e verificação
Tabela completa em
docs/specs/006-publicacao/tasks.md. Resumo:uv sync --lockedeuv run pytest -qcom 653 testes verdes, sem rede; os passos offline da CI passam localmente (tests/test_ci.py);tools/release.sh buildduas vezes sobre as amostras dádiff -rvazio esha256sum -c SHA256SUMSOK; envio testado comghfalso (CalVer, rascunho ausente, release publicada, sem sobrescrever, remoção do cache depois do envio, saída adulterada);shellchecksem avisos. Nenhuma tag, rascunho ou release foi criado.Legado: mantido congelado
Decisão do dono:
legacy/fica no repositório como arquivo histórico congelado, sem nenhuma remoção nem alteração. Não é ingerido, não entra em nenhum arquivo das releases e está fora do contrato de entradas do tools-dataset (R1.3 de lá). O ADR 0015 (docs/adr/0015-legado-congelado.md, Aceito) registra a decisão e as consequências;git diff origin/master -- legacy/é vazio.Correções da revisão independente
release.yml:GH_TOKEN/GH_REPOsó nos passos que chamam ogh(cache do rascunho e envio);persist-credentials: falseno checkout; todas as actions fixadas por SHA de commit com comentário da tag;enable-cache: falseno setup-uv do jobrelease.tools/release.sh: a lista de assets do rascunho fica numa variável (sem pipe comgrep -q), falha doghderruba o passo, e depois dodelete-asseta lista é conferida de novo; só "release not found" conta como rascunho ausente, outro erro mostra a mensagem real. Testes novos com oghfalso.sha256sum -c --ignore-missing SHA256SUMSpara download parcial.AGENTS.md:<saída>.Decisões tomadas sozinho (e o custo se estiverem erradas)
source-cache.tar.gz(ADR 0014). Custo: se oghse comportar diferente com rascunhos do que o documentado, o primeiro envio real falha (sem publicar nada) e o script precisa de ajuste; o caminho real só foi testado comghfalso.source-cache.tar.gzdo rascunho depois do envio, para os brutos das fontes nunca serem publicados. Custo: o dono precisa guardar a cópia local do cache.by_country.zip(releases não aceitam diretórios) eATTRIBUTION.txtem texto puro (nome do contrato do tools-dataset). Custo: trocar de formato depois muda os assets e exige release nova.SCHEMA_VERSION1.3.0 (menor): campos e arquivos novos, nenhum significado mudou.Issues
Closes #22
Closes #32
Closes #42
Closes #5 (todos os itens cumpridos: README no PR #19; atribuições,
.gitignoree a decisão sobrelegacy/aqui)Criadas: #42 (decisão sobre o legado, fechada por este PR), #43 (nomes e atribuições de
sources.yamlem português nos arquivos em inglês), #44 (versionardata/by_country/*.csv, spec 001 R4).Acompanhamento da revisão: #46 (tag assinada e em master), #47 (zip e zlib), #48 (insumos de benchmark antes do SHA256SUMS), #49 (cabeçalho do ATTRIBUTION.txt, com #43), #50 (validar licença no início do build), #51 (fonte só de ligações como "unknown" no cartão), #52 (checklist da primeira release real).
🤖 Generated with Claude Code