Bug 1886509
Summary: | %pyproject_buildrequires -e does not work when used repeatedly | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Petr Viktorin (pviktori) <pviktori> |
Component: | pyproject-rpm-macros | Assignee: | Miro Hrončok <mhroncok> |
Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | rawhide | CC: | mhroncok, pviktori, python-sig |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | pyproject-rpm-macros-0-32.fc34 pyproject-rpm-macros-0-32.fc32 pyproject-rpm-macros-0-32.fc31 pyproject-rpm-macros-0-32.fc33 pyproject-rpm-macros-0-37.eln109 | Doc Type: | If docs needed, set a value |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2020-11-11 10:53:14 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Petr Viktorin (pviktori)
2020-10-08 16:03:25 UTC
Currently, you can do: %pyproject_buildrequires -e %{toxenv}-unit%{?with_integration_test,%{toxenv}-integration} Albeit it's not very nice. However, supporting multiple -e might be problematic. It works with -x only because we pass them to the underlying Python script via %{?**}. However with -e, we do set a macro: %{-e:%{expand:%global toxenv %{-e*}}} And I am not entirely sure it is possible to get "all the values used for all -e flags" in RPM. (In reply to Miro Hrončok from comment #1) > And I am not entirely sure it is possible to get "all the values used for > all -e flags" in RPM. We could parse it from %{?**} with a small Python snippet and do: %global toxenv %(%{__python3} pyproject_parse_toxenv.py %{?**}) Or a small Lua macro: %global toxenv %{_pyproject_parse_toxenv %{?**}} Proof of concepts: in Lua: https://src.fedoraproject.org/rpms/pyproject-rpm-macros/pull-request/128 in Python: https://src.fedoraproject.org/rpms/pyproject-rpm-macros/pull-request/129 Both are currently untested but show how this can be done. I think the Python implementation is more robust. FEDORA-2020-6b7fa698ba has been pushed to the Fedora 34 stable repository. If problem still persists, please make note of it in this bug report. FEDORA-2020-e568a8a558 has been submitted as an update to Fedora 32. https://bodhi.fedoraproject.org/updates/FEDORA-2020-e568a8a558 FEDORA-2020-4842c9141f has been submitted as an update to Fedora 31. https://bodhi.fedoraproject.org/updates/FEDORA-2020-4842c9141f FEDORA-2020-ff1e7ce8ed has been submitted as an update to Fedora 33. https://bodhi.fedoraproject.org/updates/FEDORA-2020-ff1e7ce8ed FEDORA-2020-4842c9141f has been pushed to the Fedora 31 testing repository. In short time you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2020-4842c9141f` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-4842c9141f See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates. FEDORA-2020-ff1e7ce8ed has been pushed to the Fedora 33 testing repository. In short time you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2020-ff1e7ce8ed` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-ff1e7ce8ed See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates. FEDORA-2020-e568a8a558 has been pushed to the Fedora 32 testing repository. In short time you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2020-e568a8a558` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-e568a8a558 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates. FEDORA-2020-e568a8a558 has been pushed to the Fedora 32 stable repository. If problem still persists, please make note of it in this bug report. FEDORA-2020-4842c9141f has been pushed to the Fedora 31 stable repository. If problem still persists, please make note of it in this bug report. FEDORA-2020-ff1e7ce8ed has been pushed to the Fedora 33 stable repository. If problem still persists, please make note of it in this bug report. FEDORA-2021-46d1d95820 has been pushed to the Fedora ELN stable repository. If problem still persists, please make note of it in this bug report. |