Bug 1708372

Summary: Error loading networkx after spliting out tests folder
Product: [Fedora] Fedora Reporter: Alfredo Moralejo <amoralej>
Component: python-networkxAssignee: Jerry James <loganjerry>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: urgent Docs Contact:
Priority: unspecified    
Version: rawhideCC: loganjerry
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Unspecified   
Whiteboard:
Fixed In Version: python-networkx-2.3-2.fc30 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-05-26 01:04:06 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 Alfredo Moralejo 2019-05-09 17:38:04 UTC
Description of problem:

After spliting out tests in a different -tests subpackages, it fails to load networkx as it imports networks.tests in module __init__.py

https://github.com/networkx/networkx/blob/master/networkx/__init__.py#L126

ERROR:

[root@5099c49be804 /]# python3
Python 3.7.2 (default, Jan 16 2019, 19:49:22) 
[GCC 8.2.1 20181215 (Red Hat 8.2.1-6)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import networkx
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python3.7/site-packages/networkx/__init__.py", line 126, in <module>
    from networkx.tests.test import run as test
ModuleNotFoundError: No module named 'networkx.tests'
>>> 



Version-Release number of selected component (if applicable):

python-networkx-2.3-1.fc31
python-networkx-2.3-1.fc30

How reproducible:

allways

Steps to Reproduce:
1. install python3-networkx-2.3-1.fc30
2. run python3
3. import networks

Actual results:

Fail to load the module with error:

ModuleNotFoundError: No module named 'networkx.tests'


Expected results:

Should load the module

Additional info:

Comment 1 Jerry James 2019-05-17 02:44:17 UTC
So much for that idea....  I'll merge it back into the main package.  Thanks for the report!

Comment 2 Fedora Update System 2019-05-17 03:29:21 UTC
python-networkx-2.3-2.fc30 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-903615491e

Comment 3 Fedora Update System 2019-05-18 00:53:58 UTC
python-networkx-2.3-2.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-903615491e

Comment 4 Fedora Update System 2019-05-26 01:04:06 UTC
python-networkx-2.3-2.fc30 has been pushed to the Fedora 30 stable repository. If problems still persist, please make note of it in this bug report.