Feedback from installing wxPython 2407

wxPython 2407 is working great! Here's some slight improvs that could
be made that I took note of during my last install:

* The installation notes (README.1st.txt) say:

···

-------------------------------------------------------------------------------------
2. Make a build directory and configure wxGTK.

        cd wxPythonGTK-2.3.3 # or whatever the top-level dir is
-------------------------------------------------------------------------------------
That should be s/wxPythonGTK/wxPythonSrc

* They also say:
-------------------------------------------------------------------------------------
3. Build and install wxGTK. (You may need to be root for the last
   step, depending on where your WXPREF is.)

        make
        cd ../build
-------------------------------------------------------------------------------------

But in step 2 I already did a "cd build". I believe the "cd ../build"
should be removed.

* It would be a good idea at the end of the installation notes to remind
the person to get matching docs and demo from
http://wxpython.org/download.php#documentation

* There are a lot of gcc warnings at compile time:
contrib/ogl/contrib/src/ogl/lines.cpp:603: warning: `double
startPositionX' might be used uninitialized in this function

gcc often guesses right in these cases, and it doesn't seem expensive to
initialize such variables to 0. Can we do so?

* The version numbers in wxPython.wx either stop short or have the wrong
last digit:

from wxPython import wx
[s for s in dir(wx) if s.lower().find('versi')!=-1]

['__version__', 'wxGetOsVersion', 'wxMAJOR_VERSION', 'wxMINOR_VERSION',
'wxVERSION', 'wxVERSION_NUMBER', 'wxVERSION_STRING']

wx.wxVERSION

(2, 4, 0)

wx.wxVERSION_NUMBER

2400

wx.wxVERSION_STRING

'wxWindows 2.4.0'

Particularly wx.wxVERSION_NUMBER seems wrong since it specifies the
fourth digit, but as '0' instead of '7'.

These items aren't huge, but they would make wxPython a little smoother
and should be easy to fix. Robin, if you want formal patches or need
anything, let me know.

--
Chuck
http://ChuckEsterbrook.com

Chuck Esterbrook wrote:

* There are a lot of gcc warnings at compile time:
contrib/ogl/contrib/src/ogl/lines.cpp:603: warning: `double
startPositionX' might be used uninitialized in this function

gcc often guesses right in these cases, and it doesn't seem expensive to
initialize such variables to 0. Can we do so?

I've noticed that I get a loltof warnings about unitialized pointers as
well. I'd love to initialize these to null, so that the reall errors are
harder to find.

Robin, do you have a reason for not doing so, and if not, would you take
a patch that fixes a lot of those?

-Chris

···

--
Christopher Barker, Ph.D.
Oceanographer
                                        
NOAA/OR&R/HAZMAT (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception

Chris.Barker@noaa.gov

Chuck Esterbrook wrote:

wxPython 2407 is working great! Here's some slight improvs that could be made that I took note of during my last install:

* The installation notes (README.1st.txt) say:

Thanks. I've changed these.

* There are a lot of gcc warnings at compile time:
contrib/ogl/contrib/src/ogl/lines.cpp:603: warning: `double startPositionX' might be used uninitialized in this function

gcc often guesses right in these cases, and it doesn't seem expensive to initialize such variables to 0. Can we do so?

Some can, some are not as easy to do (in third party code that we try to touch as little as possible, or in generated code.) I'll do a full rebuild soon and see which ones are easy to squash.

* The version numbers in wxPython.wx either stop short or have the wrong last digit:

from wxPython import wx
[s for s in dir(wx) if s.lower().find('versi')!=-1]

['__version__', 'wxGetOsVersion', 'wxMAJOR_VERSION', 'wxMINOR_VERSION', 'wxVERSION', 'wxVERSION_NUMBER', 'wxVERSION_STRING']

wx.wxVERSION

(2, 4, 0)

wx.wxVERSION_NUMBER

2400

wx.wxVERSION_STRING

'wxWindows 2.4.0'

Particularly wx.wxVERSION_NUMBER seems wrong since it specifies the fourth digit, but as '0' instead of '7'.

Of these only __version__ is set by wxPython. The rest are defined in C++ and since the core wx team only does w.x.y releases that is all that is defined. wxVERSION_NUMBER is defined like this so that there can be more than 10 release versions:

#define wxVERSION_NUMBER (wxMAJOR_VERSION * 1000) + (wxMINOR_VERSION * 100) + wxRELEASE_NUMBER

That said, it's easy for me to make changes or additions here. I'll give it some thought.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!