curl-and-python

Re: pycurl.erroc (2, '')

From: Kjetil Jacobsen <kjetilja_at_gmail.com>
Date: Sun, 22 Apr 2007 19:23:24 +0200

hi,

the problem is due to the combined use of python 2.5 and a 64bit
platform. i need to update pycurl to use the Py_ssize_t typedef
instead of ints for calls to the python c-api.

regards,
    - kjetil

On 4/20/07, Aaron Hill <visine19_at_hotmail.com> wrote:
>
> Hi kjetil,
>
> Still having the same issue, here is the output during the build of
> 7.16.2.p1
>
> # python setup.py build
> Using curl-config (libcurl 7.16.2)
> running build
> running build_py
> creating build
> creating build/lib.freebsd-6.2-RELEASE-amd64-2.5
> creating build/lib.freebsd-6.2-RELEASE-amd64-2.5/curl
> copying python/curl/__init__.py ->
> build/lib.freebsd-6.2-RELEASE-amd64-2.5/curl
> running build_ext
> building 'pycurl' extension
> creating build/temp.freebsd-6.2-RELEASE-amd64-2.5
> creating build/temp.freebsd-6.2-RELEASE-amd64-2.5/src
> cc -fno-strict-aliasing -DNDEBUG -O2 -fno-strict-aliasing -pipe
> -D__wchar_t=wchar_t -DTHREAD_STACK_SIZE=0x100000 -fPIC -DHAVE_CURL_OPENSSL=1
> -DHAVE_CURL_SSL=1 -I/usr/local/include -I/usr/local/include/python2.5 -c
> src/pycurl.c -o build/temp.freebsd-6.2-RELEASE-amd64-2.5/src/pycurl.o
> src/pycurl.c: In function `read_callback':
> src/pycurl.c:1162: warning: passing arg 3 of `PyString_AsStringAndSize' from
> incompatible pointer type
> src/pycurl.c: In function `do_curl_setopt':
> src/pycurl.c:1527: warning: passing arg 3 of `PyString_AsStringAndSize' from
> incompatible pointer type
> src/pycurl.c:1723: warning: passing arg 3 of `PyString_AsStringAndSize' from
> incompatible pointer type
> src/pycurl.c:1730: warning: passing arg 3 of `PyString_AsStringAndSize' from
> incompatible pointer type
> src/pycurl.c:1801: warning: passing arg 3 of `PyString_AsStringAndSize' from
> incompatible pointer type
> src/pycurl.c:1808: warning: cast to pointer from integer of different size
> cc -shared -pthread build/temp.freebsd-6.2-RELEASE-amd64-2.5/src/pycurl.o
> -L/usr/local/lib -lcurl -lssl -lcrypto -lz -o
> build/lib.freebsd-6.2-RELEASE-amd64-2.5/pycurl.so
>
>
>
>
>
> ________________________________
>
> > Date: Fri, 20 Apr 2007 19:35:41 +0200
> > From: kjetilja_at_gmail.com
> > To: curl-and-python_at_cool.haxx.se
> > Subject: Re: pycurl.erroc (2, '')
>
> >
> > hi,
> >
> > perhaps this is related to bogus casting of 64bit ints. try the
> > following version of pycurl and see if helps:
> >
> >
> http://pycurl.sourceforge.net/download/pycurl-7.16.2.p1.tar.gz
> >
> > regards,
> > - kjetil
> >
> > On 4/20/07, Aaron Hill <visine19_at_hotmail.com> wrote:
> > >
> > > Hi,
> > >
> > > I'm running into a strange issue with pycurl. I'm currently running
> > > FreeBSD 6.2 amd64, pycurl 7.16.2 and curl 7.16.2, python2.5.
> > >
> > > here is the error:
> > >
> > > self.c.setopt(pycurl.POSTFIELDS, args['postData']);
> > > pycurl.error: (2, '')
> > >
> > >
> > > Obviously it doesn't say much. The same code is running on a development
> > > server just fine, the only difference between the two servers is that
> the
> > > development is running the 32bit version of FreeBSD 6.2 and the other
> the
> > > 64bit version (amd64).
> > >
> > > Does anyone know what this error means?
> > >
> > > ________________________________
> > > Get news, entertainment and everything you care about at Live.com. Check
> it
> > > out!
> > > _______________________________________________
> > >
> http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-python
> > >
> > >
> > _______________________________________________
> >
> http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-python
>
>
> ________________________________
> Invite your mail contacts to join your friends list with Windows Live
> Spaces. It's easy! Try it!
> _______________________________________________
> http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-python
>
>
_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-python
Received on 2007-04-22