Bug 286927 - devel/py-archinfo: Update 9.2.154 => 9.2.157
Summary: devel/py-archinfo: Update 9.2.154 => 9.2.157
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Vladimir Druzenko
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-05-19 09:40 UTC by Rares Aioanei
Modified: 2025-05-20 21:49 UTC (History)
1 user (show)

See Also:


Attachments
Updated Makefile and distinfo (906 bytes, patch)
2025-05-19 09:40 UTC, Rares Aioanei
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Rares Aioanei 2025-05-19 09:40:47 UTC
Created attachment 260538 [details]
Updated Makefile and distinfo
Comment 1 Vladimir Druzenko freebsd_committer freebsd_triage 2025-05-19 10:55:56 UTC
This is incorrect in files/setup.py.in:
from distutils.core import setup

setup(
    name = 'archinfo',
    version = "%%DISTVERSION%%",
    packages = ['archinfo'],
    )

Need substitution…
Testing…
Comment 2 Rares Aioanei 2025-05-19 11:26:40 UTC
I'm not sure what you mean. Can you explain further?
Comment 3 Vladimir Druzenko freebsd_committer freebsd_triage 2025-05-19 12:21:46 UTC
(In reply to Rares Aioanei from comment #2)
===>  Building for py311-archinfo-9.2.156
/usr/local/lib/python3.11/site-packages/setuptools/dist.py:544: UserWarning: The version specified ('%%DISTVERSION%%') is an invalid version, this may not work as expected with newer versions of setuptools, pip, and PyPI. Please see PEP 440 for more details.

$ cat files/setup.py.in
from distutils.core import setup

setup(
    name = 'archinfo',
    version = "%%DISTVERSION%%",
    packages = ['archinfo'],
    )

We need to replace %%DISTVERSION%% with value of the DISTVERSION variable (9.2.156).

I found a way, but I don't really like it:
post-extract:
        ${SED} 's|%%DISTVERSION%%|${DISTVERSION}|' ${FILESDIR}/setup.py > ${WRKSRC}/setup.py
Comment 4 Vladimir Druzenko freebsd_committer freebsd_triage 2025-05-20 14:36:21 UTC
What do you think?
Comment 5 Rares Aioanei 2025-05-20 14:48:40 UTC
I think at this point we can continue using %%DISTVERSION%% and I'll look into a way to solve this.
Comment 6 Vladimir Druzenko freebsd_committer freebsd_triage 2025-05-20 16:25:09 UTC
(In reply to Rares Aioanei from comment #5)
I'd rather use my workaround until we come up with a better option.
Comment 7 Vladimir Druzenko freebsd_committer freebsd_triage 2025-05-20 21:38:08 UTC
I see release 9.2.157.
Comment 8 commit-hook freebsd_committer freebsd_triage 2025-05-20 21:48:08 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=d2c867791923d7ac20e4386c44422d1aa8d4d040

commit d2c867791923d7ac20e4386c44422d1aa8d4d040
Author:     Rares Aioanei <schaiba@gmail.com>
AuthorDate: 2025-05-20 21:40:43 +0000
Commit:     Vladimir Druzenko <vvd@FreeBSD.org>
CommitDate: 2025-05-20 21:46:54 +0000

    devel/py-archinfo: Update 9.2.154 => 9.2.157

    Commit log:
    https://github.com/angr/archinfo/compare/v9.2.154...v9.2.157

    Add substitution of DISTVERSION in files/setup.py.

    PR:     286927

 devel/py-archinfo/Makefile | 4 ++--
 devel/py-archinfo/distinfo | 6 +++---
 2 files changed, 5 insertions(+), 5 deletions(-)
Comment 9 Vladimir Druzenko freebsd_committer freebsd_triage 2025-05-20 21:49:00 UTC
Thanks.