Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release/2.4.4 #462

Merged
merged 8 commits into from
Oct 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[bumpversion]
commit = False
tag = False
current_version = 2.4.3
current_version = 2.4.4

[bumpversion:file:README.rst]

Expand Down
23 changes: 23 additions & 0 deletions .github/workflows/oaf-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Check Open API Framework Version

on:
workflow_dispatch:
schedule:
- cron: '36 0 * * 0'

jobs:
run:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install dependencies
run: pip install -U pip-tools
- name: Run compile dependencies
run: ./bin/compile_dependencies.sh --upgrade-package open-api-framework

- name: Check git diff
run: git diff --exit-code -- requirements/*.txt
28 changes: 26 additions & 2 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,35 @@
Change history
==============

3.0.0 (WIP)
-----------

**Breaking changes**

* dropped support for v1 endpoints (#453)


2.4.4 (2024-10-01)
------------------

**Bugfixes and QOL**

* fixed CSP errors on the OAS page (#458)
* fixed OIDC login by making SameSite setting lax (#458)
* fixed adding permissions in the Admin (#449)
* fixed ``NOTIFICATIONS_DISABLED`` setting (#452)

**Project maintenance**

* added CI action to check if OAF is up-to-date (#443)


2.4.3 (2024-09-18)
------------------

**New features**

* added an endpoint to retrieve a specific object version (#328)
* supported the `in` operator in `data_attrs` to match one element (#414)

**Bugfixes and QOL**
Expand All @@ -15,9 +39,9 @@ Change history
* fixed 2FA app title (#442)
* bumped setuptools and npm dependencies (#441)

**Project maintaince**
**Project maintenance**

* disabled cofiguration steps by default (#446)
* disabled configuration steps by default (#446)
* increase default values for uwsgi processes and threads (#448)

.. warning::
Expand Down
10 changes: 5 additions & 5 deletions README.NL.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
Objecten API
============

:Version: 2.4.3
:Version: 2.4.4
:Source: https://github.com/maykinmedia/objecttypes-api
:Keywords: objecten, assets, zaakobjecten

Expand Down Expand Up @@ -38,10 +38,10 @@ Versie Release datum API specificatie
============== ============== =============================
latest n/a `ReDoc <https://redocly.github.io/redoc/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/master/src/objects/api/v2/openapi.yaml>`_,
`Swagger <https://petstore.swagger.io/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/master/src/objects/api/v2/openapi.yaml>`_,
(`verschillen <https://github.com/maykinmedia/objects-api/compare/2.4.3..master#diff-b9c28fec6c3f3fa5cff870d24601d6ab7027520f3b084cc767aefd258cb8c40a>`_)
2.4.3 2024-03-22 `ReDoc <https://redocly.github.io/redoc/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.4.3/src/objects/api/v2/openapi.yaml>`_,
`Swagger <https://petstore.swagger.io/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.4.3/src/objects/api/v2/openapi.yaml>`_
(`verschillen <https://github.com/maykinmedia/objects-api/compare/2.3.0..2.4.3#diff-b9c28fec6c3f3fa5cff870d24601d6ab7027520f3b084cc767aefd258cb8c40a>`_)
(`verschillen <https://github.com/maykinmedia/objects-api/compare/2.4.4..master#diff-b9c28fec6c3f3fa5cff870d24601d6ab7027520f3b084cc767aefd258cb8c40a>`_)
2.4.4 2024-03-22 `ReDoc <https://redocly.github.io/redoc/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.4.4/src/objects/api/v2/openapi.yaml>`_,
`Swagger <https://petstore.swagger.io/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.4.4/src/objects/api/v2/openapi.yaml>`_
(`verschillen <https://github.com/maykinmedia/objects-api/compare/2.3.0..2.4.4#diff-b9c28fec6c3f3fa5cff870d24601d6ab7027520f3b084cc767aefd258cb8c40a>`_)
2.3.0 2024-03-15 `ReDoc <https://redocly.github.io/redoc/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.3.0/src/objects/api/v2/openapi.yaml>`_,
`Swagger <https://petstore.swagger.io/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.3.0/src/objects/api/v2/openapi.yaml>`_
(`verschillen <https://github.com/maykinmedia/objects-api/compare/2.2.1..2.3.0#diff-b9c28fec6c3f3fa5cff870d24601d6ab7027520f3b084cc767aefd258cb8c40a>`_)
Expand Down
10 changes: 5 additions & 5 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
Objects API
===========

:Version: 2.4.3
:Version: 2.4.4
:Source: https://github.com/maykinmedia/objects-api
:Keywords: objects, assets, zaakobjecten

Expand Down Expand Up @@ -36,10 +36,10 @@ Version Release date API specification
============== ============== =============================
latest n/a `ReDoc <https://redocly.github.io/redoc/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/master/src/objects/api/v2/openapi.yaml>`_,
`Swagger <https://petstore.swagger.io/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/master/src/objects/api/v2/openapi.yaml>`_,
(`diff <https://github.com/maykinmedia/objects-api/compare/2.4.3..master#diff-b9c28fec6c3f3fa5cff870d24601d6ab7027520f3b084cc767aefd258cb8c40a>`_)
2.4.3 2024-03-22 `ReDoc <https://redocly.github.io/redoc/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.4.3/src/objects/api/v2/openapi.yaml>`_,
`Swagger <https://petstore.swagger.io/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.4.3/src/objects/api/v2/openapi.yaml>`_
(`diff <https://github.com/maykinmedia/objects-api/compare/2.3.0..2.4.3#diff-b9c28fec6c3f3fa5cff870d24601d6ab7027520f3b084cc767aefd258cb8c40a>`_)
(`diff <https://github.com/maykinmedia/objects-api/compare/2.4.4..master#diff-b9c28fec6c3f3fa5cff870d24601d6ab7027520f3b084cc767aefd258cb8c40a>`_)
2.4.4 2024-03-22 `ReDoc <https://redocly.github.io/redoc/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.4.4/src/objects/api/v2/openapi.yaml>`_,
`Swagger <https://petstore.swagger.io/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.4.4/src/objects/api/v2/openapi.yaml>`_
(`diff <https://github.com/maykinmedia/objects-api/compare/2.3.0..2.4.4#diff-b9c28fec6c3f3fa5cff870d24601d6ab7027520f3b084cc767aefd258cb8c40a>`_)
2.3.0 2024-03-15 `ReDoc <https://redocly.github.io/redoc/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.3.0/src/objects/api/v2/openapi.yaml>`_,
`Swagger <https://petstore.swagger.io/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.3.0/src/objects/api/v2/openapi.yaml>`_
(`diff <https://github.com/maykinmedia/objects-api/compare/2.2.1..2.3.0#diff-b9c28fec6c3f3fa5cff870d24601d6ab7027520f3b084cc767aefd258cb8c40a>`_)
Expand Down
6 changes: 3 additions & 3 deletions docs/api/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ API Specification version(s)
`Redoc <https://redocly.github.io/redoc/?url=https://raw.githubusercontent.com/maykinmedia/objecttypes-api/2.0.0/src/objecttypes/api/v2/openapi.yaml>`__,
`Swagger <https://petstore.swagger.io/?url=https://raw.githubusercontent.com/maykinmedia/objecttypes-api/2.0.0/src/objecttypes/api/v2/openapi.yaml>`__
)
`Objects API`_ 2.4.3 (
`Redoc <https://redocly.github.io/redoc/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.4.3/src/objects/api/v2/openapi.yaml>`__,
`Swagger <https://petstore.swagger.io/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.4.3/src/objects/api/v2/openapi.yaml>`__
`Objects API`_ 2.4.4 (
`Redoc <https://redocly.github.io/redoc/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.4.4/src/objects/api/v2/openapi.yaml>`__,
`Swagger <https://petstore.swagger.io/?url=https://raw.githubusercontent.com/maykinmedia/objects-api/2.4.4/src/objects/api/v2/openapi.yaml>`__
)
====================== ==========================================

Expand Down
4 changes: 2 additions & 2 deletions docs/installation/config.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Available environment variables
Required
--------

* ``SECRET_KEY``: Secret key that's used for certain cryptographic utilities. You should generate one via `miniwebtool <https://www.miniwebtool.com/django-secret-key-generator>`_.
* ``SECRET_KEY``: Secret key that's used for certain cryptographic utilities. .
* ``ALLOWED_HOSTS``: a comma separated (without spaces!) list of domains that serve the installation. Used to protect against Host header attacks. Defaults to: ``(empty string)``.
* ``CACHE_DEFAULT``: redis cache address for the default cache (this **MUST** be set when using Docker). Defaults to: ``localhost:6379/0``.
* ``CACHE_AXES``: redis cache address for the brute force login protection cache (this **MUST** be set when using Docker). Defaults to: ``localhost:6379/0``.
Expand Down Expand Up @@ -86,7 +86,7 @@ Optional
* ``LOG_LEVEL``: control the verbosity of logging output. Available values are ``CRITICAL``, ``ERROR``, ``WARNING``, ``INFO`` and ``DEBUG``. Defaults to: ``WARNING``.
* ``LOG_QUERIES``: enable (query) logging at the database backend level. Note that you must also set ``DEBUG=1``, which should be done very sparingly!. Defaults to: ``False``.
* ``LOG_REQUESTS``: enable logging of the outgoing requests. Defaults to: ``False``.
* ``SESSION_COOKIE_SAMESITE``: The value of the SameSite flag on the session cookie. This flag prevents the cookie from being sent in cross-site requests thus preventing CSRF attacks and making some methods of stealing session cookie impossible. Defaults to: ``Strict``.
* ``SESSION_COOKIE_SAMESITE``: The value of the SameSite flag on the session cookie. This flag prevents the cookie from being sent in cross-site requests thus preventing CSRF attacks and making some methods of stealing session cookie impossible.Currently interferes with OIDC. Keep the value set at Lax if used. Defaults to: ``Lax``.
* ``CSRF_COOKIE_SAMESITE``: The value of the SameSite flag on the CSRF cookie. This flag prevents the cookie from being sent in cross-site requests. Defaults to: ``Strict``.
* ``ENVIRONMENT``: An identifier for the environment, displayed in the admin depending on the settings module used and included in the error monitoring (see ``SENTRY_DSN``). The default is set according to ``DJANGO_SETTINGS_MODULE``.
* ``SUBPATH``: If hosted on a subpath, provide the value here. If you provide ``/gateway``, the component assumes its running at the base URL: ``https://somedomain/gateway/``. Defaults to an empty string. Defaults to: ``None``.
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "objects",
"version": "2.4.3",
"version": "2.4.4",
"description": "objects project",
"main": "src/objects/static/bundles/objects-js.js",
"directories": {
Expand Down
2 changes: 1 addition & 1 deletion publiccode.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ publiccodeYmlVersion: '0.2'
name: Objects API
url: 'http://github.com/maykinmedia/objects-api.git'
softwareType: standalone/backend
softwareVersion: 2.4.3
softwareVersion: 2.4.4
releaseDate: '2021-01-13'
logo: 'https://github.com/maykinmedia/objects-api/blob/master/docs/logo.png'
platforms:
Expand Down
11 changes: 8 additions & 3 deletions requirements/base.txt
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ django==4.2.15
# djangorestframework-inclusions
# drf-nested-routers
# drf-spectacular
# drf-spectacular-sidecar
# drf-yasg
# maykin-2fa
# mozilla-django-oidc
Expand Down Expand Up @@ -177,8 +178,12 @@ djangorestframework-inclusions==1.2.0
# via open-api-framework
drf-nested-routers==0.93.3
# via commonground-api-common
drf-spectacular==0.27.2
# via open-api-framework
drf-spectacular[sidecar]==0.27.2
# via
# drf-spectacular
# open-api-framework
drf-spectacular-sidecar==2024.7.1
# via drf-spectacular
drf-yasg==1.21.7
# via commonground-api-common
ecs-logging==2.1.0
Expand Down Expand Up @@ -238,7 +243,7 @@ notifications-api-common==0.2.2
# via
# -r requirements/base.in
# commonground-api-common
open-api-framework==0.8.0
open-api-framework==0.8.1
# via -r requirements/base.in
orderedmultidict==1.0.1
# via furl
Expand Down
10 changes: 8 additions & 2 deletions requirements/ci.txt
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ django==4.2.15
# djangorestframework-inclusions
# drf-nested-routers
# drf-spectacular
# drf-spectacular-sidecar
# drf-yasg
# maykin-2fa
# mozilla-django-oidc
Expand Down Expand Up @@ -271,10 +272,15 @@ drf-nested-routers==0.93.3
# via
# -r requirements/base.txt
# commonground-api-common
drf-spectacular==0.27.2
drf-spectacular[sidecar]==0.27.2
# via
# -r requirements/base.txt
# drf-spectacular
# open-api-framework
drf-spectacular-sidecar==2024.7.1
# via
# -r requirements/base.txt
# drf-spectacular
drf-yasg==1.21.7
# via
# -r requirements/base.txt
Expand Down Expand Up @@ -381,7 +387,7 @@ notifications-api-common==0.2.2
# via
# -r requirements/base.txt
# commonground-api-common
open-api-framework==0.8.0
open-api-framework==0.8.1
# via -r requirements/base.txt
orderedmultidict==1.0.1
# via
Expand Down
10 changes: 8 additions & 2 deletions requirements/dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,7 @@ django==4.2.15
# djangorestframework-inclusions
# drf-nested-routers
# drf-spectacular
# drf-spectacular-sidecar
# drf-yasg
# maykin-2fa
# mozilla-django-oidc
Expand Down Expand Up @@ -303,10 +304,15 @@ drf-nested-routers==0.93.3
# via
# -r requirements/ci.txt
# commonground-api-common
drf-spectacular==0.27.2
drf-spectacular[sidecar]==0.27.2
# via
# -r requirements/ci.txt
# drf-spectacular
# open-api-framework
drf-spectacular-sidecar==2024.7.1
# via
# -r requirements/ci.txt
# drf-spectacular
drf-yasg==1.21.7
# via
# -r requirements/ci.txt
Expand Down Expand Up @@ -430,7 +436,7 @@ notifications-api-common==0.2.2
# via
# -r requirements/ci.txt
# commonground-api-common
open-api-framework==0.8.0
open-api-framework==0.8.1
# via -r requirements/ci.txt
orderedmultidict==1.0.1
# via
Expand Down
2 changes: 1 addition & 1 deletion src/objects/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from .celery import app as celery_app

__all__ = ("celery_app",)
__version__ = "2.4.3"
__version__ = "2.4.4"
__author__ = "Maykin Media"
__homepage__ = "https://github.com/maykinmedia/objects-api"
2 changes: 1 addition & 1 deletion src/objects/api/v2/openapi.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
openapi: 3.0.3
info:
title: Objects API
version: 2.4.3 (v2)
version: 2.4.4 (v2)
description: |
An API to manage Objects.

Expand Down
7 changes: 3 additions & 4 deletions src/objects/conf/api.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
from vng_api_common.conf.api import * # noqa - imports white-listed

API_VERSION = "2.4.3"
VERSIONS = {"v1": "1.3.0", "v2": "2.4.3"}
API_VERSION = "2.4.4"
VERSIONS = {"v1": "1.3.0", "v2": "2.4.4"}

# api settings
REST_FRAMEWORK = {
Expand Down Expand Up @@ -89,6 +87,7 @@
"""

SPECTACULAR_SETTINGS = {
"REDOC_DIST": "SIDECAR",
"SCHEMA_PATH_PREFIX": r"/api/v[1-9]+",
"SCHEMA_PATH_PREFIX_TRIM": True,
"TITLE": "Objects API",
Expand Down
4 changes: 4 additions & 0 deletions src/objects/token/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@ def get_data_field_choices(self):
except requests.JSONDecodeError:
continue

# TODO: remove check once API V1 is removed
if "results" in response_data:
response_data = response_data["results"]

# use only first level of properties
data_fields[object_type.id] = {
version["version"]: {
Expand Down
Loading
Loading