[med-svn] [Git][python-team/packages/python-schema-salad][upstream] New upstream version 8.5.20240410123758

Michael R. Crusoe (@crusoe) gitlab at salsa.debian.org
Wed Apr 10 14:47:57 BST 2024



Michael R. Crusoe pushed to branch upstream at Debian Python Team / packages / python-schema-salad


Commits:
6912d49b by Michael R. Crusoe at 2024-04-10T16:35:56+03:00
New upstream version 8.5.20240410123758
- - - - -


14 changed files:

- .circleci/config.yml
- − .github/workflows/wheel-prep.sh
- .github/workflows/wheels.yml
- PKG-INFO
- cibw-requirements.txt
- dev-requirements.txt
- mypy-requirements.txt
- pyproject.toml
- requirements.txt
- schema_salad.egg-info/PKG-INFO
- schema_salad.egg-info/SOURCES.txt
- schema_salad/_version.py
- + schema_salad/typescript/test/LoadingOptions.spec.ts
- schema_salad/typescript/util/LoadingOptions.ts


Changes:

=====================================
.circleci/config.yml
=====================================
@@ -40,7 +40,6 @@ jobs:
           command: |
             python3 -m pip install --upgrade pip setuptools setuptools_scm[toml]
             python3 -m pip install -rcibw-requirements.txt
-            python3 ./setup.py --version
 
       - run:
           name: pip freeze
@@ -55,14 +54,7 @@ jobs:
       - run:
           name: cibuildwheel
           command: |
-            source .github/workflows/wheel-prep.sh
-            export CIBW_ENVIRONMENT="SCHEMA_SALAD_USE_MYPYC=1 MYPYPATH=/project/mypy-stubs SETUPTOOLS_SCM_PRETEND_VERSION=${SETUPTOOLS_SCM_PRETEND_VERSION}"
             python3 -m cibuildwheel .
-            # "/project" is the project path inside the cibuildwheel container itself
-
-      - run:
-          name: move tests results out of the wheelhouse
-          command: mv wheelhouse/test-results ./
 
       - store_test_results:
           path: test-results/


=====================================
.github/workflows/wheel-prep.sh deleted
=====================================
@@ -1,3 +0,0 @@
-export SCHEMA_SALAD_USE_MYPYC=1
-export MYPYPATH=mypy-stubs
-export SETUPTOOLS_SCM_PRETEND_VERSION=$(grep __version__ schema_salad/_version.py  | awk -F\' '{ print $2 }')


=====================================
.github/workflows/wheels.yml
=====================================
@@ -35,28 +35,15 @@ jobs:
           fetch-depth: 0  # slow, but gets all the tags
           ref: ${{ github.event.client_payload.ref }}
 
-      # Used to host cibuildwheel
-      - uses: actions/setup-python at v5
-
       # - name: Set up QEMU
       #   if: runner.os == 'Linux'
       #   uses: docker/setup-qemu-action at v2
       #   with:
       #     platforms: all
 
-      - name: Install cibuildwheel
-        run: python -m pip install -rcibw-requirements.txt
-
-      - name: set version
-        run: pip install setuptools_scm[toml] wheel && python setup.py --version
-
       - name: Build wheels
-        run: |
-          source .github/workflows/wheel-prep.sh
-          export CIBW_ENVIRONMENT="SCHEMA_SALAD_USE_MYPYC=1 MYPYPATH=/project/mypy-stubs SETUPTOOLS_SCM_PRETEND_VERSION=${SETUPTOOLS_SCM_PRETEND_VERSION}"
-          python -m cibuildwheel --output-dir wheelhouse
+        uses: pypa/cibuildwheel at v2.17.0
         env:
-          CIBW_ARCHS_MACOS: x86_64 arm64
           CIBW_BUILD: ${{ matrix.build }}
           CIBW_MANYLINUX_X86_64_IMAGE: quay.io/pypa/${{ matrix.image }}
           CIBW_MUSLLINUX_X86_64_IMAGE: quay.io/pypa/${{ matrix.image }}
@@ -84,9 +71,6 @@ jobs:
           fetch-depth: 0  # slow, but gets all the tags
           ref: ${{ github.event.client_payload.ref }}
 
-      - name: set version
-        run: pip install setuptools_scm[toml] wheel && python setup.py --version
-
       - name: Build sdist
         run: pipx run build --sdist
 
@@ -95,19 +79,45 @@ jobs:
           name: artifact-source
           path: dist/*.tar.gz
 
+  build_wheels_macos:
+    name: Build wheels on ${{ matrix.os }}
+    runs-on: ${{ matrix.os }}
+    strategy:
+      matrix:
+        # macos-13 is an intel runner, macos-14 is apple silicon
+        os: [macos-13, macos-14]
+    steps:
+      - uses: actions/checkout at v4
+        if: ${{ github.event_name != 'repository_dispatch' }}
+        with:
+          fetch-depth: 0  # slow, but gets all the tags
+      - uses: actions/checkout at v4
+        if: ${{ github.event_name == 'repository_dispatch' }}
+        with:
+          fetch-depth: 0  # slow, but gets all the tags
+          ref: ${{ github.event.client_payload.ref }}
+
+      - name: Build wheels
+        uses: pypa/cibuildwheel at v2.17.0
+
+      - uses: actions/upload-artifact at v4
+        with:
+          name: artifact-${{ matrix.os }}-${{ strategy.job-index }}
+          path: ./wheelhouse/*.whl
+
   upload_pypi:
     needs: [build_wheels, build_sdist]
     runs-on: ubuntu-latest
     environment: pypi
     permissions:
       id-token: write
-    if: github.event_name == 'release' && github.event.action == 'published'
+    if: (github.event_name == 'release' && github.event.action == 'published') || (github.event_name == 'repository_dispatch' && github.event.client_payload.publish_wheel == true)
     steps:
       - uses: actions/download-artifact at v4
         with:
           # unpacks default artifact into dist/
-          # if `name: artifact` is omitted, the action will create extra parent dir
           pattern: artifact-*
+          merge-multiple: true
           path: dist
 
       - uses: pypa/gh-action-pypi-publish at release/v1
@@ -115,4 +125,4 @@ jobs:
           # To test: repository-url: https://test.pypi.org/legacy/
           user: __token__
           password: ${{ secrets.PYPI_API_TOKEN }}
-          skip_existing: true
+          skip-existing: true


=====================================
PKG-INFO
=====================================
@@ -1,6 +1,6 @@
 Metadata-Version: 2.1
 Name: schema-salad
-Version: 8.5.20240311110950
+Version: 8.5.20240410123758
 Summary: Schema Annotations for Linked Avro Data (SALAD)
 Home-page: https://schema-salad.readthedocs.io/
 Download-URL: https://github.com/common-workflow-language/schema_salad/releases


=====================================
cibw-requirements.txt
=====================================
@@ -1 +1 @@
-cibuildwheel==2.16.5
+cibuildwheel==2.17.0


=====================================
dev-requirements.txt
=====================================
@@ -6,7 +6,7 @@ flake8-bugbear < 24.3
 tox < 3.29  # until tox-pyenv is updated for tox 4.x
 tox-pyenv < 1.2
 isort > 5, < 5.14
-build < 1.1.2
+build < 1.2.2
 autoflake < 2.4
 bandit < 1.7.9
 auto-walrus


=====================================
mypy-requirements.txt
=====================================
@@ -1,5 +1,5 @@
 mypy[mypyc]==1.9.0  # update pyproject.toml as well
-black~=24.2
+black~=24.3
 types-requests
 types-dataclasses
 objgraph


=====================================
pyproject.toml
=====================================
@@ -16,13 +16,13 @@ build-backend = "setuptools.build_meta"
 write_to = "schema_salad/_version.py"
 
 [tool.cibuildwheel]
-before-build = "python -m pip install -r requirements.txt -r mypy-requirements.txt"
-test-command = "python -m pytest -n 2 --junitxml=/output/test-results/junit_$(python -V | awk '{print $2}')_${AUDITWHEEL_PLAT}.xml --pyargs schema_salad"
+test-command = "python -m pytest -n 2 --junitxml={project}/test-results/junit_$(python -V | awk '{print $2}')_${AUDITWHEEL_PLAT}.xml --pyargs schema_salad"
 test-requires = "-r test-requirements.txt"
 test-extras = "pycodegen"
 skip = "pp*"
 #      ^ skip building wheels on PyPy (any version)
 build-verbosity = "1"
+environment = { SCHEMA_SALAD_USE_MYPYC="1", MYPYPATH="$(pwd)/mypy-stubs" }
 
 [tool.black]
 line-length = 100


=====================================
requirements.txt
=====================================
@@ -3,6 +3,6 @@ ruamel.yaml >= 0.17.6, < 0.19
 rdflib>= 4.2.2, < 8.0.0
 mistune>=3,<3.1
 CacheControl[filecache]>= 0.11.7, < 0.15
-black>=19.10b0,<24.3
+black>=19.10b0,<24.4
 mypy_extensions
 importlib_resources>=1.4;python_version<'3.9'


=====================================
schema_salad.egg-info/PKG-INFO
=====================================
@@ -1,6 +1,6 @@
 Metadata-Version: 2.1
 Name: schema-salad
-Version: 8.5.20240311110950
+Version: 8.5.20240410123758
 Summary: Schema Annotations for Linked Avro Data (SALAD)
 Home-page: https://schema-salad.readthedocs.io/
 Download-URL: https://github.com/common-workflow-language/schema_salad/releases


=====================================
schema_salad.egg-info/SOURCES.txt
=====================================
@@ -32,7 +32,6 @@ tox.ini
 .github/workflows/ci-tests.yml
 .github/workflows/codeql-analysis.yml
 .github/workflows/quay-publish.yml
-.github/workflows/wheel-prep.sh
 .github/workflows/wheels.yml
 docs/Makefile
 docs/cli.rst
@@ -428,6 +427,7 @@ schema_salad/typescript/test/AnyLoader.spec.ts
 schema_salad/typescript/test/ExampleTest.ts
 schema_salad/typescript/test/Fetcher.spec.ts
 schema_salad/typescript/test/IdMap.spec.ts
+schema_salad/typescript/test/LoadingOptions.spec.ts
 schema_salad/typescript/test/Typeguards.spec.ts
 schema_salad/typescript/test/utilities.spec.ts
 schema_salad/typescript/test/data/hellofield.yml


=====================================
schema_salad/_version.py
=====================================
@@ -12,5 +12,5 @@ __version__: str
 __version_tuple__: VERSION_TUPLE
 version_tuple: VERSION_TUPLE
 
-__version__ = version = '8.5.20240311110950'
-__version_tuple__ = version_tuple = (8, 5, 20240311110950)
+__version__ = version = '8.5.20240410123758'
+__version_tuple__ = version_tuple = (8, 5, 20240410123758)


=====================================
schema_salad/typescript/test/LoadingOptions.spec.ts
=====================================
@@ -0,0 +1,29 @@
+import { assert } from 'chai'
+import { Fetcher, LoadingOptions } from '../util/Internal'
+
+class TestFetcher implements Fetcher {
+  checkExists(url: string): boolean {
+    return true
+  }
+  async fetchText(url: string, contentTypes?: string[] | undefined): Promise<string> {
+    return "TestFetcher"
+  }
+  urljoin(baseUrl: string, url: string): string {
+    return `${baseUrl}/${url}`
+  }
+}
+
+describe('Test LoadingOptions', () => {
+  describe('copyFrom', () => {
+    const original = new LoadingOptions({fetcher: new TestFetcher()})
+    it('should have the same Fetcher as the original', async () => {
+      const copy = new LoadingOptions({copyFrom:original})
+      assert.equal(copy.fetcher,original.fetcher)
+    })
+    it('fetcher should take precedence over copyFrom', async () => {
+      const fetcher = new TestFetcher()
+      const copy = new LoadingOptions({fetcher,copyFrom:original})
+      assert.equal(copy.fetcher,fetcher)
+    })
+  })
+})


=====================================
schema_salad/typescript/util/LoadingOptions.ts
=====================================
@@ -25,7 +25,7 @@ export class LoadingOptions {
     if (copyFrom != null) {
       this.idx = copyFrom.idx
       if (fetcher === undefined) {
-        this.fetcher = copyFrom.fetcher
+        fetcher = copyFrom.fetcher
       }
       if (fileUri === undefined) {
         this.fileUri = copyFrom.fileUri



View it on GitLab: https://salsa.debian.org/python-team/packages/python-schema-salad/-/commit/6912d49b5659500091e6101fb1e273fde3265a01

-- 
View it on GitLab: https://salsa.debian.org/python-team/packages/python-schema-salad/-/commit/6912d49b5659500091e6101fb1e273fde3265a01
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20240410/15e2e517/attachment-0001.htm>


More information about the debian-med-commit mailing list