jakesylvestre / r-orange

Automatically exported from code.google.com/p/r-orange
0 stars 0 forks source link

reloadWidgets #189

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
When a few package is installed 

signals.registerRedRSignals()
redRGUI.registerQTWidgets()

are required in the reloadWidgets function

Else the new package wont be usable. 

Rather than commenting these lines before of error need to fix the error. I 
cant recreate the error with signal classes not allowing connections. 

Original issue reported on code.google.com by anup.parikh on 13 Jun 2010 at 5:34

GoogleCodeExporter commented 9 years ago
this kind of importing is not standard for python.  It would be better to use 
the accepted methods of module and package importing in python.  

All directories should have a file named __init__.py  This file can be empty 
(contain no code or text) but are required for python to recognize the 
directory as a module.

The registry can then import the files and append to signals and widgets.  I'll 
test this to see if the transition can be done with no modifications to 
widgets.  Otherwise widgets will need to change their code to specify the exact 
location of the modules.

Original comment by kylecovi...@gmail.com on 14 Jun 2010 at 12:53

GoogleCodeExporter commented 9 years ago
setting the modules automatically may not be the best thing.

module libraries should have in their __init__ instructions for registering the 
widgets in their libraries. 

I'll work on this but regulation at this level allows users to control how 
things are initialized and where signals go.  We can supply a template for how 
to do this where the user simply adds a list of signals or qtwidgets and the 
init can take care of the rest.

Original comment by kylecovi...@gmail.com on 14 Jun 2010 at 1:31

GoogleCodeExporter commented 9 years ago
this seems to be working on my machine though some library isn't loading that 
I'll take care of.

We should move to the __init__.py method to specify where signals and widgets 
live because that is the appropriate python way of doing things.

Original comment by kylecovi...@gmail.com on 14 Jun 2010 at 10:52

GoogleCodeExporter commented 9 years ago
got the error again with sqlitedataframe.  This seems to come and go.  Don't 
know what the common error is.

Original comment by kylecovi...@gmail.com on 15 Jun 2010 at 4:07

GoogleCodeExporter commented 9 years ago
will remove the registry functions for signals and widgets.  These will be 
replaced with modules that should be imported independently (including base).  
I'll convert the widgets over and place the __init__.py statements into the 
code.  package developers will be able to place the signals and qtWidgets into 
any format that they want and will  be able to declare multiple classes per .py 
file.

I'll convert shortly.

Original comment by kylecovi...@gmail.com on 15 Jun 2010 at 4:45

GoogleCodeExporter commented 9 years ago
will all the signals and qtwidget be accessed using redRGUI.xxx and signals.xxx?

How will widgetSessions handle loading and saving?

Original comment by anup.parikh on 15 Jun 2010 at 11:58

GoogleCodeExporter commented 9 years ago
Issue 171 has been merged into this issue.

Original comment by anup.parikh on 15 Jun 2010 at 1:21

GoogleCodeExporter commented 9 years ago
the new system means that no signals will be accessed using signals.XXX.  
Instead we will access modules the correct way which is to call 
libraries.[package].signalClasses.[signal].

The problem with registering doesn't seem to be affecting the redRGUI operation 
so I can leave that the way it is.

I committed changes last night to move to this and will finish them today.

Original comment by kylecovi...@gmail.com on 15 Jun 2010 at 3:01

GoogleCodeExporter commented 9 years ago
compleated the transition to specifying the signal classes as in python.  
Future changes to paths should be modified in the widgets that will be 
affected.  Path structure for base should not be altered.

Widgets may now be reloaded as often as nessisary. No need to register the 
signals.

Original comment by kylecovi...@gmail.com on 15 Jun 2010 at 11:56