Re: Poudriere and Python FLAVORS

From: Paul Mather <paul_at_gromit.dlib.vt.edu>
Date: Fri, 07 Apr 2023 13:07:59 UTC
On Apr 7, 2023, at 7:52 AM, Julien Cigar <julien@perdition.city> wrote:

> Hello, 
> 
> I'm building 2023Q2 through Poudriere with:
> DEFAULT_VERSIONS+= python2=2.7 python3=3.11 python=3.11 pgsql=13 php=8.1
> 
> I'm getting tons of "Ignored: Unknown flavor 'py39', possible flavors:
> py311" (see (1)) for my Python ports (I didn't specified any flavor 
> @pyxx) 
> 
> I don't understand why:
> - Why does Poudriere tries to build @py39 flavor by default when 3.11 is the
>  default?
> - Why py39 flavor is unknown althoug the default Python version for
>  2023Q2 is 3.9?
> 
> Any idea ? :)


I don't know whether this is the issue in your case, but I found when setting the default Python flavour to 3.10 myself I would get the same problems: ports would not build due to an "unknown" flavour.

I discovered that in some cases, "USES= ... python:<version range>" in a port Makefile would make it impossible to build with the default flavour I had set in /etc/make.conf.  A case in point: I wanted to build sysutils/py-salt via Poudriere with a default Python flavour of 3.10.  It failed.  Looking in the Makefile, I saw "USES= cpe python:3.6-3.9".  Most other ports tend to have "... python:3.6+", but this one said it only worked with 3.6 to 3.9.  Hence, trying to build it with 3.10 failed.

I knew that version of py-salt would build under 3.10, so ultimately (after carrying my own local change to the Makefile for a while) submitted a Bugzilla asking for it to be changed to "USES= cpe python:3.6-3.10", which solved the building problem.

So, you may have some similar Python ports or dependent ports that specify they aren't compatible with Python 3.11, and that is causing the warnings and errors.

Cheers,

Paul.