Skip to content

Commit

Permalink
Merge pull request #1063 from pulp/update-ci/main
Browse files Browse the repository at this point in the history
Update CI files for branch main
  • Loading branch information
hstct authored Apr 8, 2024
2 parents 08145a5 + 84ae851 commit 9996349
Show file tree
Hide file tree
Showing 24 changed files with 33 additions and 11 deletions.
1 change: 1 addition & 0 deletions .ci/scripts/schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
But some pulp paths start with curly brackets e.g. {artifact_href}
This script modifies drf-spectacular schema validation to accept slashes and curly brackets.
"""

import json
from drf_spectacular.validation import JSON_SCHEMA_SPEC_PATH

Expand Down
2 changes: 1 addition & 1 deletion .github/template_gitref
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2021.08.26-324-gb820cc2
2021.08.26-326-ge5addc7
1 change: 1 addition & 0 deletions .github/workflows/scripts/script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ if [[ "$TEST" = "docs" ]]; then
if [[ "$GITHUB_WORKFLOW" == "Deb CI" ]]; then
towncrier build --yes --version 4.0.0.ci
fi
# Legacy Docs Build
cd docs
make PULP_URL="$PULP_URL" diagrams html
tar -cvf docs.tar ./_build
Expand Down
5 changes: 4 additions & 1 deletion doc_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,14 @@
#
# For more info visit https://github.com/pulp/plugin_template
-r requirements.txt
towncrier

# Legacy docs
plantuml
sphinx~=7.1.2
sphinx-rtd-theme==1.3.0
sphinxcontrib-jquery
sphinxcontrib-openapi
towncrier
mistune<4.0.0
Jinja2<3.2
# Extra requirements
2 changes: 1 addition & 1 deletion docs/template_gitref
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2021.08.26-324-gb820cc2
2021.08.26-326-ge5addc7
2 changes: 1 addition & 1 deletion lint_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# For more info visit https://github.com/pulp/plugin_template

# python packages handy for developers, but not required by pulp
black==23.12.1
black==24.3.0
check-manifest
flake8
flake8-black
Expand Down
1 change: 1 addition & 0 deletions pulp_deb/app/models/content/content.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
like language and Debian installer files. Not included are models for metadata files like Release
files or APT repository package indices.
"""

import os

from django.db import models
Expand Down
1 change: 1 addition & 0 deletions pulp_deb/app/models/content/structure_content.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
information. This ensures, that copying structure content between different Pulp repositories, does
not inadvertantly copy anything that is not structure relevant.
"""

import os

from django.db import models
Expand Down
1 change: 1 addition & 0 deletions pulp_deb/app/models/content/verbatim_metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
(down to the checksum) as it was synced from some upstream APT repostiroy. These metadata types are
exclusively used for verbatim publications.
"""

from django.db import models

from pulpcore.plugin.models import Content
Expand Down
6 changes: 3 additions & 3 deletions pulp_deb/app/serializers/content_serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -1169,9 +1169,9 @@ def deferred_validate(self, data):
" and sha256 '{sha256}'."
).format(name=source["name"], sha256=source["sha256"])
)
artifacts[
os.path.join(os.path.dirname(data["relative_path"]), source["name"])
] = content.first()
artifacts[os.path.join(os.path.dirname(data["relative_path"]), source["name"])] = (
content.first()
)

data["artifacts"] = artifacts
return data
Expand Down
1 change: 1 addition & 0 deletions pulp_deb/tests/functional/api/test_crud_content_unit.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests that perform actions over content unit."""

from uuid import uuid4
import pytest

Expand Down
1 change: 1 addition & 0 deletions pulp_deb/tests/functional/api/test_crud_packages.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests that perform actions over packages."""

from uuid import uuid4
import pytest

Expand Down
1 change: 1 addition & 0 deletions pulp_deb/tests/functional/api/test_crud_remotes.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests that CRUD deb remotes."""

from random import choice
from uuid import uuid4
import pytest
Expand Down
1 change: 1 addition & 0 deletions pulp_deb/tests/functional/api/test_download_content.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests that verify download of content served by Pulp."""

import os
import pytest
import hashlib
Expand Down
1 change: 1 addition & 0 deletions pulp_deb/tests/functional/api/test_download_policies.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests for Pulp download policies."""

import pytest

from pulp_deb.tests.functional.constants import DEB_FIXTURE_PACKAGE_COUNT, DEB_FIXTURE_SUMMARY
Expand Down
1 change: 1 addition & 0 deletions pulp_deb/tests/functional/api/test_duplicate_packages.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
To ensure this is the case we use the handle_duplicate_packages function. As such, these tests are
primarily intended to test this function.
"""

import pytest
from uuid import uuid4

Expand Down
6 changes: 3 additions & 3 deletions pulp_deb/tests/functional/api/test_publish.py
Original file line number Diff line number Diff line change
Expand Up @@ -497,7 +497,7 @@ def parse_package_index(pkg_idx):
"""
packages = {}
for package in deb822.Packages.iter_paragraphs(pkg_idx, use_apt_pkg=False):
packages[
"-".join([package["Package"], package["Version"], package["Architecture"]])
] = package
packages["-".join([package["Package"], package["Version"], package["Architecture"]])] = (
package
)
return packages
1 change: 1 addition & 0 deletions pulp_deb/tests/functional/api/test_pulp_to_pulp.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests that verify download of content served by Pulp."""

import pytest

from pulp_deb.tests.functional.constants import (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
NOTE: assumes ALLOWED_EXPORT_PATHS and ALLOWED_IMPORT_PATHS settings contain "/tmp"
all tests will fail if that is not the case.
"""

import pytest

from uuid import uuid4
Expand Down
1 change: 1 addition & 0 deletions pulp_deb/tests/functional/api/test_sync.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests that sync deb repositories in optimized mode."""

import pytest

from pulpcore.tests.functional.utils import PulpTaskError
Expand Down
1 change: 1 addition & 0 deletions pulp_deb/tests/performance/test_publish.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests that publish deb plugin repositories."""

import pytest

from pulp_deb.tests.performance.utils import write_csv_to_tmp
Expand Down
1 change: 1 addition & 0 deletions pulp_deb/tests/performance/test_pulp_to_pulp.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests that verify download of deb content served by Pulp."""

import pytest

from pulp_deb.tests.performance.utils import write_csv_to_tmp
Expand Down
1 change: 1 addition & 0 deletions pulp_deb/tests/performance/test_sync.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests that sync deb plugin repositories."""

import pytest

from pulp_deb.tests.performance.utils import write_csv_to_tmp
Expand Down
4 changes: 3 additions & 1 deletion template_config.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# This config represents the latest values used when running the plugin-template. Any settings that
# were not present before running plugin-template have been added with their default values.

# generated with [email protected]319-ga283c28
# generated with [email protected]326-ge5addc7

api_root: /pulp/
black: true
Expand Down Expand Up @@ -84,4 +84,6 @@ test_performance:
test_reroute: true
test_s3: true
use_issue_template: true
use_legacy_docs: true
use_unified_docs: false

0 comments on commit 9996349

Please sign in to comment.