From 85322d661b7af9369a8657e5a1aeed3eba923eb5 Mon Sep 17 00:00:00 2001 From: pulpbot Date: Sun, 23 Jun 2024 02:41:02 +0000 Subject: [PATCH] Update CI files [noissue] --- .ci/ansible/settings.py.j2 | 2 +- .ci/scripts/collect_changes.py | 8 +- .github/template_gitref | 2 +- .github/workflows/build.yml | 22 +- .github/workflows/changelog.yml | 2 +- .github/workflows/ci.yml | 7 +- .github/workflows/create-branch.yml | 2 +- .github/workflows/lint.yml | 2 +- .github/workflows/nightly.yml | 14 +- .github/workflows/publish.yml | 43 +- .github/workflows/release.yml | 2 +- .github/workflows/scripts/before_script.sh | 6 - .github/workflows/scripts/install.sh | 26 +- .../workflows/scripts/publish_client_pypi.sh | 10 +- .github/workflows/scripts/script.sh | 86 +- .github/workflows/test.yml | 23 +- .github/workflows/update-labels.yml | 2 +- .github/workflows/update_ci.yml | 2 +- CHANGES.md | 509 ++++++++++++ CHANGES.rst | 735 ------------------ CHANGES/.TEMPLATE.md | 39 + MANIFEST.in | 2 +- docs/changes.rst | 7 +- pyproject.toml | 10 +- 24 files changed, 680 insertions(+), 883 deletions(-) create mode 100644 CHANGES.md delete mode 100644 CHANGES.rst create mode 100644 CHANGES/.TEMPLATE.md diff --git a/.ci/ansible/settings.py.j2 b/.ci/ansible/settings.py.j2 index 024df4e4..4ed28f42 100644 --- a/.ci/ansible/settings.py.j2 +++ b/.ci/ansible/settings.py.j2 @@ -49,7 +49,7 @@ AZURE_CONTAINER = "pulp-test" AZURE_LOCATION = "pulp3" AZURE_OVERWRITE_FILES = True AZURE_URL_EXPIRATION_SECS = 120 -AZURE_CONNECTION_STRING = 'DefaultEndpointsProtocol={{ pulp_scheme }};AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint={{ pulp_scheme }}://ci-azurite:10000/devstoreaccount1;' +AZURE_CONNECTION_STRING = 'DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://ci-azurite:10000/devstoreaccount1;' {% endif %} {% if gcp_test | default(false) %} diff --git a/.ci/scripts/collect_changes.py b/.ci/scripts/collect_changes.py index 6ca48afa..d39642c7 100755 --- a/.ci/scripts/collect_changes.py +++ b/.ci/scripts/collect_changes.py @@ -1,3 +1,4 @@ +#!/bin/env python3 # WARNING: DO NOT EDIT! # # This file was generated by plugin_template, and is managed by it. Please use @@ -8,13 +9,14 @@ import itertools import os import re +import tomllib -import toml from git import GitCommandError, Repo from packaging.version import parse as parse_version # Read Towncrier settings -tc_settings = toml.load("pyproject.toml")["tool"]["towncrier"] +with open("pyproject.toml", "rb") as fp: + tc_settings = tomllib.load(fp)["tool"]["towncrier"] CHANGELOG_FILE = tc_settings.get("filename", "NEWS.rst") START_STRING = tc_settings.get( @@ -79,7 +81,7 @@ def main(): old_length = len(main_changes) for branch in branches: - print(f"Looking at branch {branch}") + print(f"Looking for './{CHANGELOG_FILE}' at branch {branch}") try: changelog = get_changelog(repo, branch) except GitCommandError: diff --git a/.github/template_gitref b/.github/template_gitref index 418b21cd..d98f4b24 100644 --- a/.github/template_gitref +++ b/.github/template_gitref @@ -1 +1 @@ -2021.08.26-327-g6a0d984 +2021.08.26-342-g13e7dc5 diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 1e9bdf64..479f7c07 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -23,7 +23,7 @@ jobs: with: fetch-depth: 1 path: "pulp_file" - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" - name: "Install python dependencies" @@ -35,10 +35,28 @@ jobs: run: | python3 setup.py sdist bdist_wheel --python-tag py3 twine check dist/* + - name: "Install built packages" + run: | + pip install dist/pulp_file-*-py3-none-any.whl + - name: "Generate api specs" + run: | + pulpcore-manager openapi --file "api.json" + pulpcore-manager openapi --bindings --component "file" --file "file-api.json" - name: "Upload Package whl" - uses: "actions/upload-artifact@v3" + uses: "actions/upload-artifact@v4" with: name: "plugin_package" path: "pulp_file/dist/" if-no-files-found: "error" retention-days: 5 + overwrite: true + - name: "Upload API specs" + uses: "actions/upload-artifact@v4" + with: + name: "api_spec" + path: | + pulp_file/api.json + pulp_file/file-api.json + if-no-files-found: "error" + retention-days: 5 + overwrite: true diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index 88d86057..4aa03a42 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -28,7 +28,7 @@ jobs: with: fetch-depth: 1 - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 486f7416..f7161359 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -25,7 +25,7 @@ jobs: with: fetch-depth: 0 path: "pulp_file" - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" - name: "Install python dependencies" @@ -67,10 +67,11 @@ jobs: mkdir -p "pulp_file" working-directory: "." - name: "Download Deprecations" - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: - name: "deprecations" + pattern: "deprecations-*" path: "pulp_file" + merge-multiple: true - name: "Print deprecations" run: | cat deprecations-*.txt | sort -u diff --git a/.github/workflows/create-branch.yml b/.github/workflows/create-branch.yml index dc78245a..39e163e5 100644 --- a/.github/workflows/create-branch.yml +++ b/.github/workflows/create-branch.yml @@ -26,7 +26,7 @@ jobs: fetch-depth: 0 path: "pulp_file" - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index d780348f..ebc72097 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -24,7 +24,7 @@ jobs: fetch-depth: 1 path: "pulp_file" - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index 7cdbcd69..b911b0f1 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -38,7 +38,7 @@ jobs: fetch-depth: 0 path: "pulp_file" - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" @@ -76,12 +76,12 @@ jobs: fetch-depth: 1 path: "pulp_file" - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: name: "plugin_package" path: "pulp_file/dist/" - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" @@ -96,13 +96,13 @@ jobs: echo "TEST=${{ matrix.env.TEST }}" >> $GITHUB_ENV - name: Download built docs - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: "docs.tar" path: "pulp_file" - name: Download Python client docs - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: "python-client-docs.tar" path: "pulp_file" @@ -140,12 +140,12 @@ jobs: repository: "pulp/pulp-openapi-generator" path: "pulp-openapi-generator" - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: name: "plugin_package" path: "pulp_file/dist/" - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index d987817f..57c3bc8f 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -39,11 +39,11 @@ jobs: repository: "pulp/pulp-openapi-generator" path: "pulp-openapi-generator" - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" - - uses: "actions/download-artifact@v3" + - uses: "actions/download-artifact@v4" with: name: "plugin_package" path: "pulp_file/dist/" @@ -88,25 +88,32 @@ jobs: run: | .github/workflows/scripts/install_ruby_client.sh shell: "bash" + - name: "Upload python client packages" - uses: "actions/upload-artifact@v3" + uses: "actions/upload-artifact@v4" with: name: "python-client.tar" - path: "pulp_file/file-python-client.tar" + path: | + pulp_file/file-python-client.tar if-no-files-found: "error" + overwrite: true - name: "Upload python client docs" - uses: "actions/upload-artifact@v3" + uses: "actions/upload-artifact@v4" with: name: "python-client-docs.tar" - path: "pulp_file/file-python-client-docs.tar" + path: | + pulp_file/file-python-client-docs.tar if-no-files-found: "error" + overwrite: true - name: "Upload ruby client packages" - uses: "actions/upload-artifact@v3" + uses: "actions/upload-artifact@v4" with: name: "ruby-client.tar" - path: "pulp_file/file-ruby-client.tar" + path: | + pulp_file/file-ruby-client.tar if-no-files-found: "error" + overwrite: true - name: Build docs run: | export DJANGO_SETTINGS_MODULE=pulpcore.app.settings @@ -115,10 +122,12 @@ jobs: tar -cvf docs/docs.tar docs/_build - name: "Upload built docs" - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: "docs.tar" path: "pulp_file/docs/docs.tar" + if-no-files-found: "error" + overwrite: true - name: "Logs" if: always() @@ -145,12 +154,12 @@ jobs: fetch-depth: 1 path: "pulp_file" - - uses: "actions/download-artifact@v3" + - uses: "actions/download-artifact@v4" with: name: "plugin_package" path: "pulp_file/dist/" - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" @@ -184,7 +193,7 @@ jobs: path: "pulp_file" - name: "Download Python client" - uses: "actions/download-artifact@v3" + uses: "actions/download-artifact@v4" with: name: "python-client.tar" path: "pulp_file/" @@ -193,7 +202,7 @@ jobs: run: | tar -xvf file-python-client.tar - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" @@ -227,7 +236,7 @@ jobs: path: "pulp_file" - name: "Download Ruby client" - uses: "actions/download-artifact@v3" + uses: "actions/download-artifact@v4" with: name: "ruby-client.tar" path: "pulp_file/" @@ -263,7 +272,7 @@ jobs: fetch-depth: 1 path: "pulp_file" - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" @@ -280,13 +289,13 @@ jobs: SECRETS_CONTEXT: "${{ toJson(secrets) }}" - name: "Download built docs" - uses: "actions/download-artifact@v3" + uses: "actions/download-artifact@v4" with: name: "docs.tar" path: "pulp_file/" - name: "Download Python client docs" - uses: "actions/download-artifact@v3" + uses: "actions/download-artifact@v4" with: name: "python-client-docs.tar" path: "pulp_file/" diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index b2787fd7..37ab6171 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -28,7 +28,7 @@ jobs: path: "pulp_file" token: ${{ secrets.RELEASE_TOKEN }} - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" diff --git a/.github/workflows/scripts/before_script.sh b/.github/workflows/scripts/before_script.sh index 3e83bffd..f5ab492c 100755 --- a/.github/workflows/scripts/before_script.sh +++ b/.github/workflows/scripts/before_script.sh @@ -36,12 +36,6 @@ tail -v -n +1 .ci/ansible/Containerfile cmd_prefix bash -c "echo '%wheel ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/nopasswd" cmd_prefix bash -c "usermod -a -G wheel pulp" -SCENARIOS=("pulp" "performance" "azure" "gcp" "s3" "generate-bindings" "lowerbounds") -if [[ " ${SCENARIOS[*]} " =~ " ${TEST} " ]]; then - # Many functional tests require these - cmd_prefix dnf install -yq lsof which -fi - if [[ "${REDIS_DISABLED:-false}" == true ]]; then cmd_prefix bash -c "s6-rc -d change redis" echo "The Redis service was disabled for $TEST" diff --git a/.github/workflows/scripts/install.sh b/.github/workflows/scripts/install.sh index 30bd05fa..214778a3 100755 --- a/.github/workflows/scripts/install.sh +++ b/.github/workflows/scripts/install.sh @@ -114,18 +114,12 @@ pulp_scenario_env: {}\ fi if [ "$TEST" = "azure" ]; then - mkdir -p azurite - cd azurite - openssl req -newkey rsa:2048 -x509 -nodes -keyout azkey.pem -new -out azcert.pem -sha256 -days 365 -addext "subjectAltName=DNS:ci-azurite" -subj "/C=CO/ST=ST/L=LO/O=OR/OU=OU/CN=CN" - sudo cp azcert.pem /usr/local/share/ca-certificates/azcert.crt - sudo dpkg-reconfigure ca-certificates - cd .. sed -i -e '/^services:/a \ - name: ci-azurite\ image: mcr.microsoft.com/azure-storage/azurite\ volumes:\ - ./azurite:/etc/pulp\ - command: "azurite-blob --blobHost 0.0.0.0 --cert /etc/pulp/azcert.pem --key /etc/pulp/azkey.pem"' vars/main.yaml + command: "azurite-blob --blobHost 0.0.0.0"' vars/main.yaml sed -i -e '$a azure_test: true\ pulp_scenario_settings: null\ pulp_scenario_env: {}\ @@ -161,31 +155,17 @@ sudo docker cp pulp:/etc/pulp/certs/pulp_webserver.crt /usr/local/share/ca-certi # Hack: adding pulp CA to certifi.where() CERTIFI=$(python -c 'import certifi; print(certifi.where())') cat /usr/local/share/ca-certificates/pulp_webserver.crt | sudo tee -a "$CERTIFI" > /dev/null -if [[ "$TEST" = "azure" ]]; then - cat /usr/local/share/ca-certificates/azcert.crt | sudo tee -a "$CERTIFI" > /dev/null -fi # Hack: adding pulp CA to default CA file CERT=$(python -c 'import ssl; print(ssl.get_default_verify_paths().openssl_cafile)') -cat "$CERTIFI" | sudo tee -a "$CERT" > /dev/null +cat /usr/local/share/ca-certificates/pulp_webserver.crt | sudo tee -a "$CERT" > /dev/null # Updating certs sudo update-ca-certificates echo ::endgroup:: -# Add our azcert.crt certificate to the container image along with the certificates from certifi -# so that we can use HTTPS with our fake Azure CI. certifi is self-contained and doesn't allow -# extension or modification of the trust store, so we do a weird and hacky thing (above) where we just -# overwrite or append to certifi's trust store behind it's back. -# -# We do this for both the CI host and the CI image. if [[ "$TEST" = "azure" ]]; then - AZCERTIFI=$(/opt/az/bin/python3 -c 'import certifi; print(certifi.where())') - PULPCERTIFI=$(cmd_prefix python3 -c 'import certifi; print(certifi.where())') - cat /usr/local/share/ca-certificates/azcert.crt >> $AZCERTIFI - cat /usr/local/share/ca-certificates/azcert.crt | cmd_stdin_prefix tee -a "$PULPCERTIFI" > /dev/null - cat /usr/local/share/ca-certificates/azcert.crt | cmd_stdin_prefix tee -a /etc/pki/tls/cert.pem > /dev/null - AZURE_STORAGE_CONNECTION_STRING='DefaultEndpointsProtocol=https;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=https://ci-azurite:10000/devstoreaccount1;' + AZURE_STORAGE_CONNECTION_STRING='DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://ci-azurite:10000/devstoreaccount1;' az storage container create --name pulp-test --connection-string $AZURE_STORAGE_CONNECTION_STRING fi diff --git a/.github/workflows/scripts/publish_client_pypi.sh b/.github/workflows/scripts/publish_client_pypi.sh index 3bff7934..4fc80acf 100755 --- a/.github/workflows/scripts/publish_client_pypi.sh +++ b/.github/workflows/scripts/publish_client_pypi.sh @@ -24,10 +24,8 @@ RESPONSE="$(curl --write-out '%{http_code}' --silent --output /dev/null "https:/ if [ "$RESPONSE" == "200" ]; then echo "pulp_file client $VERSION has already been released. Skipping." - exit +else + twine upload -u __token__ -p "$PYPI_API_TOKEN" \ + "dist/pulp_file_client-$VERSION-py3-none-any.whl" \ + "dist/pulp_file-client-$VERSION.tar.gz" fi - -twine upload -u __token__ -p "$PYPI_API_TOKEN" \ -"dist/pulp_file_client-$VERSION-py3-none-any.whl" \ -"dist/pulp_file-client-$VERSION.tar.gz" \ -; diff --git a/.github/workflows/scripts/script.sh b/.github/workflows/scripts/script.sh index 9d959418..b984de29 100755 --- a/.github/workflows/scripts/script.sh +++ b/.github/workflows/scripts/script.sh @@ -54,64 +54,38 @@ cmd_prefix bash -c "chmod 600 ~pulp/.netrc" # Generate and install binding pushd ../pulp-openapi-generator -if pulp debug has-plugin --name "core" --specifier ">=3.44.0.dev" -then - # Use app_label to generate api.json and package to produce the proper package name. +# Use app_label to generate api.json and package to produce the proper package name. - if [ "$(jq -r '.domain_enabled' <<<"$REPORTED_STATUS")" = "true" ] - then - # Workaround: Domains are not supported by the published bindings. - # Generate new bindings for all packages. - for item in $(jq -r '.versions[] | tojson' <<<"$REPORTED_STATUS") - do - echo $item - COMPONENT="$(jq -r '.component' <<<"$item")" - VERSION="$(jq -r '.version' <<<"$item")" - MODULE="$(jq -r '.module' <<<"$item")" - PACKAGE="${MODULE%%.*}" - curl --fail-with-body -k -o api.json "${PULP_URL}${PULP_API_ROOT}api/v3/docs/api.json?bindings&component=$COMPONENT" - USE_LOCAL_API_JSON=1 ./generate.sh "${PACKAGE}" python "${VERSION}" - cmd_prefix pip3 install "/root/pulp-openapi-generator/${PACKAGE}-client" - sudo rm -rf "./${PACKAGE}-client" - done - else - # Sadly: Different pulpcore-versions aren't either... - for item in $(jq -r '.versions[]| select(.component!="file")| tojson' <<<"$REPORTED_STATUS") - do - echo $item - COMPONENT="$(jq -r '.component' <<<"$item")" - VERSION="$(jq -r '.version' <<<"$item")" - MODULE="$(jq -r '.module' <<<"$item")" - PACKAGE="${MODULE%%.*}" - curl --fail-with-body -k -o api.json "${PULP_URL}${PULP_API_ROOT}api/v3/docs/api.json?bindings&component=$COMPONENT" - USE_LOCAL_API_JSON=1 ./generate.sh "${PACKAGE}" python "${VERSION}" - cmd_prefix pip3 install "/root/pulp-openapi-generator/${PACKAGE}-client" - sudo rm -rf "./${PACKAGE}-client" - done - fi +if [ "$(jq -r '.domain_enabled' <<<"$REPORTED_STATUS")" = "true" ] +then + # Workaround: Domains are not supported by the published bindings. + # Generate new bindings for all packages. + for item in $(jq -r '.versions[] | tojson' <<<"$REPORTED_STATUS") + do + echo $item + COMPONENT="$(jq -r '.component' <<<"$item")" + VERSION="$(jq -r '.version' <<<"$item")" + MODULE="$(jq -r '.module' <<<"$item")" + PACKAGE="${MODULE%%.*}" + cmd_prefix pulpcore-manager openapi --bindings --component "${COMPONENT}" > api.json + ./gen-client.sh api.json "${COMPONENT}" python "${PACKAGE}" + cmd_prefix pip3 install "/root/pulp-openapi-generator/${PACKAGE}-client" + sudo rm -rf "./${PACKAGE}-client" + done else - # Infer the client name from the package name by replacing "-" with "_". - # Use the component to infer the package name on older versions of pulpcore. - - if [ "$(echo "$REPORTED_STATUS" | jq -r '.domain_enabled')" = "true" ] - then - # Workaround: Domains are not supported by the published bindings. - # Generate new bindings for all packages. - for item in $(echo "$REPORTED_STATUS" | jq -r '.versions[]|(.package // ("pulp_" + .component)|sub("pulp_core"; "pulpcore"))|sub("-"; "_")') - do - ./generate.sh "${item}" python - cmd_prefix pip3 install "/root/pulp-openapi-generator/${item}-client" - sudo rm -rf "./${item}-client" - done - else - # Sadly: Different pulpcore-versions aren't either... - for item in $(echo "$REPORTED_STATUS" | jq -r '.versions[]|select(.component!="file")|(.package // ("pulp_" + .component)|sub("pulp_core"; "pulpcore"))|sub("-"; "_")') - do - ./generate.sh "${item}" python - cmd_prefix pip3 install "/root/pulp-openapi-generator/${item}-client" - sudo rm -rf "./${item}-client" - done - fi + # Sadly: Different pulpcore-versions aren't either... + for item in $(jq -r '.versions[]| select(.component!="file")| tojson' <<<"$REPORTED_STATUS") + do + echo $item + COMPONENT="$(jq -r '.component' <<<"$item")" + VERSION="$(jq -r '.version' <<<"$item")" + MODULE="$(jq -r '.module' <<<"$item")" + PACKAGE="${MODULE%%.*}" + cmd_prefix pulpcore-manager openapi --bindings --component "${COMPONENT}" > api.json + ./gen-client.sh api.json "${COMPONENT}" python "${PACKAGE}" + cmd_prefix pip3 install "/root/pulp-openapi-generator/${PACKAGE}-client" + sudo rm -rf "./${PACKAGE}-client" + done fi popd diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 3fce0ca3..4c03d5f0 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -39,11 +39,11 @@ jobs: repository: "pulp/pulp-openapi-generator" path: "pulp-openapi-generator" - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" - - uses: "actions/download-artifact@v3" + - uses: "actions/download-artifact@v4" with: name: "plugin_package" path: "pulp_file/dist/" @@ -119,43 +119,50 @@ jobs: docker logs pulp 2>&1 | grep -i pulpcore.deprecation | tee deprecations-${{ matrix.env.TEST }}.txt - name: "Upload Deprecations" - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: - name: "deprecations" + name: "deprecations-${{ matrix.env.TEST }}" path: "pulp_file/deprecations-${{ matrix.env.TEST }}.txt" if-no-files-found: "error" retention-days: 5 + overwrite: true - name: Upload python client packages if: ${{ env.TEST == 'pulp' }} - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: "python-client.tar" path: "pulp_file/file-python-client.tar" if-no-files-found: "error" retention-days: 5 + overwrite: true - name: Upload python client docs if: ${{ env.TEST == 'pulp' }} - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: "python-client-docs.tar" path: "pulp_file/file-python-client-docs.tar" if-no-files-found: "error" retention-days: 5 + overwrite: true - name: Upload Ruby client if: ${{ env.TEST == 'pulp' }} - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: "ruby-client.tar" path: "pulp_file/file-ruby-client.tar" if-no-files-found: "error" retention-days: 5 + overwrite: true - name: Upload built docs if: ${{ env.TEST == 'docs' }} - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: "docs.tar" path: "pulp_file/docs/docs.tar" + if-no-files-found: "error" + retention-days: 5 + overwrite: true - name: "Logs" if: always() diff --git a/.github/workflows/update-labels.yml b/.github/workflows/update-labels.yml index d24f2f83..9de9f4e0 100644 --- a/.github/workflows/update-labels.yml +++ b/.github/workflows/update-labels.yml @@ -19,7 +19,7 @@ jobs: update_backport_labels: runs-on: "ubuntu-latest" steps: - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" - name: "Configure Git with pulpbot name and email" diff --git a/.github/workflows/update_ci.yml b/.github/workflows/update_ci.yml index 9b971f14..d410321a 100644 --- a/.github/workflows/update_ci.yml +++ b/.github/workflows/update_ci.yml @@ -29,7 +29,7 @@ jobs: repository: "pulp/plugin_template" path: "plugin_template" - - uses: "actions/setup-python@v4" + - uses: "actions/setup-python@v5" with: python-version: "3.11" diff --git a/CHANGES.md b/CHANGES.md new file mode 100644 index 00000000..d7a34e11 --- /dev/null +++ b/CHANGES.md @@ -0,0 +1,509 @@ +# Changelog + +[//]: # (You should *NOT* be adding new change log entries to this file, this) +[//]: # (file is managed by towncrier. You *may* edit previous change logs to) +[//]: # (fix problems like typo corrections or such.) +[//]: # (To add a new change log entry, please see the contributing docs.) +[//]: # (WARNING: Don't drop the towncrier directive!) + +[//]: # (towncrier release notes start) + +## 1.11.3 (2023-01-27) {: #1.11.3 } + +No significant changes. + +--- + +## 1.11.2 (2022-10-18) {: #1.11.2 } + +No significant changes. + +--- + +## 1.11.1 (2022-08-01) {: #1.11.1 } + +No significant changes. + +--- + +## 1.11.0 (2022-07-28) {: #1.11.0 } + +### Features + +- Added Role Based Access Control for each endpoint. + + * New default roles (creator, owner, viewer) have been added for `FileRepository`, `FileRemote`, + `FileDistribution`, `FilePublication`, and `FileAlternateContentSource`. + + * New detail role management endpoints (`my_permissions`, `list_roles`, `add_role`, + `remove_role`) have been added to each endpoint. + [#626](https://github.com/pulp/pulp_file/issues/626) + +- File Content is now scoped based on repositories the user has permission to see. + [#724](https://github.com/pulp/pulp_file/issues/724) + +- Added new condition on file uploads to require `repository` field if user is not an admin. + [#729](https://github.com/pulp/pulp_file/issues/729) + +### Bugfixes + +- Improved the error message shown when a user specifies an invalid path to the manifest file, or the manifest file is in the incorrect format. + [#605](https://github.com/pulp/pulp_file/issues/605) +- The relative_path field of PULP_MANIFEST can now contain commas, since they are valid filename characters in both Linux and Windows filesystems. + [#630](https://github.com/pulp/pulp_file/issues/630) +- Fixed a bug where publish used /tmp/ instead of the worker working directory. + [#676](https://github.com/pulp/pulp_file/issues/676) + +### Misc + +- [#691](https://github.com/pulp/pulp_file/issues/691) + +--- + +## 1.10.3 (2022-06-22) {: #1.10.3 } + +No significant changes. + +--- + +## 1.10.2 (2022-02-23) {: #1.10.2 } + +### Bugfixes + +- Fixed packaging bug which didn't allow pulp_file 1.10 to be installed with pulpcore 3.18.0. + [#645](https://pulp.plan.io/issues/645) + +--- + +## 1.10.1 (2021-11-02) {: #1.10.1 } + +No significant changes. + +--- + +## 1.10.0 (2021-10-06) {: #1.10.0 } + +### Features + +- Added in validation of ACS paths. + [#9341](https://pulp.plan.io/issues/9341) +- Added refresh endpoint for Alternate Content Sources. + [#9377](https://pulp.plan.io/issues/9377) +- Enabled remote type validation for the ACS. + [#9384](https://pulp.plan.io/issues/9384) + +### Bugfixes + +- Fixed bug where sync tasks would open a lot of DB connections. + [#9252](https://pulp.plan.io/issues/9252) +- Fixed bug where user hidden repos were visible to the user. + [#9416](https://pulp.plan.io/issues/9416) +- Check whether ACS exists before refreshing it. + [#9420](https://pulp.plan.io/issues/9420) + +### Improved Documentation + +- Updated ACS docs to use CLI. + [#9373](https://pulp.plan.io/issues/9373) + +### Misc + +- [#9357](https://pulp.plan.io/issues/9357), [#9426](https://pulp.plan.io/issues/9426) + +--- + +## 1.9.1 (2021-08-30) {: #1.9.1 } + +### Bugfixes + +- Fixed bug where sync tasks would open a lot of DB connections. + (backported from #9252) + [#9311](https://pulp.plan.io/issues/9311) + +--- + +## 1.9.0 (2021-08-26) {: #1.9.0 } + +### Features + +- Enable reclaim disk feature provided by pulpcore. This feature is available with pulpcore 3.15+. + [#9168](https://pulp.plan.io/issues/9168) + +### Bugfixes + +- Fix an issue where "mirror=True" syncs of a repository which has already been synced, and has not changed since the last sync, would fail. + [#8999](https://pulp.plan.io/issues/8999) +- Fixed failing 0012_delete_filefilesystemexporter migration which errors if there are + `FileFilesystemExporters`. + [#9102](https://pulp.plan.io/issues/9102) +- Fixed filtering content by sha256 for on-demand content. + [#9117](https://pulp.plan.io/issues/9117) + +### Deprecations and Removals + +- Dropped support for Python 3.6 and 3.7. pulp_file now supports Python 3.8+. + [#9037](https://pulp.plan.io/issues/9037) + +### Misc + +- [#8959](https://pulp.plan.io/issues/8959), [#9154](https://pulp.plan.io/issues/9154) + +--- + +## 1.8.2 (2021-07-21) {: #1.8.2 } + +### Bugfixes + +- Fix an issue where "mirror=True" syncs of a repository which has already been synced, and has not changed since the last sync, would fail. + (backported from #8999) + [#9060](https://pulp.plan.io/issues/9060) +- Fixed failing 0012_delete_filefilesystemexporter migration which errors if there are + `FileFilesystemExporters`. + (backported from #9102) + [#9122](https://pulp.plan.io/issues/9122) + +--- + +## 1.8.1 (2021-07-01) {: #1.8.1 } + +### Misc + +- [#8969](https://pulp.plan.io/issues/8969) + +--- + +## 1.8.0 (2021-06-11) {: #1.8.0 } + +### Features + +- Auto-publish no longer modifies distributions. + Auto-distribute now only requires setting a distribution's `repository` field. + [#8762](https://pulp.plan.io/issues/8762) +- Performing a sync with "mirror=True" will automatically generate a publication at sync-time. + [#8851](https://pulp.plan.io/issues/8851) + +### Deprecations and Removals + +- The filesystem export functionality has been removed from pulp_file. Users should now use the + filesystem export functionaliy in pulpcore instead. Upgrading to pulp_file 1.8.0 will drop any + `FilesystemExporters` in pulp_file. + [#8861](https://pulp.plan.io/issues/8861) + +### Misc + +- [#8719](https://pulp.plan.io/issues/8719) + +--- + +## 1.7.0 (2021-04-16) {: #1.7.0 } + +### Features + +- Add support for automatic publishing and distributing. + [#7469](https://pulp.plan.io/issues/7469) + +### Improved Documentation + +- Documented the auto-publication and auto-distribution feature. + [#8548](https://pulp.plan.io/issues/8548) + +### Misc + +- [#8387](https://pulp.plan.io/issues/8387), [#8415](https://pulp.plan.io/issues/8415), [#8508](https://pulp.plan.io/issues/8508) + +--- + +## 1.6.1 (2021-03-30) {: #1.6.1 } + +### Bugfixes + +- Added asynchronous tasking to the Update and Delete endpoints of FilesystemExporter to provide proper locking on resources. + [#8451](https://pulp.plan.io/issues/8451) + +### Deprecations and Removals + +- Update and Delete endpoints of FilesystemExporter changed to return 202 with tasks. + [#8451](https://pulp.plan.io/issues/8451) + +--- + +## 1.6.0 (2021-03-05) {: #1.6.0 } + +### Bugfixes + +- Fixed a bug which caused the plugin to report the default manifest's name instead of the specified + one in the publication endpoint. + [#7838](https://pulp.plan.io/issues/7838) + +### Improved Documentation + +- Update workflow docs to pulp-cli. + [#7530](https://pulp.plan.io/issues/7530) +- Add demo requirement to the Contributing process. + [#7704](https://pulp.plan.io/issues/7704) +- Update docs link in README. + [#7932](https://pulp.plan.io/issues/7932) +- Use the ReadTheDocs theme for pulp_file docs. + [#8165](https://pulp.plan.io/issues/8165) + +--- + +## 1.5.0 (2020-12-15) {: #1.5.0 } + +No significant changes. Addressed pulpcore 3.9 deprecations. + +--- + +## 1.4.0 (2020-12-02) {: #1.4.0 } + +### Bugfixes + +- Added some missing files to MANIFEST.in. + [#7685](https://pulp.plan.io/issues/7685) + +### Improved Documentation + +- Documented that a functional test is now a requirement for a feature or a bug fix. + [#7437](https://pulp.plan.io/issues/7437) + +--- + +## 1.3.0 (2020-09-23) {: #1.3.0 } + +### Bugfixes + +- Fixed exception when hitting `/pulp/api/v3/exporters/file/filesystem//exports/`. + [#7522](https://pulp.plan.io/issues/7522) + +### Improved Documentation + +- Added docs for using FileSystemExporter. + [#7515](https://pulp.plan.io/issues/7515) + +### Misc + +- [#7454](https://pulp.plan.io/issues/7454) + +--- + +## 1.2.0 (2020-08-13) {: #1.2.0 } + +### Features + +- Added ability for users to add Remote to Repository and automatically use it when syncing. + [#7135](https://pulp.plan.io/issues/7135) + +### Improved Documentation + +- Fixed the name of the artifact field + [#5966](https://pulp.plan.io/issues/5966) + +### Misc + +- [#6936](https://pulp.plan.io/issues/6936) + +--- + +## 1.1.0 (2020-07-08) {: #1.1.0 } + +### Bugfixes + +- Including requirements.txt on MANIFEST.in + [#6885](https://pulp.plan.io/issues/6885) + +### Improved Documentation + +- Added a remainder about the recommended utilities used in the workflows. + [#5998](https://pulp.plan.io/issues/5998) +- Updated fixture links from fedorapeople.org to fixtures.pulpproject.org. + [#6653](https://pulp.plan.io/issues/6653) + +--- + +## 1.0.1 (2020-06-03) {: #1.0.1 } + +### Bugfixes + +- Including requirements.txt on MANIFEST.in + [#6885](https://pulp.plan.io/issues/6885) + +--- + +## 1.0.0 (2020-05-27) {: #1.0.0 } + +### Misc + +- [#6514](https://pulp.plan.io/issues/6514), [#6708](https://pulp.plan.io/issues/6708), [#6730](https://pulp.plan.io/issues/6730), [#6761](https://pulp.plan.io/issues/6761) + +--- + +## 0.3.0 (2020-04-16) {: #0.3.0 } + +### Features + +- Added history for filesystem exports at `/exporters/file/filesystem//exports/`. + [#6328](https://pulp.plan.io/issues/6328) +- Add support for import/export processing + [#6472](https://pulp.plan.io/issues/6472) + +### Deprecations and Removals + +- The fileystem exporter endpoint has been moved from `/exporters/file/file/` to + `/exporters/file/filesystem/` and the export endpoint is now at POST + `/exporters/file/filesystem//exports/`. Additionally, the table is being dropped and + recreated due to a data structure change in core so users will lose any filesystem exporter data on + upgrade. + [#6328](https://pulp.plan.io/issues/6328) + +### Misc + +- [#6155](https://pulp.plan.io/issues/6155), [#6300](https://pulp.plan.io/issues/6300), [#6362](https://pulp.plan.io/issues/6362), [#6392](https://pulp.plan.io/issues/6392) + +--- + +## 0.2.0 (2020-02-26) {: #0.2.0 } + +### Deprecations and Removals + +- Renamed the filter for the field 'digest' to 'sha256' to correspond to field name in API and other + plugins. + [#5965](https://pulp.plan.io/issues/5965) + +### Misc + +- [#5567](https://pulp.plan.io/issues/5567) + +--- + +## 0.1.1 (2020-01-31) {: #0.1.1 } + +### Bugfixes + +- Adjusts setup.py classifier to show 0.1.0 as Production/Stable. + [#5897](https://pulp.plan.io/issues/5897) + +### Misc + +- [#5867](https://pulp.plan.io/issues/5867), [#5872](https://pulp.plan.io/issues/5872), [#5967](https://pulp.plan.io/issues/5967), [#6016](https://pulp.plan.io/issues/6016) + +--- + +## 0.1.0 (2019-12-12) {: #0.1.0 } + +### Improved Documentation + +- Labeling Exporters as tech preview. + [#5563](https://pulp.plan.io/issues/5563) + +### Misc + +- [#5701](https://pulp.plan.io/issues/5701) + +--- + +## 0.1.0rc2 (2019-12-03) + +### Features + +- Add checking for path overlapping for RepositoryVersions and Publications. + [#5559](https://pulp.plan.io/issues/5559) + +### Misc + +- [#5757](https://pulp.plan.io/issues/5757) + +--- + +## 0.1.0rc1 (2019-11-14) + +### Features + +- Sync, Upload, and Modify now have added content with the same relative_path as existing content + will remove the existing content. + [#3541](https://pulp.plan.io/issues/3541) +- Change relative_path from CharField to TextField + [#4544](https://pulp.plan.io/issues/4544) +- Added support for exporting file publications to the filesystem. + [#5086](https://pulp.plan.io/issues/5086) + +### Deprecations and Removals + +- Sync is no longer available at the {remote_href}/sync/ repository={repo_href} endpoint. Instead, use POST {repo_href}/sync/ remote={remote_href}. + + Creating / listing / editing / deleting file repositories is now performed on /pulp/api/v3/file/file/ instead of /pulp/api/v3/repositories/. Only file content can be present in a file repository, and only a file repository can hold file content. + [#5625](https://pulp.plan.io/issues/5625) + +### Misc + +- [#3308](https://pulp.plan.io/issues/3308), [#5458](https://pulp.plan.io/issues/5458), [#5580](https://pulp.plan.io/issues/5580), [#5629](https://pulp.plan.io/issues/5629) + +--- + +## 0.1.0b4 (2019-10-15) + +### Bugfixes + +- New RepositoryVersions will remove an existing unit at the same relative_path. This is true for + both sync and upload, and is per Repository. + [#4028](https://pulp.plan.io/issues/4028) + +### Improved Documentation + +- Change the prefix of Pulp services from pulp-* to pulpcore-* + [#4554](https://pulp.plan.io/issues/4554) + +### Deprecations and Removals + +- Change _id, _created, _last_updated, _href to pulp_id, pulp_created, pulp_last_updated, pulp_href + [#5457](https://pulp.plan.io/issues/5457) +- Remove "_" from _versions_href, _latest_version_href + [#5548](https://pulp.plan.io/issues/5548) +- Removing base field: _type . + [#5550](https://pulp.plan.io/issues/5550) + +--- + +## 0.1.0b3 (2019-09-30) + +### Features + +- Setting code on ProgressBar. + [#5184](https://pulp.plan.io/issues/5184) +- Add upload functionality to the file content endpoint. + [#5403](https://pulp.plan.io/issues/5403) + +### Deprecations and Removals + +- Adjust FileContentSerializer to upstream change. + [#5428](https://pulp.plan.io/issues/5428) + +### Misc + +- [#5304](https://pulp.plan.io/issues/5304), [#5444](https://pulp.plan.io/issues/5444) + +--- + +## 0.1.0b2 (2019-09-11) + +### Improved Documentation + +- Fix the code snippet provided in the example for creating a file content + [#5094](https://pulp.plan.io/issues/5094) + +### Misc + +- [#4681](https://pulp.plan.io/issues/4681) + +--- + +## 0.1.0b1 (2019-07-09) + +### Features + +- Override the Remote's serializer to allow policy='on_demand' and policy='streamed'. + [#4990](https://pulp.plan.io/issues/4990) + +### Improved Documentation + +- Switch to using [towncrier](https://github.com/hawkowl/towncrier) for better release notes. + [#4875](https://pulp.plan.io/issues/4875) diff --git a/CHANGES.rst b/CHANGES.rst deleted file mode 100644 index 0d658720..00000000 --- a/CHANGES.rst +++ /dev/null @@ -1,735 +0,0 @@ -========= -Changelog -========= - -.. - You should *NOT* be adding new change log entries to this file, this - file is managed by towncrier. You *may* edit previous change logs to - fix problems like typo corrections or such. - To add a new change log entry, please see - https://docs.pulpproject.org/en/3.0/nightly/contributing/git.html#changelog-update - - WARNING: Don't drop the next directive! - -.. towncrier release notes start - -1.11.3 (2023-01-27) -=================== - - -No significant changes. - - ----- - - -1.11.2 (2022-10-18) -=================== - - -No significant changes. - - ----- - - -1.11.1 (2022-08-01) -=================== - - -No significant changes. - - ----- - - -1.11.0 (2022-07-28) -=================== - - -Features --------- - -- Added Role Based Access Control for each endpoint. - * New default roles (creator, owner, viewer) have been added for ``FileRepository``, ``FileRemote``, - ``FileDistribution``, ``FilePublication``, and ``FileAlternateContentSource``. - * New detail role management endpoints (``my_permissions``, ``list_roles``, ``add_role``, - ``remove_role``) have been added to each endpoint. - `#626 `__ -- File Content is now scoped based on repositories the user has permission to see. - `#724 `__ -- Added new condition on file uploads to require ``repository`` field if user is not an admin. - `#729 `__ - - -Bugfixes --------- - -- Improved the error message shown when a user specifies an invalid path to the manifest file, or the manifest file is in the incorrect format. - `#605 `__ -- The relative_path field of PULP_MANIFEST can now contain commas, since they are valid filename characters in both Linux and Windows filesystems. - `#630 `__ -- Fixed a bug where publish used /tmp/ instead of the worker working directory. - `#676 `__ - - -Misc ----- - -- `#691 `__ - - ----- - - -1.10.3 (2022-06-22) -=================== - - -No significant changes. - - ----- - - -1.10.2 (2022-02-23) -=================== - - -Bugfixes --------- - -- Fixed packaging bug which didn't allow pulp_file 1.10 to be installed with pulpcore 3.18.0. - `#645 `_ - - ----- - - -1.10.1 (2021-11-02) -=================== - - -No significant changes. - - ----- - - -1.10.0 (2021-10-06) -=================== - - -Features --------- - -- Added in validation of ACS paths. - `#9341 `_ -- Added refresh endpoint for Alternate Content Sources. - `#9377 `_ -- Enabled remote type validation for the ACS. - `#9384 `_ - - -Bugfixes --------- - -- Fixed bug where sync tasks would open a lot of DB connections. - `#9252 `_ -- Fixed bug where user hidden repos were visible to the user. - `#9416 `_ -- Check whether ACS exists before refreshing it. - `#9420 `_ - - -Improved Documentation ----------------------- - -- Updated ACS docs to use CLI. - `#9373 `_ - - -Misc ----- - -- `#9357 `_, `#9426 `_ - - ----- - - -1.9.1 (2021-08-30) -================== - - -Bugfixes --------- - -- Fixed bug where sync tasks would open a lot of DB connections. - (backported from #9252) - `#9311 `_ - - ----- - - -1.9.0 (2021-08-26) -================== - - -Features --------- - -- Enable reclaim disk feature provided by pulpcore. This feature is available with pulpcore 3.15+. - `#9168 `_ - - -Bugfixes --------- - -- Fix an issue where "mirror=True" syncs of a repository which has already been synced, and has not changed since the last sync, would fail. - `#8999 `_ -- Fixed failing 0012_delete_filefilesystemexporter migration which errors if there are - ``FileFilesystemExporters``. - `#9102 `_ -- Fixed filtering content by sha256 for on-demand content. - `#9117 `_ - - -Deprecations and Removals -------------------------- - -- Dropped support for Python 3.6 and 3.7. pulp_file now supports Python 3.8+. - `#9037 `_ - - -Misc ----- - -- `#8959 `_, `#9154 `_ - - ----- - - -1.8.2 (2021-07-21) -================== - - -Bugfixes --------- - -- Fix an issue where "mirror=True" syncs of a repository which has already been synced, and has not changed since the last sync, would fail. - (backported from #8999) - `#9060 `_ -- Fixed failing 0012_delete_filefilesystemexporter migration which errors if there are - ``FileFilesystemExporters``. - (backported from #9102) - `#9122 `_ - - ----- - - -1.8.1 (2021-07-01) -================== - -Misc ----- - -- `#8969 `_ - - ----- - - -1.8.0 (2021-06-11) -================== - -Features --------- - -- Auto-publish no longer modifies distributions. - Auto-distribute now only requires setting a distribution's ``repository`` field. - `#8762 `_ -- Performing a sync with "mirror=True" will automatically generate a publication at sync-time. - `#8851 `_ - - -Deprecations and Removals -------------------------- - -- The filesystem export functionality has been removed from pulp_file. Users should now use the - filesystem export functionaliy in pulpcore instead. Upgrading to pulp_file 1.8.0 will drop any - ``FilesystemExporters`` in pulp_file. - `#8861 `_ - - -Misc ----- - -- `#8719 `_ - - ----- - - -1.7.0 (2021-04-16) -================== - - -Features --------- - -- Add support for automatic publishing and distributing. - `#7469 `_ - - -Improved Documentation ----------------------- - -- Documented the auto-publication and auto-distribution feature. - `#8548 `_ - - -Misc ----- - -- `#8387 `_, `#8415 `_, `#8508 `_ - - ----- - - -1.6.1 (2021-03-30) -================== - - -Bugfixes --------- - -- Added asynchronous tasking to the Update and Delete endpoints of FilesystemExporter to provide proper locking on resources. - `#8451 `_ - - -Deprecations and Removals -------------------------- - -- Update and Delete endpoints of FilesystemExporter changed to return 202 with tasks. - `#8451 `_ - - ----- - - -1.6.0 (2021-03-05) -================== - - -Bugfixes --------- - -- Fixed a bug which caused the plugin to report the default manifest's name instead of the specified - one in the publication endpoint. - `#7838 `_ - - -Improved Documentation ----------------------- - -- Update workflow docs to pulp-cli. - `#7530 `_ -- Add demo requirement to the Contributing process. - `#7704 `_ -- Update docs link in README. - `#7932 `_ -- Use the ReadTheDocs theme for pulp_file docs. - `#8165 `_ - - ----- - - -1.5.0 (2020-12-15) -================== - - -No significant changes. Addressed pulpcore 3.9 deprecations. - - ----- - - -1.4.0 (2020-12-02) -================== - - -Bugfixes --------- - -- Added some missing files to MANIFEST.in. - `#7685 `_ - - -Improved Documentation ----------------------- - -- Documented that a functional test is now a requirement for a feature or a bug fix. - `#7437 `_ - - ----- - - -1.3.0 (2020-09-23) -================== - - -Bugfixes --------- - -- Fixed exception when hitting ``/pulp/api/v3/exporters/file/filesystem//exports/``. - `#7522 `_ - - -Improved Documentation ----------------------- - -- Added docs for using FileSystemExporter. - `#7515 `_ - - -Misc ----- - -- `#7454 `_ - - ----- - - -1.2.0 (2020-08-13) -================== - - -Features --------- - -- Added ability for users to add Remote to Repository and automatically use it when syncing. - `#7135 `_ - - -Improved Documentation ----------------------- - -- Fixed the name of the artifact field - `#5966 `_ - - -Misc ----- - -- `#6936 `_ - - ----- - - -1.1.0 (2020-07-08) -================== - - -Bugfixes --------- - -- Including requirements.txt on MANIFEST.in - `#6885 `_ - - -Improved Documentation ----------------------- - -- Added a remainder about the recommended utilities used in the workflows. - `#5998 `_ -- Updated fixture links from fedorapeople.org to fixtures.pulpproject.org. - `#6653 `_ - - ----- - - -1.0.1 (2020-06-03) -================== - - -Bugfixes --------- - -- Including requirements.txt on MANIFEST.in - `#6885 `_ - - ----- - - -1.0.0 (2020-05-27) -================== - - -Misc ----- - -- `#6514 `_, `#6708 `_, `#6730 `_, `#6761 `_ - - ----- - - -0.3.0 (2020-04-16) -================== - - -Features --------- - -- Added history for filesystem exports at ``/exporters/file/filesystem//exports/``. - `#6328 `_ -- Add support for import/export processing - `#6472 `_ - - -Deprecations and Removals -------------------------- - -- The fileystem exporter endpoint has been moved from ``/exporters/file/file/`` to - ``/exporters/file/filesystem/`` and the export endpoint is now at POST - ``/exporters/file/filesystem//exports/``. Additionally, the table is being dropped and - recreated due to a data structure change in core so users will lose any filesystem exporter data on - upgrade. - `#6328 `_ - - -Misc ----- - -- `#6155 `_, `#6300 `_, `#6362 `_, `#6392 `_ - - ----- - - -0.2.0 (2020-02-26) -================== - - -Deprecations and Removals -------------------------- - -- Renamed the filter for the field 'digest' to 'sha256' to correspond to field name in API and other - plugins. - `#5965 `_ - - -Misc ----- - -- `#5567 `_ - - ----- - - -0.1.1 (2020-01-31) -================== - - -Bugfixes --------- - -- Adjusts setup.py classifier to show 0.1.0 as Production/Stable. - `#5897 `_ - - -Misc ----- - -- `#5867 `_, `#5872 `_, `#5967 `_, `#6016 `_ - - ----- - - -0.1.0 (2019-12-12) -================== - - -Improved Documentation ----------------------- - -- Labeling Exporters as tech preview. - `#5563 `_ - - -Misc ----- - -- `#5701 `_ - - ----- - - -0.1.0rc2 (2019-12-03) -===================== - - -Features --------- - -- Add checking for path overlapping for RepositoryVersions and Publications. - `#5559 `_ - - -Misc ----- - -- `#5757 `_ - - ----- - - -0.1.0rc1 (2019-11-14) -===================== - - -Features --------- - -- Sync, Upload, and Modify now have added content with the same `relative_path` as existing content - will remove the existing content. - `#3541 `_ -- Change `relative_path` from `CharField` to `TextField` - `#4544 `_ -- Added support for exporting file publications to the filesystem. - `#5086 `_ - - -Deprecations and Removals -------------------------- - -- Sync is no longer available at the {remote_href}/sync/ repository={repo_href} endpoint. Instead, use POST {repo_href}/sync/ remote={remote_href}. - - Creating / listing / editing / deleting file repositories is now performed on /pulp/api/v3/file/file/ instead of /pulp/api/v3/repositories/. Only file content can be present in a file repository, and only a file repository can hold file content. - `#5625 `_ - - -Misc ----- - -- `#3308 `_, `#5458 `_, `#5580 `_, `#5629 `_ - - ----- - - -0.1.0b4 (2019-10-15) -==================== - - -Bugfixes --------- - -- New RepositoryVersions will remove an existing unit at the same `relative_path`. This is true for - both `sync` and `upload`, and is per Repository. - `#4028 `_ - - -Improved Documentation ----------------------- - -- Change the prefix of Pulp services from pulp-* to pulpcore-* - `#4554 `_ - - -Deprecations and Removals -------------------------- - -- Change `_id`, `_created`, `_last_updated`, `_href` to `pulp_id`, `pulp_created`, `pulp_last_updated`, `pulp_href` - `#5457 `_ -- Remove "_" from `_versions_href`, `_latest_version_href` - `#5548 `_ -- Removing base field: `_type` . - `#5550 `_ - - ----- - - -0.1.0b3 (2019-09-30) -==================== - - -Features --------- - -- Setting `code` on `ProgressBar`. - `#5184 `_ -- Add upload functionality to the file content endpoint. - `#5403 `_ - - -Deprecations and Removals -------------------------- - -- Adjust FileContentSerializer to upstream change. - `#5428 `_ - - -Misc ----- - -- `#5304 `_, `#5444 `_ - - ----- - - -0.1.0b2 (2019-09-11) -==================== - - -Improved Documentation ----------------------- - -- Fix the code snippet provided in the example for creating a file content - `#5094 `_ - - -Misc ----- - -- `#4681 `_ - - ----- - - -0.1.0b1 (2019-07-09) -==================== - - -Features --------- - -- Override the Remote's serializer to allow policy='on_demand' and policy='streamed'. - `#4990 `_ - - -Improved Documentation ----------------------- - -- Switch to using `towncrier `_ for better release notes. - `#4875 `_ - - diff --git a/CHANGES/.TEMPLATE.md b/CHANGES/.TEMPLATE.md new file mode 100644 index 00000000..2308193b --- /dev/null +++ b/CHANGES/.TEMPLATE.md @@ -0,0 +1,39 @@ +{# TOWNCRIER TEMPLATE #} +{% for section, _ in sections.items() %} +{%- set section_slug = "-" + section|replace(" ", "-")|replace("_", "-")|lower %} +{%- if section %} + +### {{section}} {: #{{versiondata.version}}{{section_slug}} } +{% else %} +{%- set section_slug = "" %} +{% endif %} +{% if sections[section] %} +{% for category, val in definitions.items() if category in sections[section]%} + +#### {{ definitions[category]['name'] }} {: #{{versiondata.version}}{{section_slug}}-{{category}} } + +{% if definitions[category]['showcontent'] %} +{% for text, values in sections[section][category].items() %} +- {{ text }} +{% if values %} + {{ values|join(',\n ') }} +{% endif %} +{% endfor %} +{% else %} +- {{ sections[section][category]['']|join(', ') }} +{% endif %} +{% if sections[section][category]|length == 0 %} + +No significant changes. +{% else %} +{% endif %} +{% endfor %} +{% else %} + +No significant changes. +{% endif %} +{% endfor %} + +--- + + diff --git a/MANIFEST.in b/MANIFEST.in index 8e37e332..69515046 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,7 +1,7 @@ include LICENSE include requirements.txt include pyproject.toml -include CHANGES.rst +include CHANGES.md include COMMITMENT include COPYRIGHT include ci_requirements.txt diff --git a/docs/changes.rst b/docs/changes.rst index de928d92..96e8eb90 100644 --- a/docs/changes.rst +++ b/docs/changes.rst @@ -1,5 +1,4 @@ -.. _pulp-file-changes: +Changes +********* -.. include:: ../CHANGES.rst - -.. include:: ../HISTORY.rst +Removed due to docs migration process. diff --git a/pyproject.toml b/pyproject.toml index 612d35b1..aef8ada7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -7,11 +7,13 @@ build-backend = 'setuptools.build_meta' [tool.towncrier] package = "pulp_file" -filename = "CHANGES.rst" +filename = "CHANGES.md" directory = "CHANGES/" -title_format = "{version} ({project_date})" -template = "CHANGES/.TEMPLATE.rst" -issue_format = "`#{issue} `__" +title_format = "## {version} ({project_date}) {{: #{version} }}" +template = "CHANGES/.TEMPLATE.md" +issue_format = "[#{issue}](https://github.com/pulp/pulp_file/issues/{issue})" +start_string = "[//]: # (towncrier release notes start)\n" +underlines = ["", "", ""] [tool.black] line-length = 100