Bug 50919 - two Python modules in redhat-config-network import each other
Summary: two Python modules in redhat-config-network import each other
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: redhat-config-network
Version: 7.3
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Phil Knirsch
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2001-08-04 20:40 UTC by Panic
Modified: 2015-03-05 01:09 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2001-08-05 19:57:29 UTC
Embargoed:


Attachments (Terms of Use)

Description Panic 2001-08-04 20:40:04 UTC
Description of Problem:

NCProfileList.py and ProfileList.py import each other:

NCProfileList.py line 27:

from ProfileList import *

and ProfileList.py line 1518:

import NCProfileList
from NCProfileList import *

I'm not sure that this is a problem per se, but some things seem to be
crossing over unintentionally, like in editdomain.py on line 88:

    def dehydrate(self):
        profilelist = ProfileList.getProfileList()

getProfileList doesn't exist in ProfileList.py, but rather in NCProfileList.py.
 
How Reproducible:

Always

Steps to Reproduce:
1. examine code.
2. 
3. 

Actual Results:

I'm not sure, but shouldn't the imports be only one-way?  And if a function
is called, shouldn't the call indicate the correct module that the function
resides in?

Expected Results:


Additional Information:

Comment 1 Phil Knirsch 2001-08-06 15:45:46 UTC
OK, fixed in CVS.

Concerning the cross imports: We need them to some degree as otherwise our
namespacing would get horribly messy...

We've spent quite some time to clean this up as much as possible, but that one
obviously slipped through our net of checks.

Thanks,

Read ya, Phil


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