Re: [pypy-dev] dlopen NotImplementedError
Hi, 2010/12/23 Maciej Fijalkowski fij...@gmail.com CDLL(None) (or LoadLibrary(None)) is supposed to return to you the whole namespace (all loaded libraries). It's unsupported as far as I can tell. It should work by now (on Unix platforms of course). -- Amaury Forgeot d'Arc ___ pypy-dev@codespeak.net http://codespeak.net/mailman/listinfo/pypy-dev
[pypy-dev] dlopen NotImplementedError
So, as of today, I'm starting to do as much of my day-to-day work in pypy as I can. The missing numpy is a problem, but one I can work around a enough amount of the time to make this effort worth my while. I don't know how, or even whether, I should report certain kinds of problems I might run into. I would appreciate some feedback on that. I want to help by giving feedback in whatever form, and to what degree, the pypy devs desire. For example, I can run some scripts in pypy 1.4 but not in pypy fast-forward because of an error involving dlopen(). Other scripts are unaffected by this problem, depending on what needs to be imported. When I try to run fast-forward in interactive mode, I get the same error, which is pasted below. Python 2.7.0 (8c2427fa1a01, Dec 19 2010, 15:58:12) [PyPy 1.4.0 with GCC 4.1.2] on linux2 Type help, copyright, credits or license for more information. Traceback (most recent call last): File app_main.py, line 53, in run_toplevel File app_main.py, line 522, in run_it File /etc/pythonstart, line 7, in module import readline File /root/pypy/lib_pypy/readline.py, line 9, in module File /root/pypy/lib_pypy/pyrepl/readline.py, line 33, in module File /root/pypy/lib_pypy/pyrepl/unix_console.py, line 25, in module File /root/pypy/lib_pypy/pyrepl/curses.py, line 30, in module File /root/pypy/lib_pypy/_minimal_curses.py, line 12, in module File /root/pypy/lib-python/modified-2.7.0/ctypes/__init__.py, line 441, in module File /root/pypy/lib-python/modified-2.7.0/ctypes/__init__.py, line 353, in __init__ File /root/pypy/lib_pypy/_ctypes/dll.py, line 7, in dlopen NotImplementedError: dlopen(None) And now for something completely different: ``- do you know berlin? - all of it? - well, just berlin'' Traceback (most recent call last): File app_main.py, line 53, in run_toplevel File /root/pypy/lib_pypy/_pypy_interact.py, line 27, in interactive_console File /root/pypy/lib_pypy/pyrepl/simple_interact.py, line 27, in module File /root/pypy/lib_pypy/pyrepl/readline.py, line 33, in module File /root/pypy/lib_pypy/pyrepl/unix_console.py, line 25, in module File /root/pypy/lib_pypy/pyrepl/curses.py, line 30, in module File /root/pypy/lib_pypy/_minimal_curses.py, line 12, in module File /root/pypy/lib-python/modified-2.7.0/ctypes/__init__.py, line 441, in module File /root/pypy/lib-python/modified-2.7.0/ctypes/__init__.py, line 353, in __init__ File /root/pypy/lib_pypy/_ctypes/dll.py, line 7, in dlopen NotImplementedError: dlopen(None) -- Gary Robinson CTO Emergent Discovery, LLC personal email: gary...@me.com work email: grobin...@emergentdiscovery.com Company: http://www.emergentdiscovery.com Blog:http://www.garyrobinson.net ___ pypy-dev@codespeak.net http://codespeak.net/mailman/listinfo/pypy-dev
Re: [pypy-dev] dlopen NotImplementedError
Hmm, I'm thinking the dlopen error might be my problem. I think I built python at /root/pypy, and then moved it to a more proper location. But the error message is referring to /root/pypy, so I'm guessing it has that location hardcoded because that's where I built it? I'm going to rebuild but I wanted to post this message so that you guys don't worry about it (unless rebuilding doesn't help). -- Gary Robinson CTO Emergent Discovery, LLC personal email: gary...@me.com work email: grobin...@emergentdiscovery.com Company: http://www.emergentdiscovery.com Blog:http://www.garyrobinson.net ___ pypy-dev@codespeak.net http://codespeak.net/mailman/listinfo/pypy-dev
Re: [pypy-dev] dlopen NotImplementedError
On Wed, Dec 22, 2010 at 3:52 PM, Gary Robinson gary...@me.com wrote: Hmm, I'm thinking the dlopen error might be my problem. I think I built python at /root/pypy, and then moved it to a more proper location. But the error message is referring to /root/pypy, so I'm guessing it has that location hardcoded because that's where I built it? I'm going to rebuild but I wanted to post this message so that you guys don't worry about it (unless rebuilding doesn't help). -- Gary Robinson CTO Emergent Discovery, LLC personal email: gary...@me.com work email: grobin...@emergentdiscovery.com Company: http://www.emergentdiscovery.com Blog:http://www.garyrobinson.net ___ pypy-dev@codespeak.net http://codespeak.net/mailman/listinfo/pypy-dev Nope, it's a known thing, anything trying to import ctypes on fast-forward blows up ATM. If anyone knows what dlopen(None) is supposed to mean, can they let me know and I'll try to take a pass at fixing this? Alex -- I disapprove of what you say, but I will defend to the death your right to say it. -- Evelyn Beatrice Hall (summarizing Voltaire) The people's good is the highest law. -- Cicero Code can always be simpler than you think, but never as simple as you want -- Me ___ pypy-dev@codespeak.net http://codespeak.net/mailman/listinfo/pypy-dev
Re: [pypy-dev] dlopen NotImplementedError
On 09:54 pm, alex.gay...@gmail.com wrote: On Wed, Dec 22, 2010 at 3:52 PM, Gary Robinson gary...@me.com wrote: Hmm, I'm thinking the dlopen error might be my problem. I think I built python at /root/pypy, and then moved it to a more proper location. But the error message is referring to /root/pypy, so I'm guessing it has that location hardcoded because that's where I built it? I'm going to rebuild but I wanted to post this message so that you guys don't worry about it (unless rebuilding doesn't help). Nope, it's a known thing, anything trying to import ctypes on fast- forward blows up ATM. If anyone knows what dlopen(None) is supposed to mean, can they let me know and I'll try to take a pass at fixing this? From the dlopen man page: If filename is NULL, then the returned handle is for the main program. I imagine that's the case someone is trying to trigger with ctypes.LoadLibrary(None) (which is what the name `dlopen` is bound to in this context). On the other hand, maybe it's just a screw up somewhere else that causes None to show up instead of the right library name, I haven't looked at the code in question much. Jean-Paul ___ pypy-dev@codespeak.net http://codespeak.net/mailman/listinfo/pypy-dev
Re: [pypy-dev] dlopen NotImplementedError
On Wed, Dec 22, 2010 at 4:41 PM, exar...@twistedmatrix.com wrote: On 09:54 pm, alex.gay...@gmail.com wrote: On Wed, Dec 22, 2010 at 3:52 PM, Gary Robinson gary...@me.com wrote: Hmm, I'm thinking the dlopen error might be my problem. I think I built python at /root/pypy, and then moved it to a more proper location. But the error message is referring to /root/pypy, so I'm guessing it has that location hardcoded because that's where I built it? I'm going to rebuild but I wanted to post this message so that you guys don't worry about it (unless rebuilding doesn't help). Nope, it's a known thing, anything trying to import ctypes on fast- forward blows up ATM. If anyone knows what dlopen(None) is supposed to mean, can they let me know and I'll try to take a pass at fixing this? From the dlopen man page: If filename is NULL, then the returned handle is for the main program. I imagine that's the case someone is trying to trigger with ctypes.LoadLibrary(None) (which is what the name `dlopen` is bound to in this context). On the other hand, maybe it's just a screw up somewhere else that causes None to show up instead of the right library name, I haven't looked at the code in question much. Jean-Paul ___ pypy-dev@codespeak.net http://codespeak.net/mailman/listinfo/pypy-dev Ok I see the issue I think. It's coming from PyDLL(None). Not sure what the right solution is there, I know Amaury said he was working on the cpythonapi stuff. Alex -- I disapprove of what you say, but I will defend to the death your right to say it. -- Evelyn Beatrice Hall (summarizing Voltaire) The people's good is the highest law. -- Cicero Code can always be simpler than you think, but never as simple as you want -- Me ___ pypy-dev@codespeak.net http://codespeak.net/mailman/listinfo/pypy-dev
Re: [pypy-dev] dlopen NotImplementedError
CDLL(None) (or LoadLibrary(None)) is supposed to return to you the whole namespace (all loaded libraries). It's unsupported as far as I can tell. On Thu, Dec 23, 2010 at 12:45 AM, Alex Gaynor alex.gay...@gmail.com wrote: On Wed, Dec 22, 2010 at 4:41 PM, exar...@twistedmatrix.com wrote: On 09:54 pm, alex.gay...@gmail.com wrote: On Wed, Dec 22, 2010 at 3:52 PM, Gary Robinson gary...@me.com wrote: Hmm, I'm thinking the dlopen error might be my problem. I think I built python at /root/pypy, and then moved it to a more proper location. But the error message is referring to /root/pypy, so I'm guessing it has that location hardcoded because that's where I built it? I'm going to rebuild but I wanted to post this message so that you guys don't worry about it (unless rebuilding doesn't help). Nope, it's a known thing, anything trying to import ctypes on fast- forward blows up ATM. If anyone knows what dlopen(None) is supposed to mean, can they let me know and I'll try to take a pass at fixing this? From the dlopen man page: If filename is NULL, then the returned handle is for the main program. I imagine that's the case someone is trying to trigger with ctypes.LoadLibrary(None) (which is what the name `dlopen` is bound to in this context). On the other hand, maybe it's just a screw up somewhere else that causes None to show up instead of the right library name, I haven't looked at the code in question much. Jean-Paul ___ pypy-dev@codespeak.net http://codespeak.net/mailman/listinfo/pypy-dev Ok I see the issue I think. It's coming from PyDLL(None). Not sure what the right solution is there, I know Amaury said he was working on the cpythonapi stuff. Alex -- I disapprove of what you say, but I will defend to the death your right to say it. -- Evelyn Beatrice Hall (summarizing Voltaire) The people's good is the highest law. -- Cicero Code can always be simpler than you think, but never as simple as you want -- Me ___ pypy-dev@codespeak.net http://codespeak.net/mailman/listinfo/pypy-dev ___ pypy-dev@codespeak.net http://codespeak.net/mailman/listinfo/pypy-dev