Bug 2142632 - Please provide opencv-python in python3-opencv
Summary: Please provide opencv-python in python3-opencv
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: opencv
Version: 38
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Sergio Basto
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-11-14 17:11 UTC by Jaroslav Škarvada
Modified: 2023-05-24 01:16 UTC (History)
11 users (show)

Fixed In Version: opencv-4.7.0-8.fc38
Clone Of:
Environment:
Last Closed: 2023-05-24 01:16:33 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Jaroslav Škarvada 2022-11-14 17:11:08 UTC
Description of problem:
It seems some packages requires it as opencv-python (e.g. https://github.com/vlachoudis/bCNC/issues/1761). I think it would be good to also explicitly provide this variant.

Version-Release number of selected component (if applicable):
python3-opencv-4.6.0-8.fc38

How reproducible:
Always

Steps to Reproduce:
1. Check provides
2.
3.

Actual results:
Provides:
python-opencv = 4.6.0-8.fc38
python3-opencv = 4.6.0-8.fc38
python3-opencv(x86-64) = 4.6.0-8.fc38
python3.11-opencv = 4.6.0-8.fc38

Expected results:
I think it would be also good to have:
opencv-python = 4.6.0-8.fc38

Or something distro independent.

Additional info:

Comment 1 Jaroslav Škarvada 2022-11-14 17:18:37 UTC
Moreover even when patched the upstream package I got the following dnf error:
 - nothing provides python3.10dist(python3-opencv)

I.e. it should provide python3.10dist() variant.

Comment 2 Jaroslav Škarvada 2022-11-14 17:22:11 UTC
(In reply to Jaroslav Škarvada from comment #1)
> Moreover even when patched the upstream package I got the following dnf
> error:
>  - nothing provides python3.10dist(python3-opencv)
> 
> I.e. it should provide python3.10dist() variant.

This was on f35, on f38 it will be python3.11dist()... This dep was autogenerated by rpm-build from the setup.py where I had:

install_requires=[
  "python3-opencv"],

Comment 3 Sergio Basto 2022-11-27 22:46:16 UTC
(In reply to Jaroslav Škarvada from comment #2)
> (In reply to Jaroslav Škarvada from comment #1)
> > Moreover even when patched the upstream package I got the following dnf
> > error:
> >  - nothing provides python3.10dist(python3-opencv)
> > 
> > I.e. it should provide python3.10dist() variant.
> 
> This was on f35, on f38 it will be python3.11dist()... This dep was
> autogenerated by rpm-build from the setup.py where I had:
> 
> install_requires=[
>   "python3-opencv"],

I added install_requires=["python3-opencv"], to modules/python/package/setup.py a test a build [1] but nothing change ... 

I think we need run something like python-wheel , but I hadn't time to see it yet 

[1] 
https://koji.fedoraproject.org/koji/taskinfo?taskID=94586720

Comment 4 Ben Cotton 2023-02-07 14:59:03 UTC
This bug appears to have been reported against 'rawhide' during the Fedora Linux 38 development cycle.
Changing version to 38.

Comment 5 Nicolas Chauvet (kwizart) 2023-05-05 09:51:43 UTC
I think this bug is fixed in f38, feel free to re-open if you think it's not the case
(Specially as there is this %{?%py_provides:%py_provides python3-%{name}} in the python3-opencv package)

rpm -qp --provides python3-opencv-4.7.0-2.fc38.x86_64.rpm 
python-opencv = 4.7.0-2.fc38
python3-opencv = 4.7.0-2.fc38
python3-opencv(x86-64) = 4.7.0-2.fc38
python3.11-opencv = 4.7.0-2.fc3

Comment 6 Sergio Basto 2023-05-12 23:12:48 UTC
(In reply to Nicolas Chauvet (kwizart) from comment #5)
> I think this bug is fixed in f38, feel free to re-open if you think it's not
> the case
> (Specially as there is this %{?%py_provides:%py_provides python3-%{name}} in
> the python3-opencv package)
> 
> rpm -qp --provides python3-opencv-4.7.0-2.fc38.x86_64.rpm 
> python-opencv = 4.7.0-2.fc38
> python3-opencv = 4.7.0-2.fc38
> python3-opencv(x86-64) = 4.7.0-2.fc38
> python3.11-opencv = 4.7.0-2.fc3

%{?python_provide:%python_provide python3-%{srcname}} and now %{?%py_provides:%py_provides python3-%{name}} exist since 2016 , 

the problem is the python build (I found this page https://github.com/opencv/opencv/wiki/G-API-Python-Bindings ) don't build and install the python egg or .egg-info, so package doesn't provides the autogenerated python3.11dist() ,  so this bug still not solved

Comment 7 Fedora Update System 2023-05-15 01:42:59 UTC
FEDORA-2023-a225a512ce has been submitted as an update to Fedora 38. https://bodhi.fedoraproject.org/updates/FEDORA-2023-a225a512ce

Comment 8 Sergio Basto 2023-05-15 10:06:05 UTC
in %install I added :
	
cd %{__cmake_builddir}/python_loader/
%py3_install -- --install-lib %{python3_sitearch}

and in %files -n python3-opencv I added 
%{python3_sitearch}/opencv-*.egg-info

let me know if it is enough ...

Comment 9 Fedora Update System 2023-05-16 08:22:40 UTC
FEDORA-2023-a225a512ce has been pushed to the Fedora 38 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2023-a225a512ce`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2023-a225a512ce

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 10 Fedora Update System 2023-05-24 01:16:33 UTC
FEDORA-2023-a225a512ce has been pushed to the Fedora 38 stable repository.
If problem still persists, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.