pysdmx 1.11.0__tar.gz → 1.12.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (175) hide show
  1. {pysdmx-1.11.0 → pysdmx-1.12.0}/PKG-INFO +1 -1
  2. {pysdmx-1.11.0 → pysdmx-1.12.0}/pyproject.toml +1 -1
  3. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/__init__.py +1 -1
  4. pysdmx-1.12.0/src/pysdmx/io/json/fusion/messages/constraint.py +42 -0
  5. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/dsd.py +1 -0
  6. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/schema.py +20 -1
  7. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/schema.py +38 -5
  8. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/dataflow.py +9 -0
  9. pysdmx-1.11.0/src/pysdmx/io/json/fusion/messages/constraint.py +0 -21
  10. {pysdmx-1.11.0 → pysdmx-1.12.0}/LICENSE +0 -0
  11. {pysdmx-1.11.0 → pysdmx-1.12.0}/README.rst +0 -0
  12. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/__extras_check.py +0 -0
  13. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/__init__.py +0 -0
  14. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/dc/__init__.py +0 -0
  15. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/dc/_api.py +0 -0
  16. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/dc/query/__init__.py +0 -0
  17. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/dc/query/_model.py +0 -0
  18. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/dc/query/_parsing_model.py +0 -0
  19. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/dc/query/_parsing_util.py +0 -0
  20. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/dc/query/_py_parser.py +0 -0
  21. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/dc/query/_sql_parser.py +0 -0
  22. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/dc/query/util.py +0 -0
  23. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/fmr/__init__.py +0 -0
  24. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/fmr/maintenance.py +0 -0
  25. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/gds/__init__.py +0 -0
  26. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/qb/__init__.py +0 -0
  27. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/qb/availability.py +0 -0
  28. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/qb/data.py +0 -0
  29. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/qb/gds.py +0 -0
  30. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/qb/refmeta.py +0 -0
  31. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/qb/registration.py +0 -0
  32. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/qb/schema.py +0 -0
  33. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/qb/service.py +0 -0
  34. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/qb/structure.py +0 -0
  35. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/api/qb/util.py +0 -0
  36. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/errors.py +0 -0
  37. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/__init__.py +0 -0
  38. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/csv/__csv_aux_reader.py +0 -0
  39. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/csv/__csv_aux_writer.py +0 -0
  40. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/csv/__init__.py +0 -0
  41. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/csv/sdmx10/__init__.py +0 -0
  42. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/csv/sdmx10/reader/__init__.py +0 -0
  43. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/csv/sdmx10/writer/__init__.py +0 -0
  44. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/csv/sdmx20/__init__.py +0 -0
  45. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/csv/sdmx20/reader/__init__.py +0 -0
  46. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/csv/sdmx20/writer/__init__.py +0 -0
  47. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/csv/sdmx21/__init__.py +0 -0
  48. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/csv/sdmx21/reader/__init__.py +0 -0
  49. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/csv/sdmx21/writer/__init__.py +0 -0
  50. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/format.py +0 -0
  51. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/input_processor.py +0 -0
  52. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/__init__.py +0 -0
  53. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/category.py +0 -0
  54. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/code.py +0 -0
  55. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/concept.py +0 -0
  56. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/core.py +0 -0
  57. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/dataflow.py +0 -0
  58. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/map.py +0 -0
  59. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/metadataflow.py +0 -0
  60. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/mpa.py +0 -0
  61. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/msd.py +0 -0
  62. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/org.py +0 -0
  63. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/pa.py +0 -0
  64. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/report.py +0 -0
  65. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/messages/vtl.py +0 -0
  66. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/fusion/reader/__init__.py +0 -0
  67. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/gds/messages/__init__.py +0 -0
  68. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/gds/messages/agencies.py +0 -0
  69. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/gds/messages/catalog.py +0 -0
  70. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/gds/messages/sdmx_api.py +0 -0
  71. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/gds/messages/services.py +0 -0
  72. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/gds/messages/urn_resolver.py +0 -0
  73. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/gds/reader/__init__.py +0 -0
  74. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/__init__.py +0 -0
  75. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/agency.py +0 -0
  76. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/category.py +0 -0
  77. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/code.py +0 -0
  78. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/concept.py +0 -0
  79. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/constraint.py +0 -0
  80. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/core.py +0 -0
  81. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/dataflow.py +0 -0
  82. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/dsd.py +0 -0
  83. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/map.py +0 -0
  84. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/metadataflow.py +0 -0
  85. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/mpa.py +0 -0
  86. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/msd.py +0 -0
  87. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/pa.py +0 -0
  88. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/provider.py +0 -0
  89. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/report.py +0 -0
  90. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/structure.py +0 -0
  91. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/messages/vtl.py +0 -0
  92. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/reader/__init__.py +0 -0
  93. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/reader/doc_validation.py +0 -0
  94. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/reader/metadata.py +0 -0
  95. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/reader/structure.py +0 -0
  96. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/writer/__init__.py +0 -0
  97. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/writer/_helper.py +0 -0
  98. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/writer/v2_0/__init__.py +0 -0
  99. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/writer/v2_0/metadata.py +0 -0
  100. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/writer/v2_0/structure.py +0 -0
  101. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/writer/v2_1/__init__.py +0 -0
  102. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/writer/v2_1/metadata.py +0 -0
  103. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/json/sdmxjson2/writer/v2_1/structure.py +0 -0
  104. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/pd.py +0 -0
  105. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/reader.py +0 -0
  106. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/serde.py +0 -0
  107. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/writer.py +0 -0
  108. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/__allowed_lxml_errors.py +0 -0
  109. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/__data_aux.py +0 -0
  110. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/__init__.py +0 -0
  111. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/__parse_xml.py +0 -0
  112. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/__ss_aux_reader.py +0 -0
  113. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/__structure_aux_reader.py +0 -0
  114. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/__structure_aux_writer.py +0 -0
  115. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/__tokens.py +0 -0
  116. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/__write_aux.py +0 -0
  117. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/__write_data_aux.py +0 -0
  118. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/__write_structure_specific_aux.py +0 -0
  119. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/config.py +0 -0
  120. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/doc_validation.py +0 -0
  121. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/header.py +0 -0
  122. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx21/__init__.py +0 -0
  123. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx21/reader/__init__.py +0 -0
  124. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx21/reader/error.py +0 -0
  125. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx21/reader/generic.py +0 -0
  126. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx21/reader/structure.py +0 -0
  127. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx21/reader/structure_specific.py +0 -0
  128. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx21/reader/submission.py +0 -0
  129. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx21/writer/__init__.py +0 -0
  130. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx21/writer/error.py +0 -0
  131. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx21/writer/generic.py +0 -0
  132. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx21/writer/structure.py +0 -0
  133. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx21/writer/structure_specific.py +0 -0
  134. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx30/__init__.py +0 -0
  135. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx30/reader/__init__.py +0 -0
  136. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx30/reader/structure.py +0 -0
  137. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx30/reader/structure_specific.py +0 -0
  138. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx30/writer/__init__.py +0 -0
  139. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx30/writer/structure.py +0 -0
  140. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx30/writer/structure_specific.py +0 -0
  141. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx31/__init__.py +0 -0
  142. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx31/reader/__init__.py +0 -0
  143. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx31/reader/structure.py +0 -0
  144. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx31/reader/structure_specific.py +0 -0
  145. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx31/writer/__init__.py +0 -0
  146. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx31/writer/structure.py +0 -0
  147. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/sdmx31/writer/structure_specific.py +0 -0
  148. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/io/xml/utils.py +0 -0
  149. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/__base.py +0 -0
  150. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/__init__.py +0 -0
  151. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/category.py +0 -0
  152. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/code.py +0 -0
  153. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/concept.py +0 -0
  154. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/constraint.py +0 -0
  155. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/dataset.py +0 -0
  156. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/gds.py +0 -0
  157. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/map.py +0 -0
  158. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/message.py +0 -0
  159. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/metadata.py +0 -0
  160. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/organisation.py +0 -0
  161. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/submission.py +0 -0
  162. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/model/vtl.py +0 -0
  163. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/py.typed +0 -0
  164. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/toolkit/__init__.py +0 -0
  165. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/toolkit/pd/__init__.py +0 -0
  166. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/toolkit/pd/_data_utils.py +0 -0
  167. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/toolkit/vtl/__init__.py +0 -0
  168. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/toolkit/vtl/_validations.py +0 -0
  169. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/toolkit/vtl/convert.py +0 -0
  170. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/toolkit/vtl/script_generation.py +0 -0
  171. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/toolkit/vtl/validation.py +0 -0
  172. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/util/__init__.py +0 -0
  173. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/util/_date_pattern_map.py +0 -0
  174. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/util/_model_utils.py +0 -0
  175. {pysdmx-1.11.0 → pysdmx-1.12.0}/src/pysdmx/util/_net_utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pysdmx
3
- Version: 1.11.0
3
+ Version: 1.12.0
4
4
  Summary: Your opinionated Python SDMX library
5
5
  License: Apache-2.0
6
6
  License-File: LICENSE
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "pysdmx"
3
- version = "1.11.0"
3
+ version = "1.12.0"
4
4
  description = "Your opinionated Python SDMX library"
5
5
  license = { text = "Apache-2.0" }
6
6
  readme = "README.rst"
@@ -1,3 +1,3 @@
1
1
  """Your opinionated Python SDMX library."""
2
2
 
3
- __version__ = "1.11.0"
3
+ __version__ = "1.12.0"
@@ -0,0 +1,42 @@
1
+ """Collection of Fusion-JSON schemas for content constraints."""
2
+
3
+ from typing import Dict, List, Optional, Sequence
4
+
5
+ from msgspec import Struct
6
+
7
+
8
+ class FusionKeyValue(Struct, frozen=True):
9
+ """Fusion-JSON payload for the list of allowed values per component."""
10
+
11
+ values: Sequence[str]
12
+
13
+
14
+ class FusionKeySet(Struct, frozen=True):
15
+ """Fusion-JSON payload for the list of allowed values per component."""
16
+
17
+ dims: Sequence[str]
18
+ rows: Sequence[Sequence[str]]
19
+
20
+
21
+ class FusionContentConstraint(Struct, frozen=True):
22
+ """Fusion-JSON payload for a content constraint."""
23
+
24
+ includeCube: Dict[str, FusionKeyValue] = {}
25
+ includeSeries: Optional[FusionKeySet] = None
26
+
27
+ def to_map(self) -> Dict[str, Sequence[str]]:
28
+ """Gets the list of allowed values for a component."""
29
+ return {k: v.values for k, v in self.includeCube.items()}
30
+
31
+ def get_series(self, dimensions: List[str]) -> Sequence[str]:
32
+ """Get the list of series defined in the keyset."""
33
+ if self.includeSeries:
34
+ series = []
35
+ for r in self.includeSeries.rows:
36
+ s = dict.fromkeys(dimensions, "*")
37
+ for idx, cd in enumerate(self.includeSeries.dims):
38
+ s[cd] = r[idx]
39
+ series.append(".".join(s.values()))
40
+ return series
41
+ else:
42
+ return []
@@ -163,6 +163,7 @@ class FusionDimension(Struct, frozen=True):
163
163
  id: str
164
164
  concept: str
165
165
  representation: Optional[FusionRepresentation] = None
166
+ isTimeDimension: bool = False
166
167
 
167
168
  def to_model(
168
169
  self,
@@ -65,6 +65,25 @@ class FusionSchemaMessage(msgspec.Struct, frozen=True):
65
65
  mapped_grps = [
66
66
  Group(g.id, dimensions=g.dimensionReferences) for g in grps
67
67
  ]
68
+ keys: List[str] = []
69
+ for dc in self.DataConstraint:
70
+ keys.extend(
71
+ dc.get_series(
72
+ [
73
+ d.id
74
+ for d in self.DataStructure[0].dimensionList.dimensions
75
+ if not d.isTimeDimension
76
+ ]
77
+ )
78
+ )
79
+ keys = list(set(keys)) if keys else None # type: ignore[assignment]
68
80
  return Schema(
69
- context, agency, id_, comps, version, urns, groups=mapped_grps
81
+ context,
82
+ agency,
83
+ id_,
84
+ comps,
85
+ version,
86
+ urns,
87
+ groups=mapped_grps,
88
+ keys=keys,
70
89
  )
@@ -1,12 +1,15 @@
1
1
  """Collection of SDMX-JSON schemas for SDMX-REST schema queries."""
2
2
 
3
- from typing import Literal, Optional, Sequence, Tuple
3
+ from typing import Dict, Literal, Optional, Sequence, Tuple
4
4
 
5
5
  import msgspec
6
6
 
7
7
  from pysdmx.io.json.sdmxjson2.messages.code import JsonCodelist, JsonValuelist
8
8
  from pysdmx.io.json.sdmxjson2.messages.concept import JsonConceptScheme
9
- from pysdmx.io.json.sdmxjson2.messages.constraint import JsonDataConstraint
9
+ from pysdmx.io.json.sdmxjson2.messages.constraint import (
10
+ JsonDataConstraint,
11
+ JsonKeySet,
12
+ )
10
13
  from pysdmx.io.json.sdmxjson2.messages.core import JsonHeader
11
14
  from pysdmx.io.json.sdmxjson2.messages.dsd import JsonDataStructure
12
15
  from pysdmx.model import Components, HierarchyAssociation, Schema
@@ -25,7 +28,7 @@ class JsonSchemas(msgspec.Struct, frozen=True, omit_defaults=True):
25
28
 
26
29
  def to_model(
27
30
  self,
28
- ) -> Tuple[Components, Optional[Sequence[Group]]]:
31
+ ) -> Tuple[Components, Optional[Sequence[Group]], Optional[Sequence[str]]]:
29
32
  """Returns the requested schema."""
30
33
  comps = self.dataStructures[0].dataStructureComponents
31
34
  comps, grps = comps.to_model( # type: ignore[union-attr,assignment]
@@ -34,7 +37,36 @@ class JsonSchemas(msgspec.Struct, frozen=True, omit_defaults=True):
34
37
  self.valuelists,
35
38
  self.dataConstraints,
36
39
  )
37
- return comps, grps # type: ignore[return-value]
40
+ keys = self.__process_keys()
41
+ return comps, grps, keys # type: ignore[return-value]
42
+
43
+ def __extract_keys_dict(
44
+ self, keysets: Sequence[JsonKeySet]
45
+ ) -> Sequence[Dict[str, str]]:
46
+ keys = []
47
+ for ks in keysets:
48
+ keys.extend(
49
+ [{kv.id: kv.value for kv in k.keyValues} for k in ks.keys]
50
+ )
51
+ return keys
52
+
53
+ def __infer_keys(self, keys_dict: Dict[str, str]) -> str:
54
+ dimensions = [
55
+ d.id
56
+ for d in self.dataStructures[ # type: ignore[union-attr]
57
+ 0
58
+ ].dataStructureComponents.dimensionList.dimensions
59
+ ]
60
+ dim_values = [keys_dict.get(d, "*") for d in dimensions]
61
+ return ".".join(dim_values)
62
+
63
+ def __process_keys(self) -> Optional[Sequence[str]]:
64
+ keys = []
65
+ for c in self.dataConstraints:
66
+ if c.dataKeySets:
67
+ keys_dicts = self.__extract_keys_dict(c.dataKeySets)
68
+ keys.extend([self.__infer_keys(d) for d in keys_dicts])
69
+ return list(set(keys))
38
70
 
39
71
 
40
72
  class JsonSchemaMessage(msgspec.Struct, frozen=True, omit_defaults=True):
@@ -52,7 +84,7 @@ class JsonSchemaMessage(msgspec.Struct, frozen=True, omit_defaults=True):
52
84
  hierarchies: Sequence[HierarchyAssociation],
53
85
  ) -> Schema:
54
86
  """Returns the requested schema."""
55
- components, groups = self.data.to_model()
87
+ components, groups, keys = self.data.to_model()
56
88
  comp_dict = {c.id: c for c in components}
57
89
  urns = [a.urn for a in self.meta.links]
58
90
  for ha in hierarchies:
@@ -77,4 +109,5 @@ class JsonSchemaMessage(msgspec.Struct, frozen=True, omit_defaults=True):
77
109
  version,
78
110
  urns, # type: ignore[arg-type]
79
111
  groups=groups,
112
+ keys=keys,
80
113
  )
@@ -487,6 +487,14 @@ class Schema(Struct, frozen=True, omit_defaults=True, repr_omit_defaults=True):
487
487
  if any of the artefacts listed under the artefacts
488
488
  property has been updated after the schema was
489
489
  generated, you might want to regenerate the schema.
490
+ name: The schema name.
491
+ groups: The list of groups defined in the data structure.
492
+ keys: The list of allowed series. This is the equivalent
493
+ of an SDMX KeySet. KeySets allow finer
494
+ restrictions than when components only (i.e. SDMX
495
+ CubeRegions). The values in the sequence follow
496
+ the SDMX-REST conventions for series wildcarding
497
+ (e.g. *.USD.CHF.*).
490
498
  """
491
499
 
492
500
  context: Literal["datastructure", "dataflow", "provisionagreement"]
@@ -498,6 +506,7 @@ class Schema(Struct, frozen=True, omit_defaults=True, repr_omit_defaults=True):
498
506
  generated: datetime = datetime.now(timezone.utc)
499
507
  name: Optional[str] = None
500
508
  groups: Optional[Sequence[Group]] = None
509
+ keys: Optional[Sequence[str]] = None
501
510
 
502
511
  def __str__(self) -> str:
503
512
  """Custom string representation without the class name."""
@@ -1,21 +0,0 @@
1
- """Collection of Fusion-JSON schemas for content constraints."""
2
-
3
- from typing import Dict, Sequence
4
-
5
- from msgspec import Struct
6
-
7
-
8
- class FusionKeyValue(Struct, frozen=True):
9
- """Fusion-JSON payload for the list of allowed values per component."""
10
-
11
- values: Sequence[str]
12
-
13
-
14
- class FusionContentConstraint(Struct, frozen=True):
15
- """Fusion-JSON payload for a content constraint."""
16
-
17
- includeCube: Dict[str, FusionKeyValue] = {}
18
-
19
- def to_map(self) -> Dict[str, Sequence[str]]:
20
- """Gets the list of allowed values for a component."""
21
- return {k: v.values for k, v in self.includeCube.items()}
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes