Bug report #12011

python error when opening the sql console in DB Manager

Added by Giovanni Manghi almost 10 years ago. Updated almost 10 years ago.

Status:Closed
Priority:Severe/Regression
Assignee:-
Category:DB Manager
Affected QGIS version:master Regression?:No
Operating System:Ubuntu Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:20214

Description

it happens on QGIS master

Traceback (most recent call last):
  File "/usr/share/qgis/python/plugins/db_manager/db_manager.py", line 183, in runSqlWindow
    from dlg_sql_window import DlgSqlWindow
  File "/usr/lib/python2.7/dist-packages/qgis/utils.py", line 479, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "/usr/share/qgis/python/plugins/db_manager/dlg_sql_window.py", line 33, in 
    from .ui.ui_DlgSqlWindow import Ui_DbManagerDlgSqlWindow as Ui_Dialog
  File "/usr/lib/python2.7/dist-packages/qgis/utils.py", line 479, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "/usr/share/qgis/python/plugins/db_manager/ui/ui_DlgSqlWindow.py", line 222, in 
    from qgis.gui import QgsCodeEditorSQL
ImportError: cannot import name QgsCodeEditorSQL

Associated revisions

Revision 2c820bb9
Added by Jürgen Fischer almost 10 years ago

db_manager: use SqlEdit when QgsCodeEditorSQL is unavailable (fixes #12011)

History

#1 Updated by Alexander Bruy almost 10 years ago

Not reproducible with master under Windows and Linux. I suspect this is local issue.

#2 Updated by Giovanni Manghi almost 10 years ago

  • OS version set to 14.04
  • Operating System set to Ubuntu
  • Status changed from Open to Feedback

Hi Alex,
not sure is a local issue. I have a (very) clean installation of master from the nightly build repository. Anyway I'm looking for feedback from other users with the same installation. I confirm on Windows is OK.

#3 Updated by Pedro Venâncio almost 10 years ago

Hi Giovanni and Alexander,

I can confirm this error on Xubuntu 12.04

Traceback (most recent call last):
  File "/usr/share/qgis/python/plugins/db_manager/db_manager.py", line 183, in runSqlWindow
    from dlg_sql_window import DlgSqlWindow
  File "/usr/lib/python2.7/dist-packages/qgis/utils.py", line 479, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "/usr/share/qgis/python/plugins/db_manager/dlg_sql_window.py", line 33, in 
    from .ui.ui_DlgSqlWindow import Ui_DbManagerDlgSqlWindow as Ui_Dialog
  File "/usr/lib/python2.7/dist-packages/qgis/utils.py", line 479, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "/usr/share/qgis/python/plugins/db_manager/ui/ui_DlgSqlWindow.py", line 215, in 
    from qgis.gui import QgsCodeEditorSQL
ImportError: cannot import name QgsCodeEditorSQL

Python version:
2.7.3 (default, Dec 18 2014, 19:15:23) 
[GCC 4.6.3]

QGIS version:
2.7.0-Master Master, exported

and Lubuntu 14.04.

#4 Updated by Giovanni Manghi almost 10 years ago

confirmed also by other users under Linux. Windows is ok.

#5 Updated by andre mano almost 10 years ago

I can confirm this issue in my Mint 17 installation. I get the same error message.

#6 Updated by Jürgen Fischer almost 10 years ago

  • Status changed from Feedback to Closed

Also available in: Atom PDF