Index | Thread | Search

From:
Stuart Henderson <stu@spacehopper.org>
Subject:
Re: [UPDATE] py-b2sdk -> 2.4.1
To:
Paul Galbraith <paul@galbraiths.ca>
Cc:
ports@openbsd.org
Date:
Thu, 25 Jul 2024 17:09:37 +0100

Download raw body.

Thread
On 2024/07/24 23:47, Paul Galbraith wrote:
> Update b2sdk to release 2.4.1 -- needed as recent updates in duplicity (e.g.
> https://marc.info/?l=openbsd-ports-cvs&m=169908956215510&w=2) break backups
> over Backblaze B2.

Committed. Some notes below:

> Index: Makefile
> ===================================================================
> RCS file: /cvs/ports/net/py-b2sdk/Makefile,v
> diff -u -p -u -r1.3 Makefile
> --- Makefile	6 May 2024 12:23:47 -0000	1.3
> +++ Makefile	5 Jul 2024 20:52:29 -0000
> @@ -1,8 +1,6 @@
>  COMMENT =		client lib to access B2 cloud storage
>  
> -# optional dep for duplicity; there's a problem with newer versions so holding at
> -# 1.18.0 for now. https://gitlab.com/duplicity/duplicity/-/issues/701
> -MODPY_EGG_VERSION =	1.18.0
> +MODPY_EGG_VERSION =	2.4.1
>  DISTNAME =		b2sdk-${MODPY_EGG_VERSION}
>  PKGNAME =		py-${DISTNAME}
>  CATEGORIES =		devel net
> @@ -13,15 +11,18 @@ PERMIT_PACKAGE =	Yes

please remove REVISION for updates

>  MODULES =		lang/python
>  MODPY_PI =		Yes
> -MODPY_PYBUILD =		setuptools_scm
> +MODPY_PYBUILD =		setuptools

It moved to pdm-backend. That's not handled by python.port.mk yet but
this is the third port using it so I've added it, you can now set
MODPY_PYBUILD=pdm (after updating lang/python/python.port.mk) and remove
the explicit BUILD_DEPENDS on pdm-backend.

Otherwise for a build backend without explicit support in python.port.mk,
set MODPY_PYBUILD=other and add the BUILD_DEPENDS. setuptools is just
meant for setuptools.

It was failing to build if py3-black was installed, but I've fixed that
by updating pdm-backend:

[...]
  File "/usr/local/lib/python3.11/site-packages/pdm/backend/config.py", line 52, in validate
    validator = api.Validator()
                ^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/pdm/backend/_vendor/validate_pyproject/api.py", line 208, in __init__
    self._schema_registry = SchemaRegistry(self._plugins)
                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/pdm/backend/_vendor/validate_pyproject/api.py", line 117, in __init__
    sid = self._ensure_compatibility(tool, schema)["$id"]
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/pdm/backend/_vendor/validate_pyproject/api.py", line 144, in _ensure_compatibility
    raise errors.InvalidSchemaVersion(reference, version, self.spec_version)
pdm.backend._vendor.validate_pyproject.errors.InvalidSchemaVersion: All schemas used in the validator should be specified using the same version     as the toplevel schema ('http://json-schema.org/draft-07/schema').

Schema for 'black' has version 'http://json-schema.org/draft-07/schema#'.

ERROR Backend subprocess exited when trying to invoke get_requires_for_build_wheel