Skip to content
Permalink
Browse files

Fix Object Inspector in Python console editor

  • Loading branch information
g-sherman committed Sep 27, 2017
1 parent 43a9bc1 commit 036646fcfe79e22e5ded882a2238e50bb6b67dac
Showing with 7 additions and 6 deletions.
  1. +7 −6 python/console/console_editor.py
@@ -34,6 +34,7 @@
import traceback
import codecs
import re
import importlib


class KeyFilter(QObject):
@@ -520,7 +521,7 @@ def _runSubProcess(self, filename, tmp=False):
if dir not in sys.path:
sys.path.append(dir)
if name in sys.modules:
reload(sys.modules[name]) # NOQA
importlib.reload(sys.modules[name]) # NOQA
try:
# set creationflags for running command without shell window
if sys.platform.startswith('win'):
@@ -1174,7 +1175,7 @@ def listObject(self, tab):
sys.path.append(pathFile)
found = True
try:
reload(pyclbr) # NOQA
importlib.reload(pyclbr) # NOQA
dictObject = {}
readModule = pyclbr.readmodule(module)
readModuleFunction = pyclbr.readmodule_ex(module)
@@ -1236,10 +1237,10 @@ def listObject(self, tab):
iconWarning = QgsApplication.getThemeIcon("console/iconSyntaxErrorConsole.png")
msgItem.setIcon(0, iconWarning)
self.parent.listClassMethod.addTopLevelItem(msgItem)
# s = traceback.format_exc()
# print '## Error: '
# sys.stderr.write(s)
# pass
# s = traceback.format_exc()
# print('## Error: ')
# sys.stderr.write(s)
# pass

def refreshSettingsEditor(self):
countTab = self.count()

0 comments on commit 036646f

Please sign in to comment.
You can’t perform that action at this time.