Re: python3dist provides
On 19. 04. 20 18:01, Jerry James wrote: On Sun, Apr 19, 2020 at 10:00 AM Miro Hrončok wrote: On 19. 04. 20 17:49, Miro Hrončok wrote: On 19. 04. 20 17:09, Miro Hrončok wrote: I'll send a PR shortly. Finishing the commit message... https://src.fedoraproject.org/rpms/python-nb2plots/pull-request/2 Thank you! You are welcome and sorry for the trouble with the broken generator -- although it uncovered a problem in nb2plots. As a side note I must say I really dislike how versioneer hardcodes the version information in the file with bundled copy of versioneer itself. There is at least https://github.com/warner/python-versioneer/issues/199 for environment variable support. But latest commit in the project is from 2017. If you have close relationship with nb2plots upstream, please consider suggesting them to switch to setuptools-scm, the de-facto standard to do what versioneer is doing (however I don't know the history, maybe they have chosen versioneer over setuptools-scm for a reason). -- Miro Hrončok -- Phone: +420777974800 IRC: mhroncok ___ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Re: python3dist provides
On Sun, Apr 19, 2020 at 10:00 AM Miro Hrončok wrote: > On 19. 04. 20 17:49, Miro Hrončok wrote: > > On 19. 04. 20 17:09, Miro Hrončok wrote: > >> I'll send a PR shortly. > > Finishing the commit message... > > https://src.fedoraproject.org/rpms/python-nb2plots/pull-request/2 Thank you! -- Jerry James http://www.jamezone.org/ ___ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Re: python3dist provides
On 19. 04. 20 17:49, Miro Hrončok wrote: On 19. 04. 20 17:09, Miro Hrončok wrote: Anyway, now that I know what the immediate problem is, I'll try to work around it. Regards, I'll send a PR shortly. Finishing the commit message... https://src.fedoraproject.org/rpms/python-nb2plots/pull-request/2 -- Miro Hrončok -- Phone: +420777974800 IRC: mhroncok ___ python-devel mailing list -- python-devel@lists.fedoraproject.org To unsubscribe send an email to python-devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/python-devel@lists.fedoraproject.org
Re: python3dist provides
On 19. 04. 20 17:49, Miro Hrončok wrote: On 19. 04. 20 17:09, Miro Hrončok wrote: Anyway, now that I know what the immediate problem is, I'll try to work around it. Regards, I'll send a PR shortly. Finishing the commit message... https://src.fedoraproject.org/rpms/python-nb2plots/pull-request/2 -- Miro Hrončok -- Phone: +420777974800 IRC: mhroncok ___ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Re: python3dist provides
On 19. 04. 20 17:09, Miro Hrončok wrote: Anyway, now that I know what the immediate problem is, I'll try to work around it. Regards, In this particular case the version is trying to be read from git, I recommend using %autosetup -S git and creating a %{version} tag in %prep. I'll send a PR shortly. OK. I've tired the usual: %prep ... git commit -q -a -m "rpmbuild %prep" --author "%{__scm_author}" git tag -a -m '%{version} from rpmbuild' %{version} But it is not that simple. The "versioneer" thing used here tries to read and parse (or execute?) the nb2plots/_version.py file. The file has gitattributes variables in it and git(hub) substitutes those with real values when the git archive tarball is created. Hence any git-like voodoo in prep doesn't really change that :( I am afraid that sedding/patching the file is the only sane way forward. Replacing git_refnames = " (HEAD -> master)" with git_refnames = " (tag: 0.6)" gets the job done. Finishing the commit message... -- Miro Hrončok -- Phone: +420777974800 IRC: mhroncok ___ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Re: python3dist provides
On 19. 04. 20 17:09, Miro Hrončok wrote: Anyway, now that I know what the immediate problem is, I'll try to work around it. Regards, In this particular case the version is trying to be read from git, I recommend using %autosetup -S git and creating a %{version} tag in %prep. I'll send a PR shortly. OK. I've tired the usual: %prep ... git commit -q -a -m "rpmbuild %prep" --author "%{__scm_author}" git tag -a -m '%{version} from rpmbuild' %{version} But it is not that simple. The "versioneer" thing used here tries to read and parse (or execute?) the nb2plots/_version.py file. The file has gitattributes variables in it and git(hub) substitutes those with real values when the git archive tarball is created. Hence any git-like voodoo in prep doesn't really change that :( I am afraid that sedding/patching the file is the only sane way forward. Replacing git_refnames = " (HEAD -> master)" with git_refnames = " (tag: 0.6)" gets the job done. Finishing the commit message... -- Miro Hrončok -- Phone: +420777974800 IRC: mhroncok ___ python-devel mailing list -- python-devel@lists.fedoraproject.org To unsubscribe send an email to python-devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/python-devel@lists.fedoraproject.org
Re: python3dist provides
On 19. 04. 20 16:39, Jerry James wrote: On Sun, Apr 19, 2020 at 2:11 AM Miro Hrončok wrote: Correction, this is valid: https://www.python.org/dev/peps/pep-0440/#local-version-identifiers But in this package case, we don't want version 0, so valid, but wrong. Followup on the generator problem: https://github.com/rpm-software-management/rpm/issues/1183 - the traceback should say: Cannot process Python package version: 0+unknown - the build should abort on errors - the version is actually valid Thanks for the detective work, Miro. I wish this upstream would just release a new version. Anyway, now that I know what the immediate problem is, I'll try to work around it. Regards, In this particular case the version is trying to be read from git, I recommend using %autosetup -S git and creating a %{version} tag in %prep. I'll send a PR shortly. -- Miro Hrončok -- Phone: +420777974800 IRC: mhroncok ___ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Re: python3dist provides
On 19. 04. 20 16:39, Jerry James wrote: On Sun, Apr 19, 2020 at 2:11 AM Miro Hrončok wrote: Correction, this is valid: https://www.python.org/dev/peps/pep-0440/#local-version-identifiers But in this package case, we don't want version 0, so valid, but wrong. Followup on the generator problem: https://github.com/rpm-software-management/rpm/issues/1183 - the traceback should say: Cannot process Python package version: 0+unknown - the build should abort on errors - the version is actually valid Thanks for the detective work, Miro. I wish this upstream would just release a new version. Anyway, now that I know what the immediate problem is, I'll try to work around it. Regards, In this particular case the version is trying to be read from git, I recommend using %autosetup -S git and creating a %{version} tag in %prep. I'll send a PR shortly. -- Miro Hrončok -- Phone: +420777974800 IRC: mhroncok ___ python-devel mailing list -- python-devel@lists.fedoraproject.org To unsubscribe send an email to python-devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/python-devel@lists.fedoraproject.org
Re: python3dist provides
On Sun, Apr 19, 2020 at 2:11 AM Miro Hrončok wrote: > Correction, this is valid: > > https://www.python.org/dev/peps/pep-0440/#local-version-identifiers > > But in this package case, we don't want version 0, so valid, but wrong. > > > Followup on the generator problem: > > https://github.com/rpm-software-management/rpm/issues/1183 > > - the traceback should say: Cannot process Python package version: 0+unknown > - the build should abort on errors > - the version is actually valid Thanks for the detective work, Miro. I wish this upstream would just release a new version. Anyway, now that I know what the immediate problem is, I'll try to work around it. Regards, -- Jerry James http://www.jamezone.org/ ___ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Re: python3dist provides
On 19. 04. 20 10:05, Miro Hrončok wrote: On 19. 04. 20 9:51, Miro Hrončok wrote: On 19. 04. 20 2:16, Jerry James wrote: What generates the python3dist(module) provides? I ask because I did a build of python-nb2plots today for which those provides were not generated: https://koji.fedoraproject.org/koji/buildinfo?buildID=1495361 even though they were for the previous build: https://koji.fedoraproject.org/koji/buildinfo?buildID=1449952 although with questionable values: python3.8dist(nb2plots) = 0+unknown python3dist(nb2plots) = 0+unknown This: https://src.fedoraproject.org/rpms/python-rpm-generators/blob/master/f/pythondistdeps.py https://src.fedoraproject.org/rpms/python-rpm-generators/blob/master/f/pythondist.attr Let me try to debug it. My first rough idea is: The version in upstream metadata is not valid. Downstream (dep generator): ...snip... Upstream (invalid version): Correction, this is valid: https://www.python.org/dev/peps/pep-0440/#local-version-identifiers But in this package case, we don't want version 0, so valid, but wrong. Followup on the generator problem: https://github.com/rpm-software-management/rpm/issues/1183 - the traceback should say: Cannot process Python package version: 0+unknown - the build should abort on errors - the version is actually valid -- Miro Hrončok -- Phone: +420777974800 IRC: mhroncok ___ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Re: python3dist provides
On 19. 04. 20 10:05, Miro Hrončok wrote: On 19. 04. 20 9:51, Miro Hrončok wrote: On 19. 04. 20 2:16, Jerry James wrote: What generates the python3dist(module) provides? I ask because I did a build of python-nb2plots today for which those provides were not generated: https://koji.fedoraproject.org/koji/buildinfo?buildID=1495361 even though they were for the previous build: https://koji.fedoraproject.org/koji/buildinfo?buildID=1449952 although with questionable values: python3.8dist(nb2plots) = 0+unknown python3dist(nb2plots) = 0+unknown This: https://src.fedoraproject.org/rpms/python-rpm-generators/blob/master/f/pythondistdeps.py https://src.fedoraproject.org/rpms/python-rpm-generators/blob/master/f/pythondist.attr Let me try to debug it. My first rough idea is: The version in upstream metadata is not valid. Downstream (dep generator): ...snip... Upstream (invalid version): Correction, this is valid: https://www.python.org/dev/peps/pep-0440/#local-version-identifiers But in this package case, we don't want version 0, so valid, but wrong. Followup on the generator problem: https://github.com/rpm-software-management/rpm/issues/1183 - the traceback should say: Cannot process Python package version: 0+unknown - the build should abort on errors - the version is actually valid -- Miro Hrončok -- Phone: +420777974800 IRC: mhroncok ___ python-devel mailing list -- python-devel@lists.fedoraproject.org To unsubscribe send an email to python-devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/python-devel@lists.fedoraproject.org
Re: python3dist provides
On 19. 04. 20 9:51, Miro Hrončok wrote: On 19. 04. 20 2:16, Jerry James wrote: What generates the python3dist(module) provides? I ask because I did a build of python-nb2plots today for which those provides were not generated: https://koji.fedoraproject.org/koji/buildinfo?buildID=1495361 even though they were for the previous build: https://koji.fedoraproject.org/koji/buildinfo?buildID=1449952 although with questionable values: python3.8dist(nb2plots) = 0+unknown python3dist(nb2plots) = 0+unknown This: https://src.fedoraproject.org/rpms/python-rpm-generators/blob/master/f/pythondistdeps.py https://src.fedoraproject.org/rpms/python-rpm-generators/blob/master/f/pythondist.attr Let me try to debug it. My first rough idea is: The version in upstream metadata is not valid. Downstream (dep generator): Before the latest update, it generated something, now it fails. The behavior with invalid versions is not well defined. The log says: Traceback (most recent call last): File "/usr/lib/rpm/pythondistdeps.py", line 379, in spec_list.append(convert(name, spec[0], spec[1])) File "/usr/lib/rpm/pythondistdeps.py", line 125, in convert return OPERATORS[operator](name, operator, version_id) File "/usr/lib/rpm/pythondistdeps.py", line 79, in convert_equal return '{} = {}'.format(name, version) File "/usr/lib/rpm/pythondistdeps.py", line 47, in __str__ while self.version[-1] == 0: IndexError: list index out of range I wonder if RPMbuild should fail in that case :/ Upstream (invalid version): The versioneer.py file in the project root seem to not handle this well with git snapshots. From /usr/lib/python3.8/site-packages/nb2plots-0+unknown-py3.8.egg-info/PKG-INFO Version: 0+unknown -- Miro Hrončok -- Phone: +420777974800 IRC: mhroncok ___ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Re: python3dist provides
On 19. 04. 20 9:51, Miro Hrončok wrote: On 19. 04. 20 2:16, Jerry James wrote: What generates the python3dist(module) provides? I ask because I did a build of python-nb2plots today for which those provides were not generated: https://koji.fedoraproject.org/koji/buildinfo?buildID=1495361 even though they were for the previous build: https://koji.fedoraproject.org/koji/buildinfo?buildID=1449952 although with questionable values: python3.8dist(nb2plots) = 0+unknown python3dist(nb2plots) = 0+unknown This: https://src.fedoraproject.org/rpms/python-rpm-generators/blob/master/f/pythondistdeps.py https://src.fedoraproject.org/rpms/python-rpm-generators/blob/master/f/pythondist.attr Let me try to debug it. My first rough idea is: The version in upstream metadata is not valid. Downstream (dep generator): Before the latest update, it generated something, now it fails. The behavior with invalid versions is not well defined. The log says: Traceback (most recent call last): File "/usr/lib/rpm/pythondistdeps.py", line 379, in spec_list.append(convert(name, spec[0], spec[1])) File "/usr/lib/rpm/pythondistdeps.py", line 125, in convert return OPERATORS[operator](name, operator, version_id) File "/usr/lib/rpm/pythondistdeps.py", line 79, in convert_equal return '{} = {}'.format(name, version) File "/usr/lib/rpm/pythondistdeps.py", line 47, in __str__ while self.version[-1] == 0: IndexError: list index out of range I wonder if RPMbuild should fail in that case :/ Upstream (invalid version): The versioneer.py file in the project root seem to not handle this well with git snapshots. From /usr/lib/python3.8/site-packages/nb2plots-0+unknown-py3.8.egg-info/PKG-INFO Version: 0+unknown -- Miro Hrončok -- Phone: +420777974800 IRC: mhroncok ___ python-devel mailing list -- python-devel@lists.fedoraproject.org To unsubscribe send an email to python-devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/python-devel@lists.fedoraproject.org
Re: python3dist provides
On 19. 04. 20 2:16, Jerry James wrote: What generates the python3dist(module) provides? I ask because I did a build of python-nb2plots today for which those provides were not generated: https://koji.fedoraproject.org/koji/buildinfo?buildID=1495361 even though they were for the previous build: https://koji.fedoraproject.org/koji/buildinfo?buildID=1449952 although with questionable values: python3.8dist(nb2plots) = 0+unknown python3dist(nb2plots) = 0+unknown This: https://src.fedoraproject.org/rpms/python-rpm-generators/blob/master/f/pythondistdeps.py https://src.fedoraproject.org/rpms/python-rpm-generators/blob/master/f/pythondist.attr Let me try to debug it. -- Miro Hrončok -- Phone: +420777974800 IRC: mhroncok ___ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org