Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AttributeError: module 'sys' has no attribute 'frozen' #920

Closed
hroncok opened this issue Mar 23, 2018 · 4 comments
Closed

AttributeError: module 'sys' has no attribute 'frozen' #920

hroncok opened this issue Mar 23, 2018 · 4 comments
Labels
2.x Non-breaking features and fixes suitable for inclusion in future Printrun 2.x minor releases

Comments

@hroncok
Copy link
Collaborator

hroncok commented Mar 23, 2018

After c41e643

This is what I see when I run pronterface from an updated Fedora package:

Traceback (most recent call last):
  File "/usr/bin/pronterface", line 62, in <module>
    app = PronterApp(False)
  File "/usr/lib64/python3.6/site-packages/printrun/pronterface.py", line 2350, in __init__
    self.mainwindow = PronterWindow(self)
  File "/usr/lib64/python3.6/site-packages/printrun/pronterface.py", line 184, in __init__
    self.SetIcon(wx.Icon(iconfile("pronterface.png"), wx.BITMAP_TYPE_PNG))
  File "/usr/lib64/python3.6/site-packages/printrun/utils.py", line 78, in iconfile
    return pixmapfile(filename)
  File "/usr/lib64/python3.6/site-packages/printrun/utils.py", line 109, in pixmapfile
    '/usr/share/pixmaps'])
  File "/usr/lib64/python3.6/site-packages/printrun/utils.py", line 100, in lookup_file
    if sys.frozen: prefixes+=[getattr(sys, "_MEIPASS", os.path.dirname(os.path.abspath(__file__))),]
AttributeError: module 'sys' has no attribute 'frozen'

Note it doesn't happen when I run pronterface from sources. Will investigate.

@hroncok hroncok added the 2.x Non-breaking features and fixes suitable for inclusion in future Printrun 2.x minor releases label Mar 23, 2018
@kliment
Copy link
Owner

kliment commented Mar 23, 2018

Should be fixed with latest commit, can you test?

@hroncok
Copy link
Collaborator Author

hroncok commented Mar 23, 2018

I had a bit different fix prepared (but basically the same), you are too fast :) Will apply the patch, rebuild the package and let you know.

The problem is when running form source, the code was never executed, because it returned sooner.

@kliment
Copy link
Owner

kliment commented Mar 23, 2018

Yeah, but this should be fairly robust.

@hroncok
Copy link
Collaborator Author

hroncok commented Mar 23, 2018

Confirmed, fixed.

@hroncok hroncok closed this as completed Mar 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.x Non-breaking features and fixes suitable for inclusion in future Printrun 2.x minor releases
Projects
None yet
Development

No branches or pull requests

2 participants