Re: double module loads

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> For python, the two modules seem to be a different module and so it
> loads them twice (and adds them as two separate entries into
> sys.modules, once as 'module', then as 'pyanaconda.module'). The
> module init code that we expect to be executed exactly once is then
> executed twice. I found out about this thing by noticing that all
> the logging output is doubled after certain execution point (due to
> handlers being added twice). Another complication is with updates:
> if a module is first imported from your update directory but later
> from site-packages/pyanaconda, it actually runs a different
> code--->total chaos.

Let's start by moving code that shouldn't be run more than once into
functions and classes to ensure it only runs once.  Now that anaconda's
a module, it should act like a well-behaved module and not totally crap
out just because it was imported twice.

After we do that, let's see where we stand.

- Chris

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux