From: Fabio Z. <fa...@gm...> - 2010-03-04 22:25:28
|
Hi All, Pydev 1.5.5 has been released Details on Pydev: http://pydev.org Details on its development: http://pydev.blogspot.com Release Highlights: ------------------------------- * Predefined completions available for code completion: * Predefined completions may be created for use when sources are not available * Can also be used for providing better completions for compiled modules (e.g.: PyQt, wx, etc.) * Defined in .pypredef files (which are plain Python code) * Provides a way for generating those from a QScintilla .api file (experimental) * See Predefined Completions in manual for more info * Pydev Package Explorer: * Showing the contents of the PYTHONPATH from the interpreter for each project * Shows the folder containing the python interpreter executable (to browse for docs, scripts, etc) * Allows opening files in the interpreter PYTHONPATH (even inside zip files) * Editor options: * Find/replace dialog has option to search in currently opened editors * Move line up/down can move considering Python indentation (not default) * Simple token completions can have a space or a space and colon added when applied. E.g.: print, if, etc (not default) * Refactoring: * Fixed InvalidThreadAccess on refactoring * Fixed problem doing refactoring on external files (no file was found) * Globals Browser (Ctrl+Shift+T): * No longer throwing NullPointerException when the interpreter is no longer available for a previously found token * General: * When creating a new pydev project, the user will be asked before changing to the pydev perspective * Only files under source folders are analyzed (files in the external source folders would be analyzed if they happened to be in the Eclipse workspace) * Interactive console now works properly on non-english systems * Hover working over tokens from compiled modules (e.g.: file, file.readlines) * JYTHONPATH environment variable is set on Jython (previously only the PYTHONPATH was set) * Fixed path translation issues when using remote debugger * Fixed issue finding definition for a method of a locally created token What is PyDev? --------------------------- PyDev is a plugin that enables users to use Eclipse for Python, Jython and IronPython development -- making Eclipse a first class Python IDE -- It comes with many goodies such as code completion, syntax highlighting, syntax analysis, refactor, debug and many others. Cheers, -- Fabio Zadrozny ------------------------------------------------------ Software Developer Aptana http://aptana.com/python Pydev - Python Development Environment for Eclipse http://pydev.org http://pydev.blogspot.com |
From: josu j. <jos...@gm...> - 2010-03-04 23:18:37
|
Hi I have observed that a version of ctypes is in trunk. I have been trying to work with it, but i obtain the next error with the typical example (MacOSX) >>> libc = ctypes.CDLL("libc.dylib") >>> print libc.strlen("hello") NotImplementedError: variadic functions not supported yet; specify a parameter list I don't know what is the mean of this error. Is it possible to use ctypes in some examples in this moment? Thanks in advance josu |
From: Nicholas R. <nj...@il...> - 2010-03-05 02:00:54
|
In article <71B...@gm...>, josu jugo <jos...@gm...> wrote: > >>> libc = ctypes.CDLL("libc.dylib") > >>> print libc.strlen("hello") > > NotImplementedError: variadic functions not supported yet; specify a > parameter list > > I don't know what is the mean of this error. Is it possible to use ctypes in > some examples in this moment? What ctypes is trying to tell you is that it doesn't know what the argument types for strlen are. So you need to tell it: >>> libc.strlen.argtypes = [ctypes.c_char_p] >>> libc.strlen('hello') 5 -- Nicholas Riley <nj...@il...> |
From: josu j. <jos...@gm...> - 2010-03-05 10:05:54
|
Thanks again, Nicholas (sure that the first thing should be "thanks for your work!") Just one question more, ;): Usually, I use jna (or sometimes jni) to access native libraries under jython. I think that the advantage of ctypes is the use of work derived from CPython. Do you expect that will be easily ported code using ctypes from CPyhton to jython (I am thinking in numpy and so on ... )? josu On 2010 mar 5, at 08:54, Nicholas Riley wrote: > On Mar 5, 2010, at 1:41 AM, josu jugo wrote: >> >> OK, I will read it more deeply. However, I have been following typical ctypes examples (as the previous one) without luck. So, I have gone more speedy than I should go. > > Feel free to keep asking questions on the mailing list. I don't know of anyone else using the ctypes support, so at least this will provide some motivation for the people working on it :-) > > Of note, CPython's ctypes can't read the parameters for strlen either; it just makes some assumptions about the types you pass into it. > > -- > Nicholas Riley <nj...@il...> > |
From: Larry R. <La...@Ri...> - 2010-03-05 11:01:05
|
> I think that the advantage of ctypes is the use of > work derived from CPython. Do you expect that will > be easily ported code using ctypes from CPyhton to > jython (I am thinking in numpy and so on ... )? I think it would be interesting to see ctypes used to provide the module-facing side of the CPython extension API, so the Jython VM looks to the module like the CPython VM. Maybe this could be implemented first as a passthrough in CPython using its ctypes, then ported over to use the ctypes implementation in Jython. Larry |