pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/textproc/py-ramlfications
Module Name: pkgsrc
Committed By: adam
Date: Tue Nov 10 09:23:50 UTC 2026
Modified Files:
pkgsrc/textproc/py-ramlfications: Makefile PLIST distinfo
Log Message:
py-ramlfications: updated to 0.3.0
0.3.0 (2026-10-25)
Added:
- RAML 1.0 support, dispatched automatically from the ``#%RAML`` header
at the existing ``parse()``/``load()``/``validate()`` entry points:
* data types with inheritance, facets, and type expressions
(named types, arrays ``T[]``, unions ``A | B``)
* ``annotationTypes`` declarations and annotations applied on
resources and methods
* ``uses`` libraries with dotted ``LibName.member`` references,
including libraries used by other libraries
* typed fragments (DataType, Trait, ResourceType, Library,
SecurityScheme, DocumentationItem), parsed standalone or included
* Overlay and Extension documents with RAML 1.0 merge semantics;
overlays may not change behavioral aspects of their target
* security scheme updates (RAML 1.0 OAuth 2.0 grants and ``null``
``securedBy`` for optional security)
* the RAML 1.0 parameter functions ``!uppercase``, ``!lowercase``,
``!lowercamelcase``, ``!uppercamelcase``, ``!lowerunderscorecase``,
``!upperunderscorecase``, ``!lowerhyphencase`` and
``!upperhyphencase`` (``<<name | !uppercase>>``); RAML 0.8
documents keep only ``!singularize`` and ``!pluralize``
- Version-routed validation: RAML 1.0-only constructs are rejected in
0.8 documents and vice versa, and RAML 1.0 rules (unresolvable type
references, annotation value conformance) report located errors that
are collected rather than failing at the first one.
Changed:
- Python 3.10+ is now the minimum supported version; Python 2 era
compatibility shims have been removed.
- Dependencies modernized (PyYAML 6.x, current attrs).
- A RAML 0.8 resource assigned a resource type with ``type:`` now gets
that type's required (non-``?``) methods, including those of the
type's own ``type:``, as resource nodes. A resource that only declared
``type:`` used to produce a single node with ``method=None``; it now
produces one node per inherited method, so ``len(api.resources)``
grows for such APIs. Methods the resource declares itself keep their
order and come first.
- Validation follows the RAML specification where it was stricter:
RAML 1.0 documents without ``baseUri`` validate (the spec makes it
OPTIONAL); RAML 0.8 documents without ``baseUri`` validate when the
config sets ``production = False`` (a missing ``production`` still
requires it); APIs without resources validate; ``baseUriParameters``
accept any named-parameter type, not only ``string``.
- A placeholder name must match the parameter exactly: ``<<item-x>>``
is no longer treated as the parameter ``item``.
Fixed:
- RAML 0.8 resource type/trait inheritance edge cases, including
optional (``?``) properties.
- ``!include`` resolution (nested includes, relative paths, and
missing-file errors).
- ``<<resourcePathName>>`` is the rightmost path segment for nested
resources (``widget`` for ``/root/widget``, previously ``root/widget``)
and is now also substituted when ``type:`` is a plain name.
- Resource type and trait parameters (e.g. ``<<resourceType>>``) are
substituted in inherited scalar values such as ``description``.
- Inheriting a scalar value through a resource type that has its own
``type:`` no longer raises ``TypeError``, and cyclic ``type:`` chains
no longer raise ``RecursionError``.
- ``ramlfications tree -vv``/``-vvv`` lists form parameters declared
under a form ``body`` (``ResourceNode.form_params`` is unchanged).
- A resource declared with no value (``/empty:``) parses as a resource
without properties instead of raising ``AttributeError``.
- RAML 1.0 ``<<resourcePathName>>`` skips path segments that contain a
URI parameter (``users`` for ``/users/{id}``), as the RAML 1.0 spec
defines; RAML 0.8 keeps the rightmost segment (``{id}``).
- Parameters a resource type passes to its own ``type:`` (e.g.
``type: {base: {thing: <<item>>}}``) are substituted in what it
inherits from that type.
- A ``documentation`` value that is not a list, and unknown facets in a
RAML 1.0 type declaration, raise ``InvalidRAMLStructureError`` instead
of ``AssertionError`` / ``TypeError``.
- ``absolute_uri`` is a string (the resource path) when the API has no
``baseUri``; it used to be a one-element list.
- URI/base URI parameter handling (implicit template parameters and
explicit overrides).
- Passing a config file without a ``[main] validate`` option to
``parse()`` or ``ramlfications tree -c`` no longer turns validation
off; such files now validate, as documented. To turn validation off,
set ``validate = False`` (the older spelling ``validation`` is still
accepted when ``validate`` is not set).
- ``ramlfications tree -V``/``--validate`` now validates the file even
when the config file turns validation off; the flag used to be
ignored.
- Placeholders next to each other are substituted independently:
``<<thing>>-<<resourcePathName>>`` gives ``gizmo-widgets`` instead of
losing everything after ``gizmo``.
- ``!singularize`` and ``!pluralize`` leave a value that already has the
requested form unchanged (``/user`` with ``!singularize`` used to give
``False``, and ``/users`` with ``!pluralize`` gave ``user``).
- An unknown parameter function, or a RAML 1.0 function in a RAML 0.8
document, raises ``InvalidRAMLStructureError`` naming the function
instead of ``AttributeError``/``TypeError``.
- A parameter function applied to a number or boolean value (for example
``thing: 5`` with ``<<thing | !uppercase>>``) transforms its text form
instead of raising ``AttributeError``/``TypeError``.
To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 pkgsrc/textproc/py-ramlfications/Makefile
cvs rdiff -u -r1.3 -r1.4 pkgsrc/textproc/py-ramlfications/PLIST
cvs rdiff -u -r1.4 -r1.5 pkgsrc/textproc/py-ramlfications/distinfo
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/textproc/py-ramlfications/Makefile
diff -u pkgsrc/textproc/py-ramlfications/Makefile:1.12 pkgsrc/textproc/py-ramlfications/Makefile:1.13
--- pkgsrc/textproc/py-ramlfications/Makefile:1.12 Fri Oct 16 19:44:19 2026
+++ pkgsrc/textproc/py-ramlfications/Makefile Tue Nov 10 09:23:50 2026
@@ -1,8 +1,7 @@
-# $NetBSD: Makefile,v 1.12 2026/10/16 19:44:19 adam Exp $
+# $NetBSD: Makefile,v 1.13 2026/11/10 09:23:50 adam Exp $
-DISTNAME= ramlfications-0.2.2
+DISTNAME= ramlfications-0.3.0
PKGNAME= ${PYPKGPREFIX}-${DISTNAME}
-PKGREVISION= 1
CATEGORIES= textproc python
MASTER_SITES= ${MASTER_SITE_PYPI:=r/ramlfications/}
@@ -12,26 +11,23 @@ COMMENT= Python RAML parser
LICENSE= apache-2.0
TOOL_DEPENDS+= ${PYPKGPREFIX}-setuptools>=78:../../devel/py-setuptools
-DEPENDS+= ${PYPKGPREFIX}-attrs-[0-9]*:../../devel/py-attrs
-DEPENDS+= ${PYPKGPREFIX}-click-[0-9]*:../../devel/py-click
-DEPENDS+= ${PYPKGPREFIX}-inflect-[0-9]*:../../lang/py-inflect
-DEPENDS+= ${PYPKGPREFIX}-jsonref-[0-9]*:../../textproc/py-jsonref
-DEPENDS+= ${PYPKGPREFIX}-markdown2-[0-9]*:../../textproc/py-markdown2
-DEPENDS+= ${PYPKGPREFIX}-six-[0-9]*:../../lang/py-six
-DEPENDS+= ${PYPKGPREFIX}-termcolor-[0-9]*:../../devel/py-termcolor
-DEPENDS+= ${PYPKGPREFIX}-xmltodict-[0-9]*:../../textproc/py-xmltodict
-DEPENDS+= ${PYPKGPREFIX}-yaml-[0-9]*:../../textproc/py-yaml
-TEST_DEPENDS+= ${PYPKGPREFIX}-mock-[0-9]*:../../devel/py-mock
-TEST_DEPENDS+= ${PYPKGPREFIX}-test-mock-[0-9]*:../../devel/py-test-mock
-TEST_DEPENDS+= ${PYPKGPREFIX}-test-localserver-[0-9]*:../../devel/py-test-localserver
+DEPENDS+= ${PYPKGPREFIX}-attrs>=0:../../devel/py-attrs
+DEPENDS+= ${PYPKGPREFIX}-click>=0:../../devel/py-click
+DEPENDS+= ${PYPKGPREFIX}-inflect>=0:../../lang/py-inflect
+DEPENDS+= ${PYPKGPREFIX}-jsonref>=0:../../textproc/py-jsonref
+DEPENDS+= ${PYPKGPREFIX}-markdown2>=0:../../textproc/py-markdown2
+DEPENDS+= ${PYPKGPREFIX}-termcolor>=0:../../devel/py-termcolor
+DEPENDS+= ${PYPKGPREFIX}-xmltodict>=0:../../textproc/py-xmltodict
+DEPENDS+= ${PYPKGPREFIX}-yaml>=0:../../textproc/py-yaml
+TEST_DEPENDS+= ${PYPKGPREFIX}-mock>=0:../../devel/py-mock
+TEST_DEPENDS+= ${PYPKGPREFIX}-test-mock>=0:../../devel/py-test-mock
+TEST_DEPENDS+= ${PYPKGPREFIX}-test-localserver>=0:../../devel/py-test-localserver
USE_LANGUAGES= # none
-PYTHON_VERSIONS_INCOMPATIBLE= 311
+PY_RENAME_BINARIES= ramlfications
-post-install:
- cd ${DESTDIR}${PREFIX}/bin && \
- ${MV} ramlfications ramlfications-${PYVERSSUFFIX} || ${TRUE}
+PYTHON_VERSIONS_INCOMPATIBLE= 311
.include "../../lang/python/wheel.mk"
.include "../../mk/bsd.pkg.mk"
Index: pkgsrc/textproc/py-ramlfications/PLIST
diff -u pkgsrc/textproc/py-ramlfications/PLIST:1.3 pkgsrc/textproc/py-ramlfications/PLIST:1.4
--- pkgsrc/textproc/py-ramlfications/PLIST:1.3 Mon Apr 14 12:50:20 2025
+++ pkgsrc/textproc/py-ramlfications/PLIST Tue Nov 10 09:23:50 2026
@@ -1,10 +1,9 @@
-@comment $NetBSD: PLIST,v 1.3 2025/04/14 12:50:20 adam Exp $
+@comment $NetBSD: PLIST,v 1.4 2026/11/10 09:23:50 adam Exp $
bin/ramlfications-${PYVERSSUFFIX}
${PYSITELIB}/${WHEEL_INFODIR}/METADATA
${PYSITELIB}/${WHEEL_INFODIR}/RECORD
${PYSITELIB}/${WHEEL_INFODIR}/WHEEL
${PYSITELIB}/${WHEEL_INFODIR}/entry_points.txt
-${PYSITELIB}/${WHEEL_INFODIR}/licenses/AUTHORS.rst
${PYSITELIB}/${WHEEL_INFODIR}/licenses/LICENSE
${PYSITELIB}/${WHEEL_INFODIR}/top_level.txt
${PYSITELIB}/ramlfications/__init__.py
@@ -13,9 +12,6 @@ ${PYSITELIB}/ramlfications/__init__.pyo
${PYSITELIB}/ramlfications/__main__.py
${PYSITELIB}/ramlfications/__main__.pyc
${PYSITELIB}/ramlfications/__main__.pyo
-${PYSITELIB}/ramlfications/_helpers.py
-${PYSITELIB}/ramlfications/_helpers.pyc
-${PYSITELIB}/ramlfications/_helpers.pyo
${PYSITELIB}/ramlfications/config.py
${PYSITELIB}/ramlfications/config.pyc
${PYSITELIB}/ramlfications/config.pyo
@@ -71,15 +67,15 @@ ${PYSITELIB}/ramlfications/models/securi
${PYSITELIB}/ramlfications/models/traits.py
${PYSITELIB}/ramlfications/models/traits.pyc
${PYSITELIB}/ramlfications/models/traits.pyo
-${PYSITELIB}/ramlfications/parser.py
-${PYSITELIB}/ramlfications/parser.pyc
-${PYSITELIB}/ramlfications/parser.pyo
${PYSITELIB}/ramlfications/parser/__init__.py
${PYSITELIB}/ramlfications/parser/__init__.pyc
${PYSITELIB}/ramlfications/parser/__init__.pyo
${PYSITELIB}/ramlfications/parser/base.py
${PYSITELIB}/ramlfications/parser/base.pyc
${PYSITELIB}/ramlfications/parser/base.pyo
+${PYSITELIB}/ramlfications/parser/fragments.py
+${PYSITELIB}/ramlfications/parser/fragments.pyc
+${PYSITELIB}/ramlfications/parser/fragments.pyo
${PYSITELIB}/ramlfications/parser/mixins.py
${PYSITELIB}/ramlfications/parser/mixins.pyc
${PYSITELIB}/ramlfications/parser/mixins.pyo
@@ -95,21 +91,27 @@ ${PYSITELIB}/ramlfications/parser/types.
${PYSITELIB}/ramlfications/tree.py
${PYSITELIB}/ramlfications/tree.pyc
${PYSITELIB}/ramlfications/tree.pyo
-${PYSITELIB}/ramlfications/utils.py
-${PYSITELIB}/ramlfications/utils.pyc
-${PYSITELIB}/ramlfications/utils.pyo
${PYSITELIB}/ramlfications/utils/__init__.py
${PYSITELIB}/ramlfications/utils/__init__.pyc
${PYSITELIB}/ramlfications/utils/__init__.pyo
+${PYSITELIB}/ramlfications/utils/annotations.py
+${PYSITELIB}/ramlfications/utils/annotations.pyc
+${PYSITELIB}/ramlfications/utils/annotations.pyo
${PYSITELIB}/ramlfications/utils/common.py
${PYSITELIB}/ramlfications/utils/common.pyc
${PYSITELIB}/ramlfications/utils/common.pyo
${PYSITELIB}/ramlfications/utils/examples.py
${PYSITELIB}/ramlfications/utils/examples.pyc
${PYSITELIB}/ramlfications/utils/examples.pyo
+${PYSITELIB}/ramlfications/utils/libraries.py
+${PYSITELIB}/ramlfications/utils/libraries.pyc
+${PYSITELIB}/ramlfications/utils/libraries.pyo
${PYSITELIB}/ramlfications/utils/nodelist.py
${PYSITELIB}/ramlfications/utils/nodelist.pyc
${PYSITELIB}/ramlfications/utils/nodelist.pyo
+${PYSITELIB}/ramlfications/utils/overlays.py
+${PYSITELIB}/ramlfications/utils/overlays.pyc
+${PYSITELIB}/ramlfications/utils/overlays.pyo
${PYSITELIB}/ramlfications/utils/parameter.py
${PYSITELIB}/ramlfications/utils/parameter.pyc
${PYSITELIB}/ramlfications/utils/parameter.pyo
@@ -137,6 +139,9 @@ ${PYSITELIB}/ramlfications/validate/node
${PYSITELIB}/ramlfications/validate/parameters.py
${PYSITELIB}/ramlfications/validate/parameters.pyc
${PYSITELIB}/ramlfications/validate/parameters.pyo
+${PYSITELIB}/ramlfications/validate/raml10.py
+${PYSITELIB}/ramlfications/validate/raml10.pyc
+${PYSITELIB}/ramlfications/validate/raml10.pyo
${PYSITELIB}/ramlfications/validate/root.py
${PYSITELIB}/ramlfications/validate/root.pyc
${PYSITELIB}/ramlfications/validate/root.pyo
Index: pkgsrc/textproc/py-ramlfications/distinfo
diff -u pkgsrc/textproc/py-ramlfications/distinfo:1.4 pkgsrc/textproc/py-ramlfications/distinfo:1.5
--- pkgsrc/textproc/py-ramlfications/distinfo:1.4 Thu Jun 13 05:15:58 2024
+++ pkgsrc/textproc/py-ramlfications/distinfo Tue Nov 10 09:23:50 2026
@@ -1,5 +1,5 @@
-$NetBSD: distinfo,v 1.4 2024/06/13 05:15:58 adam Exp $
+$NetBSD: distinfo,v 1.5 2026/11/10 09:23:50 adam Exp $
-BLAKE2s (ramlfications-0.2.2.tar.gz) = ab145265ec67dd6419833f081f8678131aff53637116711a4d0f43c3ecab141a
-SHA512 (ramlfications-0.2.2.tar.gz) = fbf0ef577dfbf99ee0747bdf98a507e214cbcf70c78b9abff105dd71b27f875ad3662c740c74b6ce65509e93fdfa07a68b8c4c4b4a3589ef5759e9b25b4e48bd
-Size (ramlfications-0.2.2.tar.gz) = 1155837 bytes
+BLAKE2s (ramlfications-0.3.0.tar.gz) = f04a4bc4d31d48008d405ce2185c0d2931a81b604e81972ec84a857e7c6b402d
+SHA512 (ramlfications-0.3.0.tar.gz) = 1f1e6d81898a2e8916573ef9c810f5b85731333822af4822f7df44ab36df454299182f6b151c69c01047b718e2f4c233d2a0eab0b511205a959b728b5566d7e6
+Size (ramlfications-0.3.0.tar.gz) = 1182435 bytes
Home |
Main Index |
Thread Index |
Old Index