[PATCH] Split out helper code from the Custom partitioning spoke

Vratislav Podzimek vpodzime at redhat.com
Tue Mar 11 14:25:12 UTC 2014


On Tue, 2014-03-11 at 09:57 -0400, Chris Lumens wrote:
> > The Custom partitioning spoke has a lot of helper code that can live in a
> > separate module decreasing the unmaintainable complexity and length of the
> > spoke's module.
> > 
> > Signed-off-by: Vratislav Podzimek <vpodzime at redhat.com>
> > ---
> >  pyanaconda/ui/gui/spokes/custom.glade              |  988 ------------------
> >  pyanaconda/ui/gui/spokes/custom.py                 |  665 +-----------
> >  .../ui/gui/spokes/lib/custom_storage_helpers.glade | 1059 ++++++++++++++++++++
> >  .../ui/gui/spokes/lib/custom_storage_helpers.py    |  658 ++++++++++++
> >  4 files changed, 1745 insertions(+), 1625 deletions(-)
> >  create mode 100644 pyanaconda/ui/gui/spokes/lib/custom_storage_helpers.glade
> >  create mode 100644 pyanaconda/ui/gui/spokes/lib/custom_storage_helpers.py
> 
> My intention with the lib/ directory was to treat is as a directory of
> lots of small files, each one basically handling one thing.  Please make
> sure your new file isn't a catch-all for stuff you don't want in
> custom.py.  I'd also like to see an __all__.
Adding __all__ is definitely a good idea, thanks!

The intention behind the new file was to make the custom.py and
custom.glade files shorter and less complex because even the code that
has to be in them is very long and complex. So it basically is about
"catch-all for stuff we dont *need* in custom.py". Is there any better
place for it? Should the file live directly under
pyanaconda/ui/gui/spokes/ ?

-- 
Vratislav Podzimek

Anaconda Rider | Red Hat, Inc. | Brno - Czech Republic



More information about the anaconda-patches mailing list