[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [gpsd-dev] ✘Python maidenhead fails on XCode
From: |
Gary E. Miller |
Subject: |
Re: [gpsd-dev] ✘Python maidenhead fails on XCode |
Date: |
Tue, 16 Aug 2016 15:05:11 -0700 |
Yo Fred!
On Tue, 16 Aug 2016 14:52:53 -0700 (PDT)
Fred Wright <address@hidden> wrote:
> On Tue, 16 Aug 2016, Gary E. Miller wrote:
>
> > I got a Python failure in 'scons check' on XCode:
> >
> > Testing the Maidenhead Locator conversion...
> > /opt/local/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python
> > ./test_maidenhead.py
> > >/dev/null maidenhead test: from 48.86471 2.37305 (Paris) expected
> > >JN18eu got JJ00aa
> > maidenhead test: from 41.93498 12.43652 (Rome) expected JN61fw got
> > JJ00aa maidenhead test: from 39.9771 -75.1685 (Philadelphia)
> > expected FM29jx got JJ00aa maidenhead test: from -23.4028 -50.9766
> > (Sao Paulo) expected GG46mo got JJ00aa scons: ***
> > [maidenhead-locator-regress] Error 1
> >
> > Not being a Python or maindenhead person, anyone have a clue?
>
> I'm only marginally familiar with the maidenhead stuff, but I believe
> it's something that maps lat/lon to some sort of location
> identifiers. My guess is that some calculations got screwed up (and
> note that all four of the error cases are producing the same
> result). There's probably too much intermediate breakage to make
> "git bisect" useful, but one could compare intermediate results
> between working and non-working cases.
One line in gpsclient.d:
static PyObject *
gpsclient_maidenhead(PyObject *self UNUSED, PyObject *args)
{
- const double lat, lon;
+ const double lat = 0.0, lon = 0.0;
Very weird, Eric helped me narrow it down. Adding an initializer, as
requested by compiler warning, breaks it. And just on OS X.
Hmmm..
RGDS
GARY
---------------------------------------------------------------------------
Gary E. Miller Rellim 109 NW Wilmington Ave., Suite E, Bend, OR 97703
address@hidden Tel:+1 541 382 8588
pgppt4Nxc02jW.pgp
Description: OpenPGP digital signature