Bug report #9063

QGIS Plugin Builder crash since the second time it start

Added by alexis acosta almost 8 years ago. Updated almost 8 years ago.

Category:Python plugins
Affected QGIS version:2.0.1 Regression?:No
Operating System:Debian GNU/Linux Easy fix?:No
Pull Request or Patch supplied:Yes Resolution:up/downstream
Crashes QGIS or corrupts data:No Copied to github as #:17710


This is the error:

Couldn't load plugin onetime due an error when calling its classFactory() method

Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/qgis/utils.py", line 204, in startPlugin
plugins[packageName] = package.classFactory(iface)
File "/home/devgis2/.qgis2/python/plugins/onetime/__init__.py", line 26, in classFactory
from onetime import onetime
File "/usr/lib/python2.7/dist-packages/qgis/utils.py", line 453, in _import
mod = _builtin_import(name, globals, locals, fromlist, level)
File "/home/devgis2/.qgis2/python/plugins/onetime/onetime.py", line 27, in
import resources_rc
File "/usr/lib/python2.7/dist-packages/qgis/utils.py", line 453, in _import
mod = _builtin_import(name, globals, locals, fromlist, level)
ImportError: No module named resources_rc

Python version:
2.7.3 (default, Jan 2 2013, 14:09:21)
[GCC 4.7.2]

QGIS version:
2.0.1-Dufour Dufour, exported

Python path: ['/usr/share/qgis/python', '/home/devgis2/.qgis2/python', '/home/devgis2/.qgis2/python/plugins', '/usr/share/qgis/python/plugins', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-linux2', '/usr/lib/python2.7/lib-tk', '/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', '/usr/local/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages/gtk-2.0', '/usr/lib/pymodules/python2.7']

Then looked the template with the 'import resources_rc' from (ImportError: No module named resources_rc) found /templateclass/TemplateClass.tmpl, and commented that. Please someone can verify.



TemplateClass.tmpl (3.13 KB) alexis acosta, 2013-11-14 05:44 AM


#1 Updated by Richard Duivenvoorde almost 8 years ago

  • Resolution changed from fixed/implemented to up/downstream
  • Status changed from Open to Closed

this looks like it is not crashing the QGIS Plugin Builder

but it is crashing a plugin (onetime) that is created with it.

I tried it myself here, and if I (as per instructions) copy it to .qgis/python/plugins and run there I have problems like you mention above.

BUT if I copy the directory (generated by the builder) to another directory and run 'make deploy' the plugin runs fine.

So I would not consider this a QGIS issue, but of the plugin builder. See;


Plz create an issue here:


for it.

Also available in: Atom PDF