commonground-api-common 2.3.0__tar.gz → 2.5.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.
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/CHANGELOG.rst +15 -0
- {commonground_api_common-2.3.0/commonground_api_common.egg-info → commonground_api_common-2.5.0}/PKG-INFO +2 -2
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0/commonground_api_common.egg-info}/PKG-INFO +2 -2
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/commonground_api_common.egg-info/requires.txt +1 -1
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/setup.cfg +2 -2
- commonground_api_common-2.5.0/tests/test_validators.py +106 -0
- commonground_api_common-2.5.0/vng_api_common/__init__.py +1 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/apps.py +2 -1
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/contrib/setup_configuration/models.py +10 -2
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/serializers.py +1 -1
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/validators.py +85 -33
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/views.py +2 -2
- commonground_api_common-2.3.0/tests/test_validators.py +0 -37
- commonground_api_common-2.3.0/vng_api_common/__init__.py +0 -1
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/MANIFEST.in +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/README.rst +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/bin/generate_schema +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/commonground_api_common.egg-info/SOURCES.txt +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/commonground_api_common.egg-info/dependency_links.txt +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/commonground_api_common.egg-info/not-zip-safe +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/commonground_api_common.egg-info/top_level.txt +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/pyproject.toml +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/setup.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_autorisatie_validation.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_cache_headers.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_check_query_params.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_checks.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_choices.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_configuration_steps_applicaties.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_configuration_steps_jwtsecrets.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_content_type_headers.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_field_extensions.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_filter_extension.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_filters.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_gegevensgroepen.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_get_resource.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_jwt_decoding.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_jwtsecrets.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_migrations.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_nested_serializer_validation.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_pagination.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_permissions.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_publish_validators.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_schema.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_serializer_extensions.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_server_errors.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_utils.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_views.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/admin.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/api/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/api/permissions.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/api/serializers.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/api/urls.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/api/views.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/admin.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/api/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/api/scopes.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/api/serializers.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/apps.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/audits.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0001_initial.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0002_auto_20190516_0830.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0003_auto_20190517_0844.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0004_auto_20190520_1238.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0005_auto_20190520_1450.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0006_audittrail_toelichting.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0007_auto_20190522_0916.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0008_audittrail_resource_weergave.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0009_auto_20190712_1643.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0010_audittrail_request_id.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0011_auto_20190918_1335.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0012_auto_20200619_0545.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0012_remove_audittrail_request_id.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0013_audittrail_logrecord_id.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0013_auto_20201207_0846.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0014_auto_20201221_0905.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0014_auto_20210323_1654.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0015_auto_20220318_1608.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0016_merge_20220607_0517.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0017_alter_audittrail_bron.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/0018_auto_20221212_0745.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/migrations/_operations.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/models.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/utils.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/viewsets.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/admin.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/middleware.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0001_initial.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0002_authorizationsconfig.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0003_auto_20190502_0409.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0004_auto_20190503_0941.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0005_auto_20190506_0842.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0006_auto_20190506_0901.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0007_auto_20190506_1212.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0008_auto_20190712_1541.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0009_update_enums.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0010_auto_20190712_1643.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0011_auto_20191114_0728.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0012_auto_20200619_0545.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0013_auto_20201207_0846.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0014_auto_20201221_0905.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0015_auto_20220318_1608.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/0016_remove_authorizationsconfig_api_root_and_more.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/migrations/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/models.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/serializers.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/utils.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/authorizations/validators.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/caching/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/caching/decorators.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/caching/etags.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/caching/introspection.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/caching/models.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/caching/registry.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/caching/signals.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/checks.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/choices.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/client.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/compat.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/conf/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/conf/api.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/constants.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/contrib/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/contrib/setup_configuration/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/contrib/setup_configuration/steps.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/db/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/db/operations.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/decorators.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/descriptors.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/doc.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/exception_handling.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/exceptions.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/extensions/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/extensions/file.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/extensions/gegevensgroep.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/extensions/geojson.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/extensions/hyperlink.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/extensions/polymorphic.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/extensions/query.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/fields.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/filters.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/filtersets.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/generators.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/geo.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/locale/nl/LC_MESSAGES/django.mo +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/locale/nl/LC_MESSAGES/django.po +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/middleware.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/migrations/0001_initial.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/migrations/0002_apicredential.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/migrations/0003_auto_20190417_1145.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/migrations/0004_auto_20190517_0903.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/migrations/0005_auto_20190614_1346.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/migrations/0006_delete_apicredential.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/migrations/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/mocks.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/models.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/api/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/api/urls.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/api/views.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/apps.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/handlers.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/migrations/0001_initial.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/migrations/0002_subscription__subscription.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/migrations/0003_auto_20190319_1048.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/migrations/0004_auto_20190325_1313.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/migrations/0005_fix_default_nrc.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/migrations/0006_auto_20190417_1142.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/migrations/0007_auto_20190429_1442.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/migrations/0008_auto_20190502_0415.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/migrations/0009_auto_20190729_0427.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/migrations/0010_auto_20220704_1419.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/migrations/0011_remove_subscription_config_and_more.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/notifications/migrations/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/oas.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/pagination.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/permissions.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/polymorphism.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/routers.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/schema.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/scopes.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/search.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/css/admin/admin_overrides.css +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/css/screen.css +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/ico/favicon.png +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/img/vng.svg +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/LICENSE.txt +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/css/all.css +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/css/all.min.css +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-brands-400.eot +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-brands-400.svg +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-brands-400.ttf +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-brands-400.woff +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-brands-400.woff2 +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-regular-400.eot +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-regular-400.svg +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-regular-400.ttf +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-regular-400.woff +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-regular-400.woff2 +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-solid-900.eot +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-solid-900.svg +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-solid-900.ttf +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-solid-900.woff +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/static/vng_api_common/libs/fontawesome/webfonts/fa-solid-900.woff2 +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/templates/vng_api_common/admin/base_site.html +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/templates/vng_api_common/includes/kanalen_card.html +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/templates/vng_api_common/index.html +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/templates/vng_api_common/master.html +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/templates/vng_api_common/ref/error_detail.html +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/templates/vng_api_common/ref/scopes.html +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/templates/vng_api_common/view_config.html +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/templatetags/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/templatetags/vng_api_common.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/tests/__init__.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/tests/auth.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/tests/caching.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/tests/schema.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/tests/urls.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/urls.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/utils.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/version.py +0 -0
- {commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/viewsets.py +0 -0
@@ -2,6 +2,21 @@
|
|
2
2
|
Change history
|
3
3
|
==============
|
4
4
|
|
5
|
+
2.5.0 (2025-02-06)
|
6
|
+
------------------
|
7
|
+
|
8
|
+
* Update setup-config docs to use example directive and add extra example values to models
|
9
|
+
|
10
|
+
2.4.1 (2025-01-14)
|
11
|
+
------------------
|
12
|
+
|
13
|
+
* Make geojson fields optional by catching ImproperlyConfigured errors
|
14
|
+
|
15
|
+
2.4.0 (2025-01-13)
|
16
|
+
------------------
|
17
|
+
|
18
|
+
* [#57] Improved validation of RSIN and BSN by creating a generic validator.
|
19
|
+
|
5
20
|
2.3.0 (2025-01-09)
|
6
21
|
------------------
|
7
22
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.2
|
2
2
|
Name: commonground-api-common
|
3
|
-
Version: 2.
|
3
|
+
Version: 2.5.0
|
4
4
|
Summary: Commonground API tooling
|
5
5
|
Home-page: https://github.com/maykinmedia/commonground-api-common
|
6
6
|
Author: Maykin Media, VNG-Realisatie
|
@@ -61,7 +61,7 @@ Requires-Dist: drf-extra-fields; extra == "tests"
|
|
61
61
|
Provides-Extra: testutils
|
62
62
|
Requires-Dist: zgw-consumers-oas; extra == "testutils"
|
63
63
|
Provides-Extra: setup-configuration
|
64
|
-
Requires-Dist: django-setup-configuration>=0.
|
64
|
+
Requires-Dist: django-setup-configuration>=0.7.0; extra == "setup-configuration"
|
65
65
|
Provides-Extra: pep8
|
66
66
|
Requires-Dist: flake8; extra == "pep8"
|
67
67
|
Provides-Extra: coverage
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.2
|
2
2
|
Name: commonground-api-common
|
3
|
-
Version: 2.
|
3
|
+
Version: 2.5.0
|
4
4
|
Summary: Commonground API tooling
|
5
5
|
Home-page: https://github.com/maykinmedia/commonground-api-common
|
6
6
|
Author: Maykin Media, VNG-Realisatie
|
@@ -61,7 +61,7 @@ Requires-Dist: drf-extra-fields; extra == "tests"
|
|
61
61
|
Provides-Extra: testutils
|
62
62
|
Requires-Dist: zgw-consumers-oas; extra == "testutils"
|
63
63
|
Provides-Extra: setup-configuration
|
64
|
-
Requires-Dist: django-setup-configuration>=0.
|
64
|
+
Requires-Dist: django-setup-configuration>=0.7.0; extra == "setup-configuration"
|
65
65
|
Provides-Extra: pep8
|
66
66
|
Requires-Dist: flake8; extra == "pep8"
|
67
67
|
Provides-Extra: coverage
|
@@ -1,6 +1,6 @@
|
|
1
1
|
[metadata]
|
2
2
|
name = commonground-api-common
|
3
|
-
version = 2.
|
3
|
+
version = 2.5.0
|
4
4
|
description = Commonground API tooling
|
5
5
|
long_description = file: README.rst
|
6
6
|
url = https://github.com/maykinmedia/commonground-api-common
|
@@ -88,7 +88,7 @@ tests =
|
|
88
88
|
testutils =
|
89
89
|
zgw-consumers-oas
|
90
90
|
setup-configuration =
|
91
|
-
django-setup-configuration>=0.
|
91
|
+
django-setup-configuration>=0.7.0
|
92
92
|
pep8 = flake8
|
93
93
|
coverage = pytest-cov
|
94
94
|
docs =
|
@@ -0,0 +1,106 @@
|
|
1
|
+
from django.core.exceptions import ValidationError
|
2
|
+
|
3
|
+
import pytest
|
4
|
+
|
5
|
+
from vng_api_common.validators import (
|
6
|
+
AlphanumericExcludingDiacritic,
|
7
|
+
BaseIdentifierValidator,
|
8
|
+
validate_bsn,
|
9
|
+
validate_rsin,
|
10
|
+
)
|
11
|
+
|
12
|
+
|
13
|
+
@pytest.mark.parametrize("value", ["foo$", "aëeeei", "no spaces allowed"])
|
14
|
+
def test_alphanumeric_validator_error_invalid_input(value):
|
15
|
+
validator = AlphanumericExcludingDiacritic()
|
16
|
+
|
17
|
+
with pytest.raises(ValidationError):
|
18
|
+
validator(value)
|
19
|
+
|
20
|
+
|
21
|
+
@pytest.mark.parametrize(
|
22
|
+
"value",
|
23
|
+
[
|
24
|
+
"simple",
|
25
|
+
"dashes-are-ok",
|
26
|
+
"underscores_are_too",
|
27
|
+
"let_us_not_forget_about_numb3rs",
|
28
|
+
],
|
29
|
+
)
|
30
|
+
def test_alphanumeric_validator_error_valid_input(value):
|
31
|
+
validator = AlphanumericExcludingDiacritic()
|
32
|
+
try:
|
33
|
+
validator(value)
|
34
|
+
except ValidationError:
|
35
|
+
pytest.fail("Should have passed validation")
|
36
|
+
|
37
|
+
|
38
|
+
def test_equality_validator_instances():
|
39
|
+
validator1 = AlphanumericExcludingDiacritic()
|
40
|
+
validator2 = AlphanumericExcludingDiacritic()
|
41
|
+
|
42
|
+
assert validator1 == validator2
|
43
|
+
|
44
|
+
|
45
|
+
def test_valid():
|
46
|
+
validator = BaseIdentifierValidator(
|
47
|
+
"296648875", identifier_length=9, validate_11proef=True
|
48
|
+
)
|
49
|
+
validator.validate()
|
50
|
+
|
51
|
+
|
52
|
+
def test_invalid_length():
|
53
|
+
validator = BaseIdentifierValidator(
|
54
|
+
"1234", identifier_length=9, validate_11proef=True
|
55
|
+
)
|
56
|
+
|
57
|
+
with pytest.raises(ValidationError) as error:
|
58
|
+
validator.validate()
|
59
|
+
assert "Waarde moet 9 tekens lang zijn" in str(error.value)
|
60
|
+
|
61
|
+
|
62
|
+
def test_invalid_isdigit():
|
63
|
+
validator = BaseIdentifierValidator(
|
64
|
+
"1234TEST", identifier_length=9, validate_11proef=True
|
65
|
+
)
|
66
|
+
|
67
|
+
with pytest.raises(ValidationError) as error:
|
68
|
+
validator.validate()
|
69
|
+
assert "Voer een numerieke waarde in" in str(error.value)
|
70
|
+
|
71
|
+
|
72
|
+
def test_invalid_11proefnumber():
|
73
|
+
validator = BaseIdentifierValidator(
|
74
|
+
"123456789", identifier_length=9, validate_11proef=True
|
75
|
+
)
|
76
|
+
with pytest.raises(ValidationError) as error:
|
77
|
+
validator.validate()
|
78
|
+
assert "Ongeldige code" in str(error.value)
|
79
|
+
|
80
|
+
|
81
|
+
def test_valid_bsn():
|
82
|
+
validate_bsn("296648875")
|
83
|
+
|
84
|
+
|
85
|
+
def test_invalid_bsn():
|
86
|
+
with pytest.raises(ValidationError) as error:
|
87
|
+
validate_bsn("123456789") # validate_11proef
|
88
|
+
assert "Onjuist BSN nummer" in str(error.value)
|
89
|
+
|
90
|
+
with pytest.raises(ValidationError) as error:
|
91
|
+
validate_bsn("12345678") # validate_length
|
92
|
+
assert "Waarde moet 9 tekens lang zijn" in str(error.value)
|
93
|
+
|
94
|
+
|
95
|
+
def test_valid_rsin():
|
96
|
+
validate_rsin("296648875")
|
97
|
+
|
98
|
+
|
99
|
+
def test_invalid_rsin():
|
100
|
+
with pytest.raises(ValidationError) as error:
|
101
|
+
validate_rsin("123456789") # validate_11proef
|
102
|
+
assert "Onjuist RSIN nummer" in str(error.value)
|
103
|
+
|
104
|
+
with pytest.raises(ValidationError) as error:
|
105
|
+
validate_rsin("12345678") # validate_length
|
106
|
+
assert "Waarde moet 9 tekens lang zijn" in str(error.value)
|
@@ -0,0 +1 @@
|
|
1
|
+
__version__ = "2.5.0"
|
@@ -1,6 +1,7 @@
|
|
1
1
|
import logging
|
2
2
|
|
3
3
|
from django.apps import AppConfig
|
4
|
+
from django.core.exceptions import ImproperlyConfigured
|
4
5
|
from django.db import models
|
5
6
|
from django.forms.fields import CharField
|
6
7
|
from django.utils.translation import gettext_lazy as _
|
@@ -89,7 +90,7 @@ def register_geojson_field_extension() -> None:
|
|
89
90
|
"""
|
90
91
|
try:
|
91
92
|
from rest_framework_gis.fields import GeometryField # noqa
|
92
|
-
except ImportError:
|
93
|
+
except (ImportError, ImproperlyConfigured):
|
93
94
|
logger.debug(
|
94
95
|
"Could not import djangorestframework-gis, skipping "
|
95
96
|
"GeometryFieldExtension registration."
|
@@ -13,10 +13,14 @@ class SingleJWTSecretConfigurationModel(ConfigurationModel):
|
|
13
13
|
"secret",
|
14
14
|
]
|
15
15
|
}
|
16
|
+
extra_kwargs = {
|
17
|
+
"identifier": {"examples": ["application-name"]},
|
18
|
+
"secret": {"examples": ["modify-this"]},
|
19
|
+
}
|
16
20
|
|
17
21
|
|
18
22
|
class JWTSecretsConfigurationModel(ConfigurationModel):
|
19
|
-
items: list[SingleJWTSecretConfigurationModel] = Field(
|
23
|
+
items: list[SingleJWTSecretConfigurationModel] = Field()
|
20
24
|
|
21
25
|
|
22
26
|
class SingleApplicatieConfigurationModel(ConfigurationModel):
|
@@ -26,7 +30,11 @@ class SingleApplicatieConfigurationModel(ConfigurationModel):
|
|
26
30
|
django_model_refs = {
|
27
31
|
Applicatie: ["uuid", "client_ids", "label", "heeft_alle_autorisaties"]
|
28
32
|
}
|
33
|
+
extra_kwargs = {
|
34
|
+
"client_ids": {"examples": [["open-notificaties-prod"]]},
|
35
|
+
"label": {"examples": ["Open Notificaties (productie)"]},
|
36
|
+
}
|
29
37
|
|
30
38
|
|
31
39
|
class ApplicatieConfigurationModel(ConfigurationModel):
|
32
|
-
items: list[SingleApplicatieConfigurationModel]
|
40
|
+
items: list[SingleApplicatieConfigurationModel]
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/serializers.py
RENAMED
@@ -91,7 +91,7 @@ class ValidatieFoutSerializer(FoutSerializer):
|
|
91
91
|
|
92
92
|
|
93
93
|
def add_choice_values_help_text(
|
94
|
-
choices: Union[models.Choices, List[Tuple[str, str]]]
|
94
|
+
choices: Union[models.Choices, List[Tuple[str, str]]],
|
95
95
|
) -> str:
|
96
96
|
is_dj_choices = inspect.isclass(choices) and issubclass(choices, models.Choices)
|
97
97
|
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/validators.py
RENAMED
@@ -5,7 +5,6 @@ from typing import Callable
|
|
5
5
|
|
6
6
|
from django.conf import settings
|
7
7
|
from django.core.exceptions import ValidationError
|
8
|
-
from django.core.validators import RegexValidator
|
9
8
|
from django.utils import timezone
|
10
9
|
from django.utils.deconstruct import deconstructible
|
11
10
|
from django.utils.module_loading import import_string
|
@@ -13,7 +12,7 @@ from django.utils.translation import gettext_lazy as _
|
|
13
12
|
|
14
13
|
from rest_framework import serializers, validators
|
15
14
|
|
16
|
-
from .constants import RSIN_LENGTH
|
15
|
+
from .constants import BSN_LENGTH, RSIN_LENGTH
|
17
16
|
from .oas import fetcher, obj_has_shape
|
18
17
|
|
19
18
|
logger = logging.getLogger(__name__)
|
@@ -22,6 +21,90 @@ logger = logging.getLogger(__name__)
|
|
22
21
|
WORD_REGEX = re.compile(r"[\w\-]+$", re.ASCII)
|
23
22
|
|
24
23
|
|
24
|
+
class BaseIdentifierValidator:
|
25
|
+
"""
|
26
|
+
Validator base class that performs common validation logic.
|
27
|
+
Digit check, length, and optional 11-proof check.
|
28
|
+
"""
|
29
|
+
|
30
|
+
error_messages = {
|
31
|
+
"isdigit": _("Voer een numerieke waarde in"),
|
32
|
+
"length": _("Waarde moet %(identifier_length)s tekens lang zijn"),
|
33
|
+
"11proefnumber": _("Ongeldige code"),
|
34
|
+
}
|
35
|
+
|
36
|
+
def __init__(
|
37
|
+
self,
|
38
|
+
value: str,
|
39
|
+
identifier_length: int,
|
40
|
+
validate_11proef: bool = False,
|
41
|
+
):
|
42
|
+
self.value = value
|
43
|
+
self.identifier_length = identifier_length
|
44
|
+
self.validate_11proef = validate_11proef
|
45
|
+
|
46
|
+
def validate_isdigit(self) -> None:
|
47
|
+
"""Validates that the value contains only digits."""
|
48
|
+
if not self.value.isdigit():
|
49
|
+
raise ValidationError(self.error_messages["isdigit"], code="only-digits")
|
50
|
+
|
51
|
+
def validate_length(self) -> None:
|
52
|
+
"""Validates that the length of the value is within the allowed sizes."""
|
53
|
+
if len(self.value) != self.identifier_length:
|
54
|
+
raise ValidationError(
|
55
|
+
self.error_messages["length"]
|
56
|
+
% {"identifier_length": self.identifier_length},
|
57
|
+
code="invalid-length",
|
58
|
+
)
|
59
|
+
|
60
|
+
def validate_11proefnumber(self) -> None:
|
61
|
+
"""Validates the value based on the 11-proof check."""
|
62
|
+
total = 0
|
63
|
+
for multiplier, char in enumerate(reversed(self.value), start=1):
|
64
|
+
if multiplier == 1:
|
65
|
+
total += -multiplier * int(char)
|
66
|
+
else:
|
67
|
+
total += multiplier * int(char)
|
68
|
+
|
69
|
+
if total % 11 != 0:
|
70
|
+
raise ValidationError(self.error_messages["11proefnumber"], code="invalid")
|
71
|
+
|
72
|
+
def validate(self) -> None:
|
73
|
+
self.validate_isdigit()
|
74
|
+
self.validate_length()
|
75
|
+
if self.validate_11proef:
|
76
|
+
self.validate_11proefnumber()
|
77
|
+
|
78
|
+
|
79
|
+
def validate_rsin(value: str) -> None:
|
80
|
+
"""
|
81
|
+
Validates that a string value is a valid RSIN number by applying the
|
82
|
+
'11-proef' checking.
|
83
|
+
|
84
|
+
:param value: String object representing a presumably good RSIN number.
|
85
|
+
"""
|
86
|
+
|
87
|
+
validator = BaseIdentifierValidator(
|
88
|
+
value, identifier_length=RSIN_LENGTH, validate_11proef=True
|
89
|
+
)
|
90
|
+
validator.error_messages["11proefnumber"] = _("Onjuist RSIN nummer")
|
91
|
+
validator.validate()
|
92
|
+
|
93
|
+
|
94
|
+
def validate_bsn(value: str) -> None:
|
95
|
+
"""
|
96
|
+
Validates that a string value is a valid BSN number by applying the
|
97
|
+
'11-proef' checking.
|
98
|
+
|
99
|
+
:param value: String object representing a presumably good BSN number.
|
100
|
+
"""
|
101
|
+
validator = BaseIdentifierValidator(
|
102
|
+
value, identifier_length=BSN_LENGTH, validate_11proef=True
|
103
|
+
)
|
104
|
+
validator.error_messages["11proefnumber"] = _("Onjuist BSN nummer")
|
105
|
+
validator.validate()
|
106
|
+
|
107
|
+
|
25
108
|
@deconstructible
|
26
109
|
class AlphanumericExcludingDiacritic:
|
27
110
|
"""
|
@@ -73,37 +156,6 @@ def validate_non_negative_string(value):
|
|
73
156
|
raise ValidationError("De waarde moet een niet-negatief getal zijn.")
|
74
157
|
|
75
158
|
|
76
|
-
validate_digits = RegexValidator(
|
77
|
-
regex="^[0-9]+$", message="Waarde moet numeriek zijn.", code="only-digits"
|
78
|
-
)
|
79
|
-
|
80
|
-
|
81
|
-
def validate_rsin(value):
|
82
|
-
"""
|
83
|
-
Validates that a string value is a valid RSIN number by applying the
|
84
|
-
'11-proef' checking.
|
85
|
-
|
86
|
-
:param value: String object representing a presumably good RSIN number.
|
87
|
-
"""
|
88
|
-
# Initial sanity checks.
|
89
|
-
validate_digits(value)
|
90
|
-
if len(value) != RSIN_LENGTH:
|
91
|
-
raise ValidationError(
|
92
|
-
"RSIN moet %s tekens lang zijn." % RSIN_LENGTH, code="invalid-length"
|
93
|
-
)
|
94
|
-
|
95
|
-
# 11-proef check.
|
96
|
-
total = 0
|
97
|
-
for multiplier, char in enumerate(reversed(value), start=1):
|
98
|
-
if multiplier == 1:
|
99
|
-
total += -multiplier * int(char)
|
100
|
-
else:
|
101
|
-
total += multiplier * int(char)
|
102
|
-
|
103
|
-
if total % 11 != 0:
|
104
|
-
raise ValidationError("Onjuist RSIN nummer.", code="invalid")
|
105
|
-
|
106
|
-
|
107
159
|
class URLValidator:
|
108
160
|
"""
|
109
161
|
Validate that the URL actually resolves to a HTTP 200
|
@@ -184,12 +184,12 @@ def _test_nrc_config(check_autorisaties_subscription=True) -> list:
|
|
184
184
|
nrc_client: Optional[Client] = NotificationsConfig.get_client()
|
185
185
|
|
186
186
|
if not nrc_client:
|
187
|
-
return [(
|
187
|
+
return [(_("NRC"), _("Missing"), False)]
|
188
188
|
|
189
189
|
has_nrc_auth = nrc_client.auth is not None if nrc_client else False
|
190
190
|
|
191
191
|
if not nrc_config.notifications_api_service:
|
192
|
-
checks = [(
|
192
|
+
checks = [(_("NRC"), _("Missing"), False)]
|
193
193
|
return checks
|
194
194
|
|
195
195
|
checks = [
|
@@ -1,37 +0,0 @@
|
|
1
|
-
from django.core.exceptions import ValidationError
|
2
|
-
|
3
|
-
import pytest
|
4
|
-
|
5
|
-
from vng_api_common.validators import AlphanumericExcludingDiacritic
|
6
|
-
|
7
|
-
|
8
|
-
@pytest.mark.parametrize("value", ["foo$", "aëeeei", "no spaces allowed"])
|
9
|
-
def test_alphanumeric_validator_error_invalid_input(value):
|
10
|
-
validator = AlphanumericExcludingDiacritic()
|
11
|
-
|
12
|
-
with pytest.raises(ValidationError):
|
13
|
-
validator(value)
|
14
|
-
|
15
|
-
|
16
|
-
@pytest.mark.parametrize(
|
17
|
-
"value",
|
18
|
-
[
|
19
|
-
"simple",
|
20
|
-
"dashes-are-ok",
|
21
|
-
"underscores_are_too",
|
22
|
-
"let_us_not_forget_about_numb3rs",
|
23
|
-
],
|
24
|
-
)
|
25
|
-
def test_alphanumeric_validator_error_valid_input(value):
|
26
|
-
validator = AlphanumericExcludingDiacritic()
|
27
|
-
try:
|
28
|
-
validator(value)
|
29
|
-
except ValidationError:
|
30
|
-
pytest.fail("Should have passed validation")
|
31
|
-
|
32
|
-
|
33
|
-
def test_equality_validator_instances():
|
34
|
-
validator1 = AlphanumericExcludingDiacritic()
|
35
|
-
validator2 = AlphanumericExcludingDiacritic()
|
36
|
-
|
37
|
-
assert validator1 == validator2
|
@@ -1 +0,0 @@
|
|
1
|
-
__version__ = "2.3.0"
|
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
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_autorisatie_validation.py
RENAMED
File without changes
|
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_check_query_params.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_content_type_headers.py
RENAMED
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_field_extensions.py
RENAMED
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_filter_extension.py
RENAMED
File without changes
|
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_gegevensgroepen.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_publish_validators.py
RENAMED
File without changes
|
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/tests/test_serializer_extensions.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/api/__init__.py
RENAMED
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/api/permissions.py
RENAMED
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/api/serializers.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/admin.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/apps.py
RENAMED
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/audits.py
RENAMED
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
|
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
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/models.py
RENAMED
File without changes
|
{commonground_api_common-2.3.0 → commonground_api_common-2.5.0}/vng_api_common/audittrails/utils.py
RENAMED
File without changes
|
File without changes
|