ejeschke / ginga

The Ginga astronomical FITS file viewer
BSD 3-Clause "New" or "Revised" License
122 stars 77 forks source link

SyntaxError for 0L in gtkw/Widgets.py #220

Closed cdeil closed 9 years ago

cdeil commented 9 years ago

When I install ginga master on Python 3.4 locally I see this error:

Extracting ginga-2.5.20151112024614-py3.4.egg to /Users/deil/Library/Python/3.4/lib/python/site-packages
  File "/Users/deil/Library/Python/3.4/lib/python/site-packages/ginga-2.5.20151112024614-py3.4.egg/ginga/gtkw/Widgets.py", line 1215
    menu.popup(None, None, None, None, 0, 0L)
                                           ^
SyntaxError: invalid syntax

The literal 0L doesn't exist on Python 3, so this should be changed: https://github.com/ejeschke/ginga/blame/0c39d3d933b7bf412e6818cf9e28ec395d98d7f6/ginga/gtkw/Widgets.py#L1215

This error doesn't seem to occur in the Python 3 builds on travis-ci: https://travis-ci.org/ejeschke/ginga/jobs/90653148 Is this part of the code untested?

ejeschke commented 9 years ago

@cdeil, it seems that travis doesn't throw an error installing on python 3.3 and 3.4. When I test ginga with python3 manually I normally don't do it by an install, just run the tests (which aren't very many) and some manual testing. So I guess this has slipped by.

I'll do some testing and update. Tnx for the report!

ejeschke commented 9 years ago

Fixed in commit 794b7df3aeae7d5cd1339e93fd087515342519e6