Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > PyEphem on Win32 -- 2nd try

Reply
Thread Tools

PyEphem on Win32 -- 2nd try

 
 
Guest
Posts: n/a
 
      02-23-2005

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

A second request for help...

Has anyone run the PyEphem ephemeris application under WinXP?
http://rhodesmill.org/brandon/projects/pyephem.html
I have compiled it with Visual Studio 6 and it crashes Python with a
simple

>>> import ephem
>>> ephem.date('1994/7/16')


Identical code works fine under Linux. I suspect that the problem has
to do with a parser built into the c shell for the c code that the
app wraps around. However, I am not good enough at c to spot the
error.

I am running ActivePython 2.3.5 Build 236 on a WinXP SP2 system with
Visual Studio 6 patched to sp6.

I would appreciate either help from a c guru who knows how to wrap
python around c or a pointer to another list where experts might
reside.
- -------------------------------------------
Cheers, David Flory

-----BEGIN PGP SIGNATURE-----
Version: PGP 8.1

iQA/AwUBQhy551e2/rcN3lp8EQIu2gCfRyDmSCtiP4uB2qKMtIvjcOOsNUkAn1FD
rir+BKqfDqZ0P+lKcwfgdQPu
=5+at
-----END PGP SIGNATURE-----

 
Reply With Quote
 
 
 
 
John Roth
Guest
Posts: n/a
 
      02-23-2005
A quick look at the site, and following the link to
the XEphem site reveals that the Windows port
of XEphem uses Cygwin. AFAIK, that's not
compatible with the usual CPython implementation.

Again, AFAIK, you'll either have to use a Python
port compiled under Cygwin, or you'll have to
find a Windows port compiled with VS 6 or
higher.

Someone who knows more about those
issues will have to take it from here.

John Roth


<(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> A second request for help...
>
> Has anyone run the PyEphem ephemeris application under WinXP?
> http://rhodesmill.org/brandon/projects/pyephem.html
> I have compiled it with Visual Studio 6 and it crashes Python with a
> simple
>
>>>> import ephem
>>>> ephem.date('1994/7/16')

>
> Identical code works fine under Linux. I suspect that the problem has
> to do with a parser built into the c shell for the c code that the
> app wraps around. However, I am not good enough at c to spot the
> error.
>
> I am running ActivePython 2.3.5 Build 236 on a WinXP SP2 system with
> Visual Studio 6 patched to sp6.
>
> I would appreciate either help from a c guru who knows how to wrap
> python around c or a pointer to another list where experts might
> reside.
> - -------------------------------------------
> Cheers, David Flory
>
> -----BEGIN PGP SIGNATURE-----
> Version: PGP 8.1
>
> iQA/AwUBQhy551e2/rcN3lp8EQIu2gCfRyDmSCtiP4uB2qKMtIvjcOOsNUkAn1FD
> rir+BKqfDqZ0P+lKcwfgdQPu
> =5+at
> -----END PGP SIGNATURE-----
>


 
Reply With Quote
 
 
 
 
drobinow@gmail.com
Guest
Posts: n/a
 
      02-24-2005

http://www.velocityreviews.com/forums/(E-Mail Removed) wrote:
> Has anyone run the PyEphem ephemeris application under WinXP?
> http://rhodesmill.org/brandon/projects/pyephem.html
> I have compiled it with Visual Studio 6 and it crashes Python with a
> simple
>
> >>> import ephem
> >>> ephem.date('1994/7/16')

>
> Identical code works fine under Linux. I suspect that the problem has
> to do with a parser built into the c shell for the c code that the
> app wraps around. However, I am not good enough at c to spot the
> error.


I had the same problem with Python 2.4. Dates appear to need a
trailing space.

ephem.date('1994/7/16 ')
works for me.

I believe the following code in ephem.c is responsible:
if (conversions == -1 || !conversions ||
(conversions == 1 && s[dchars] != '\0') ||
(conversions == 2 && s[tchars] != '\0')) {
PyErr_SetString(PyExc_ValueError,
"your date string does not seem to have "
"year/month/day followed optionally by "
"hours:minutes:seconds");

This may be a VC versus gcc issue. It would be interesting to see if a
Mingw compile would help here.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
2nd Call for Papers | Extended deadline: April 07 |CENTERIS'2009 - Conference on ENTERprise Information Systems | 2nd Callfor Papers CENTERIS'2009 - Conference on ENTERprise Information Systems Python 0 03-16-2009 01:59 PM
PyEphem on winXP jbattat@cfa.harvard.edu Python 1 09-22-2005 06:39 AM
PyEphem on Win32 David Flory Python 0 02-21-2005 03:09 AM
Try, Try, Try, again... Rick12N4@netscape.net Computer Support 3 01-29-2005 04:02 PM
Mac Authentication - 2nd try - on Aeronet Pharmacy Cisco 1 12-16-2003 11:38 PM



Advertisments