Hi everyone,

I've currently upgraded matplolib version of my software (on Windows 10, 
python 2.7) from 1.4 to 2.1.2 and now when I try to freeze it via 
PyInstaller (3.3.1) I get the following error:

  File "MyProg.pyw", line 19, in <module>
  File 
"C:\Users\user1\Desktop\Trunk3.2\pyinstaller\PyInstaller\loader\pyimod03_importers.py",
 
line 396, in load_module
    exec(bytecode, module.__dict__)
  File "gui\stage\MyProgStage.py", line 13, in <module>
  File 
"C:\Users\user1\Desktop\Trunk3.2\pyinstaller\PyInstaller\loader\pyimod03_importers.py",
 
line 396, in load_module
    exec(bytecode, module.__dict__)
  File "gui\stage\MyProgItem.py", line 13, in <module>
  File 
"C:\Users\user1\Desktop\Trunk3.2\pyinstaller\PyInstaller\loader\pyimod03_importers.py",
 
line 396, in load_module
    exec(bytecode, module.__dict__)
  File "components\MyProgCompSource.py", line 1, in <module>
  File 
"C:\Users\user1\Desktop\Trunk3.2\pyinstaller\PyInstaller\loader\pyimod03_importers.py",
 
line 396, in load_module
    exec(bytecode, module.__dict__)
  File "components\MyProgComponentBase.py", line 26, in <module>
  File 
"C:\Users\user1\Desktop\Trunk3.2\pyinstaller\PyInstaller\loader\pyimod03_importers.py",
 
line 396, in load_module
    exec(bytecode, module.__dict__)
  File "components\common\code\MyProgCodePanel.py", line 9, in <module>
  File 
"C:\Users\user1\Desktop\Trunk3.2\pyinstaller\PyInstaller\loader\pyimod03_importers.py",
 
line 396, in load_module
    exec(bytecode, module.__dict__)
  File "components\common\code\codepage.py", line 48, in <module>
  File 
"C:\Users\user1\Desktop\Trunk3.2\pyinstaller\PyInstaller\loader\pyimod03_importers.py",
 
line 396, in load_module
    exec(bytecode, module.__dict__)
  File "components\common\code\MyProgCodeTable.py", line 7, in <module>
  File 
"C:\Users\user1\Desktop\Trunk3.2\pyinstaller\PyInstaller\loader\pyimod03_importers.py",
 
line 396, in load_module
    exec(bytecode, module.__dict__)
  File "components\common\MyProgDelegate.py", line 10, in <module>
  File 
"C:\Users\user1\Desktop\Trunk3.2\pyinstaller\PyInstaller\loader\pyimod03_importers.py",
 
line 396, in load_module
    exec(bytecode, module.__dict__)
  File "designer\widgets\plottingmanager\PlotUtilities.py", line 1, in 
<module>
  File 
"C:\Users\user1\Desktop\Trunk3.2\pyinstaller\PyInstaller\loader\pyimod03_importers.py",
 
line 396, in load_module
    exec(bytecode, module.__dict__)
  File "site-packages\matplotlib\__init__.py", line 127, in <module>
ImportError: cannot import name cbook

I've also tried to include it in my hidden_import list:

# -*- mode: python -*-
block_cipher = None

a = Analysis(['../MyProg.pyw'],
             pathex=[HOMEPATH],
             binaries=None,
             datas=None,
             hiddenimports=['pymysql', 'pg8000', 'matplotlib.cbook'],
             hookspath=[],
             runtime_hooks=[],
             excludes=[],
             win_no_prefer_redirects=False,
             win_private_assemblies=False,
             cipher=block_cipher)

Still I get the same error... any advice?
Just for the record here is the line that seems to bother PyInstaller:


# cbook must import matplotlib only within function
# definitions, so it is safe to import from it here.
from . import cbook
from matplotlib.cbook import (
    _backports, mplDeprecation, dedent, get_label, sanitize_sequence)

Thanks in advance!


-- 
You received this message because you are subscribed to the Google Groups 
"PyInstaller" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to pyinstaller+unsubscr...@googlegroups.com.
To post to this group, send email to pyinstaller@googlegroups.com.
Visit this group at https://groups.google.com/group/pyinstaller.
For more options, visit https://groups.google.com/d/optout.

Reply via email to