#2401 F33 Self-Contained Change: No more automagic Python bytecompilation (phase 3)
Closed: Accepted 3 years ago by ignatenkobrain. Opened 3 years ago by bcotton.

See Changes/No_more_automagic_Python_bytecompilation and Changes/No_more_automagic_Python_bytecompilation_phase_2. Now, %global _python_bytecompile_extra 1 won't be allowed anymore and raises an error with a link to this change.


Generally I am +1, however

Now, %global _python_bytecompile_extra 1 won't be allowed anymore and raises an error with a link to this change

How does this affect EPEL? Does that do anything there? If so, can we make it to not error out but rather print some warning?

How does this affect EPEL?

It doesn't, this change happens on rawhide. I don't understand your question.

We make it error, because we need packagers to switch to %py_byte_compile.

+1 to the change (for clarity: I was involved in the decision to submit it)

It doesn't, this change happens on rawhide. I don't understand your question.

The question was whether setting this variable changes something in EPEL buildroot. People tend to keep same spec files across Fedora and EPEL so this would prevent them from doing so. I just want to be sure that if it breaks that, we will have it documented.

We make it error, because we need packagers to switch to %py_compile.

I understand why and fully support it, just wanted to clarify EPEL situation.

So, for EPEL 6 and 7, the automagic Python bytecompilation of everything with %__python is always done if %__python is present in the buildroot. The %_python_bytecompile_extra value is not used by anything. Spec files that have %global _python_bytecompile_extra 1, spec files that have %global _python_bytecompile_extra 0 and spec files that don't have either all behave the same.

For EPEL 8, %_python_bytecompile_extra default value is 0 (same as in current Fedora). Setting %global _python_bytecompile_extra 1 in spec behaves like in current Fedora.

When we make it error in Fedora, the Fedora spec files that have %global _python_bytecompile_extra 1 will need to be adapted to either drop it (when they don't actually need it) or to use %py_byte_compile explicitly. Such change is EPEL 6/7/8 compatible and can be merged to EPEL 6/7/8.

Does that answer your concerns?

Not Igor but it addresses it for me. +1

When we make it error in Fedora, the Fedora spec files that have %global _python_bytecompile_extra 1 will need to be adapted to either drop it (when they don't actually need it) or to use %py_byte_compile explicitly. Such change is EPEL 6/7/8 compatible and can be merged to EPEL 6/7/8.

Fine with me :) Probably put this into the change page so that people can easily find this too.

+1

APPROVED (+6, 0, -0)

I can no longer manage ticket but this has now been announced.

Metadata Update from @ignatenkobrain:
- Issue close_status updated to: Accepted
- Issue status updated to: Closed (was: Open)

3 years ago

Metadata Update from @bcotton:
- Issue untagged with: F33
- Issue set to the milestone: Fedora 33

3 years ago

Login to comment on this ticket.

Metadata