Repository navigation
feat(metadata): document curated CNES LT fields - #392
Open
elvispcavalcante wants to merge 1 commit into
Open
elvispcavalcante wants to merge 1 commit into
elvispcavalcante wants to merge 1 commit into
Conversation
Add a curated CNES hospital bed (LT) column schema, sourced from the DATASUS CNES 2017-06 technical layout and the TabWin TAB_CNES package, and checked against the official LTCE2610 file. Refs AlertaDengue#232
This branch has not been deployed
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.
Refs #232
Follows the format of #383 (CNES ST) and adds a curated schema for CNES LT (hospital beds).
Changes
pysus/api/metadata/schemas/cnes/lt.yaml: 10 columns (CNES, CODUFMUN, TP_LEITO, CODLEITO, QT_EXIST, QT_CONTR, QT_SUS, QT_NSUS, COMPETEN, NAT_JUR) with PT/EN descriptions. TP_LEITO and CODLEITO include their category codes.test_columns.pyandtest_metadata_columns.pycover search by endpoint, description and bed specialty, load a synthetic row shaped like LTCE2610, and check thatavailable_groups("cnes") == ["lt", "st"]. The "uncovered group" tests now usepf.docs/source/guides/columns.rst: describes the LT coverage and adds aload_column_metadata("cnes", "lt")example.No change to
pysus/api/columns.pywas needed, since it already loads every CNES group.Sources (also cited in the YAML header)
TAB_CNES.zip(Oct 2026):Leitos_Especialidade.def,tip1leit.cnv,Esp_leit.CNVLTCE2610fileNotes from that check:
Leitos_Especialidade.defas QT_EXIST - QT_SUS, which held for every row.Esp_leit.CNV.Checks
pytest pysus/tests/api/test_columns.py pysus/tests/api/test_metadata_columns.py: 43 passedpre-commiton the changed files: passedsphinx-build -W: no new warnings from this change (the local warnings are identical onmain)