Bug 2314083

Summary: error: lua script failed: [string "forgeversion"]:14: error expanding macro
Product: [Fedora] Fedora EPEL Reporter: Jens Petersen <petersen>
Component: forge-srpm-macrosAssignee: Maxwell G <maxwell>
Status: CLOSED CANTFIX QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: epel10CC: maxwell
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2024-10-01 11:45:50 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 Jens Petersen 2024-09-22 11:07:43 UTC
Description of problem:
It would be useful to have forge-srpm-macros in epel10

Could you please request a branch and build it there, when you find time, thanks?

Comment 1 Maxwell G 2024-09-24 12:28:57 UTC
$ fedrq pkgs -b c10s forge-srpm-macros -S -F plainwithrepo
forge-srpm-macros-0.2.0-4.el10.noarch fedrq-centos-stream-appstream

Comment 2 Jens Petersen 2024-09-27 06:37:24 UTC
Right, thank you!

I misinterpreted this epel10 failure in copr:

https://copr.fedorainfracloud.org/coprs/petersen/ramalama/build/8053865/
https://download.copr.fedorainfracloud.org/results/petersen/ramalama/epel-10-x86_64/08053865-python-ramalama/build.log.gz

```
error: 'Version: %forgeversion' must be invoked before setting Release.
  2<      (%error)
error: lua script failed: [string "forgeversion"]:14: error expanding macro
  1<    (%lua)
  0<  (%forgeversion)
Version: 
Building target platforms: x86_64
Building for target x86_64
Child return code was: 1
```

Any idea what might cause this?

Comment 3 Jens Petersen 2024-09-27 06:40:21 UTC
The spec file looks like: https://download.copr.fedorainfracloud.org/results/petersen/ramalama/epel-10-x86_64/08053865-python-ramalama/python-ramalama.spec

Quite possible I doing something stupid or abusing the macros?

Comment 4 Maxwell G 2024-09-27 21:01:42 UTC
Nope, it looks like the issue is that RHEL is shipping an older, buggy version of forge-srpm-macros. I filed https://issues.redhat.com/browse/RHEL-60802. I don't know who is maintaining the package in EL 10, but they are welcome to contact me (the current maintainer of the forge-srpm-macros project) with any questions.

Comment 5 Jens Petersen 2024-10-01 11:45:50 UTC
Thank you