Am 13.09.2014 03:19, schrieb Grant Edwards:
On 2014-09-12, Thomas Heller wrote:
Am 12.09.2014 18:38, schrieb Chris Angelico:
Does Tkinter really work well with cx_Freeze? I doubt it (from my
experiences with py2exe).
I never had any problems with Tkinter and py2exe, but you do get
a
Am 12.09.2014 18:38, schrieb Chris Angelico:
On Sat, Sep 13, 2014 at 2:35 AM, Nagy László Zsolt wrote:
So I need to create a GUI mode version of my program. That the customer
should be able to see a progress bar. What kind of GUI toolkit should I use
for this? I would like this to be lightweigh
Am 23.07.2014 06:23, schrieb Steven D'Aprano:
A little known feature of Python: you can wrap your Python application in
a zip file and distribute it as a single file. The trick to make it
runnable is to put your main function inside a file called __main__.py
inside the zip file.
Look here:
htt
Am 21.06.2014 09:08, schrieb peter.balazo...@emspin.com:
Dears,
I am not sure I am at right place here. Now I've started working with comtypes
1.1.0 package within python 2.7.6.1. I have ActiveX COM object I want access
and work with it.
I do following
from comtypes.client import CreateObjec
Am 14.02.2014 17:32, schrieb Ethan Furman:
On 02/14/2014 08:10 AM, Sam wrote:
Dynamic data type has pros and cons. It is easier to program but
also easier to create bugs. What are the best practices to reduce
bugs caused by Python's dynamic data-type characteristic? Can the
experienced Pytho
Am 16.12.2013 12:18, schrieb Nicholas Cole:
Dear List,
What is the best way to distribute a private, pure python, Python 3
project that needs several modules (some available on pypi but some
private and used by several separate projects) in order to run?
I'd like to include everything that my p
Am 19.11.2013 17:58, schrieb Mark Summerfield:
Hi,
I am using ctypes to access a function in a DLL using Python 3.3
32-bit on Windows 7 64-bit:
dplGetPageText = dpl.DPLGetPageText dplGetPageText.argtypes =
(ctypes.c_int, ctypes.c_int) dplGetPageText.restype =
ctypes.c_wchar_p
Python returns th
"All of the surviving members of comedy group Monty Python are to reform
for a stage show, one of the Pythons, Terry Jones, has confirmed."
See: http://www.bbc.co.uk/news/entertainment-arts-24999401
Thomas
--
https://mail.python.org/mailman/listinfo/python-list
Am 28.06.2013 17:25, schrieb Thomas Heller:
Robert Kern:
enum.EnumMeta uses super() in its __new__() implementation but
_ctypes.PyCSimpleType doesn't. Thus, only
_ctypes.PyCSimpleType.__new__() gets a chance to run. Switching the
order of the two might work.
Robert found the proble
Am 28.06.2013 17:16, schrieb Ethan Furman:
On 06/28/2013 03:48 AM, Thomas Heller wrote:
trying out the enum34 module.
What I want to create is a subclass of enum.Enum that is also based
on ctypes.c_int so that I can better use enum instances in ctypes
api calls.
Have you tried using
trying out the enum34 module.
What I want to create is a subclass of enum.Enum that is also
based on ctypes.c_int so that I can better use enum instances
in ctypes api calls.
When I do this, I get a metaclass conflict:
>>> class MyEnum(ctypes.c_int, enum.Enum):
...FOOBAR = 0
...
Traceback
Am 15.03.2013 11:58, schrieb Steven D'Aprano:
On Fri, 15 Mar 2013 11:46:36 +0100, Thomas Heller wrote:
[Windows: Problems with unicode output to console]
You can isolate the error by noting that the second one only raises an
exception when you try to print it. That suggests that the pr
I thought I understand unicode (somewhat, at least), but this seems
not to be the case.
I expected the following code to print 'µm' two times to the console:
# -*- coding: cp850 -*-
a = u"µm"
b = u"\u03bcm"
print(a)
print(b)
But what I get is this:
µm
Traceback (most recent call last):
Am 15.02.2013 08:11, schrieb Travis Oliphant:
Hey all,
With Numba and Blaze we have been doing a lot of work on what
essentially is compiler technology and realizing more and more that
we are treading on ground that has been plowed before with many other
projects. So, we wanted to create a web
Am 31.01.2013 12:05, schrieb Andreas Röhler:
Am 31.01.2013 10:03, schrieb Thomas Heller:
Has someone managed to patch python-mode.el to use
the PEP 397 python launcher when you hit C-c C-c?
It seems that emacs should parse the shebang line in the edited
python script and pass the corresponding
Has someone managed to patch python-mode.el to use
the PEP 397 python launcher when you hit C-c C-c?
It seems that emacs should parse the shebang line in the edited
python script and pass the corresponding arguments to py.exe.
Thomas
--
http://mail.python.org/mailman/listinfo/python-list
Am 24.01.2013 16:54, schrieb rusi:
[I personally use emacs. It would be sadistic to make that into a
recommendation]
It would be truly sadistic to force a long-time emacs user to any
other editor.
Thomas
--
http://mail.python.org/mailman/listinfo/python-list
Am 27.06.2012 20:06, schrieb Terry Reedy:
On 6/27/2012 10:36 AM, Thomas Heller wrote:
Is there a tool, similar to 2to3, which converts python2 code
to code using six.py, so that it runs unchanged with python2
*and* python 3?
Others have expressed a similar wish, but I do not know that anyone
Is there a tool, similar to 2to3, which converts python2 code
to code using six.py, so that it runs unchanged with python2
*and* python 3?
Thomas
--
http://mail.python.org/mailman/listinfo/python-list
Am 02.05.2012 22:05, schrieb Thomas Heller:
class GPIO(BitVector):
def __init__(self, address, value=0xFF, nbits=8):
self.address = address
super(GPIO, self).__init__(value, nbits)
def _get_value(self):
"read an 8-bit value from the hardware as 8-bit in
Am 02.05.2012 19:40, schrieb Petr Jakes:
Hi,
I am trying to work with HW peripherals on Raspberry Pi
To achieve this, it is necessary read/write some values from/to the
memory directly.
I am looking for some wise way how to organize the bit twiddling.
To set some specific bit, for example, it i
Am 17.01.2012 18:10, schrieb Alex Willmer:
Hello,
I'm looking for a way to find the occurrences of x is y comparisons in
an existing code base. Except for a few special cases (e.g. x is [not]
None) they're a usually mistakes, the correct test being x == y.
However they happen to work most of the
Am 12.10.2011 10:22, schrieb Christian Wutte:
Hello all,
as stated in the docs [1] os.startfile relies on Win32 ShellExecute().
So maybe someone can explain it to me, why there is no support for
program arguments.
That's quite a pity since os.startfile is the easiest way for an
elevated run (with
Am 20.05.2011 19:56, schrieb Andrew Berg:
This is probably somewhat off-topic, but where would I find a list of
what each error code in WindowsError means? WindowsError is so broad
that it could be difficult to decide what to do in an except clause.
Fortunately, sys.exc_info()[1][0] holds the spe
Am 20.04.2011 00:21, schrieb Grant Edwards:
I'm have problems figuring out how to receive UDP broadcast packets on
Linux.
[...]
On the receiving machine, I've used tcpdump to verify that broadcast
packets are being seen and have a destination IP of 255.255.255.255 and
destination MAC of ff:ff:
Paul Moore schrieb:
>>From a quick experiment, it seems that select.select with a timeout
> doesn't react to a keyboard interrupt until the timeout expires.
> Specifically, if I do
>
> s = socket.socket()
> select.select([s], [], [], 30)
>
> and then press Ctrl-C, Python waits for the 30 seconds
Brendan Miller schrieb:
> I have a function exposed through ctypes that returns a c_char_p.
> Since I need to deallocate that c_char_p, it's inconvenient that
> ctypes copies the c_char_p into a string instead of giving me the raw
> pointer. I believe this will cause a memory leak, unless ctypes is
Patrick Maupin schrieb:
> On Apr 2, 6:24 am, Peter Otten <__pete...@web.de> wrote:
>> Thomas Heller wrote:
>> > Maybe I'm just lazy, but what is the fastest way to convert a string
>> > into a tuple containing character sequences and integer numbers, like
>
Maybe I'm just lazy, but what is the fastest way to convert a string
into a tuple containing character sequences and integer numbers, like this:
'si_pos_99_rep_1_0.ita' -> ('si_pos_', 99, '_rep_', 1, '_', 0, '.ita')
Thanks for ideas,
Thomas
--
http://mail.python.org/mailman/listinfo/python-li
Joe Fox schrieb:
> Hi,
>
> actually i have simplified my scenario a lot here ,
>
> In my actual case , i have to call a C-api which blocks on c select , in a
> separate thread.
>
> my thread is getting struck in that api , and thus blocking all the other
> threads.
> Can you point to something
Am 05.01.2010 12:19, schrieb Coert Klaver (DT):
> Hi,
>
> I am using ctypes in python 3 on a WXP machine
>
> Loading a dll and using its exported functions works fine.
>
> Now I want to use a function in the dll that is not exported.
>
> In C this can be done by just casting the address in the
M.-A. Lemburg schrieb:
> Jonathan Hartley wrote:
>> While examining py2exe et al of late, my thoughts keep returning to
>> the idea of writing, in C or similar, a compiled stand-alone
>> executable 'bootstrapper', which:
>> 1) downloads and install a Python interpreter if none exists
>> 2) runs the
Paul Moore schrieb:
> I run Python on Windows. I have the (pure Python) pyreadline package
> installed for (occasional) use by IPython. However, when I use the
> normal Python interactive prompt, the mere fact that the readline
> module exists means that it gets used.
>
> Is there a way of disabli
Philip Semanchuk schrieb:
> On Jun 5, 2009, at 10:13 AM, Thomas Heller wrote:
>
>> s...@pobox.com schrieb:
>>>>> If there is no C++ compiler available then the proposed layout
>>>>> sniffing just
>>> wouldn't be done and eithe
s...@pobox.com schrieb:
> >> Requiring that the C++ compiler used to make the dll's/so's to be the
> >> same one Python is compiled with wouldn't be too burdensome would it?
>
> Scott> And what gave you then impression that Python is compiled with a
> Scott> C++ compiler?
>
> I do
Joseph Garvin schrieb:
> On Thu, Jun 4, 2009 at 3:23 PM, Brian wrote:
>> What is the goal of this conversation that goes above and beyond what
>> Boost.Python + pygccxml achieve?
>
> I can't speak for others but the reason I was asking is because it's
> nice to be able to define bindings from wit
Amit Gupta schrieb:
> Hi,
>
> I have been using ctype.cdll to load a library, but I am unable to
> figure out how to load multiple libraries that depends on each other.
> E.g. I have two libraries A.so and B.so. A.so has some undefined
> references, and those symbols are defined in B.so.
>
> When
Philip Semanchuk schrieb:
> Hi Thomas,
> We're weighing options for accessing C++ objects via Python. I know of
> SIWG and Boost; are there others that you think deserve consideration?
I haven't used any of them myself. A common suggestion is SIP,
less known are pybindgen and Robin. But there
[Please keep the discussion on the list]
Joseph Garvin schrieb:
> On Thu, Jun 4, 2009 at 3:43 AM, Thomas Heller wrote:
>> There have been some attempts to use ctypes to access C++ objects.
>> We (Roman Yakovenko and myself) made some progress. We were able to
>> handle C
Joseph Garvin schrieb:
> So I was curious whether it's possible to use the ctypes module with
> C++ and if so how difficult it is.
There have been some attempts to use ctypes to access C++ objects.
We (Roman Yakovenko and myself) made some progress. We were able to
handle C++ name mangling, the s
Ned Deily schrieb:
> In article <76vs9tf1f6c5...@mid.individual.net>,
> Thomas Heller wrote:
>> Diez B. Roggisch schrieb:
>> > Thomas Heller wrote:
>> >> Python 2.6 contains the json module, which I thought was the renamed (and
>> >> improved?
Diez B. Roggisch schrieb:
> Thomas Heller wrote:
>
>> Python 2.6 contains the json module, which I thought was the renamed (and
>> improved?) simplejson module that also works on older Python versions.
>>
>> However, it seems the json is a lot slower than simplejso
David Lyon schrieb:
> On Wed, 13 May 2009 05:32:16 +0200, "Martin v. Löwis"
> wrote:
>
>> I think this was a case of obscure misconfiguration of the system.
>> It is always possible to configure a system in such a way that even
>> the most resilient installation procedure will break.
>
> Techni
Python 2.6 contains the json module, which I thought was the renamed (and
improved?)
simplejson module that also works on older Python versions.
However, it seems the json is a lot slower than simplejson.
This little test, run on Python 2.6.2 and WinXP shows a dramatic difference:
C:\>py26 -m
Thomas Heller schrieb:
> I'm looking for a lightweight web-framework for an embedded system.
> The system is running a realtime linux-variant on a 200 MHz ARM
> processor, Python reports a performance of around 500 pystones.
>
> The web application will not be too fancy, n
I'm looking for a lightweight web-framework for an embedded system.
The system is running a realtime linux-variant on a 200 MHz ARM
processor, Python reports a performance of around 500 pystones.
The web application will not be too fancy, no databases involved
for example, but it will need to cont
lorenzo.mentas...@yahoo.it schrieb:
> Hi all,
> I need to call GetSystemPowerState windows api from pythonCE, because
> I need to know if a windows ce 5 device is in sleep/off status.
> I can find this api in ctypes.windll.coredll, but I cannot figure out
> how to pass parameters to this procedure:
PS schrieb:
> Hello all
>
> I can't install neither python 2.6.1 nor 2.6.2 because an error during
> compilation of _ctypes module, I don't need the module but I don't
> know how to instruct to skip it.
You only get a warning, right? So a subsequent 'make install' should work.
--
http://mail.pyt
Ralf schrieb:
>> I think that for whatever reasons, explorer always tries to create
>> shell extensions as InProc. CoCreateInstance, which is the usual
>> API to create COM instances, allows to specify which one you want.
>>
>> Thomas
>
> So there is no way to do this, other than to create a "pro
Ralf schrieb:
> I'm trying to develop Windows Shell Extensions with the Python Win32
> Extensions. Most of the samples are working. However, I have a
> slightly different need: I want the Python COM server to run as a
> separate process ("LocalServer" or "OutOfProc").
>
> As I understand, both the
greg schrieb:
> Suraj Barkale wrote:
>
>> I installed this and tried out the tests on Python 2.6.1 and Windows XP
>> SP3. Following are my observations.
>
> Thanks, I'll look into these.
>
>> Test 33-mouse-events.py:
>> 1. mouse-enter and mouse-leave events are not reported.
>
> That's actu
I have installed pyreadline, and get nice tab completion in
the normal interactive interpreter:
Python 2.4.4 (#71, Oct 18 2006, 08:34:43) [MSC v.1310 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import rlcompleter
>>> import readline
>>> read
Christian Heimes schrieb:
> Hrvoje Niksic schrieb:
>> "Diez B. Roggisch" writes:
>>
>>> The answer is easy: if you use C, you can use ctypes to create a
>>> wrapper - with pure python, no compilation, no platform issues.
>>
>> The last part is not true. ctypes doesn't work on 64-bit
>> architec
> Maxim Demenko schrieb:
>> Hi,
>> i have installed Python 2.5.4 on WinXP, setuptools-0.6c9 and py2exe 0.6.9
>> Now i can't list installed modules, here is the stacktrace:
[...]
>> Any suggestion, how to fix this issue?
>
Thomas Heller schrieb:
> Looks like a
Maxim Demenko schrieb:
> Hi,
> i have installed Python 2.5.4 on WinXP, setuptools-0.6c9 and py2exe 0.6.9
> Now i can't list installed modules, here is the stacktrace:
>
>
>
> help> modules
>
> Please wait a moment while I gather a list of all available modules...
>
> Traceback (most recent cal
Armin schrieb:
> As posted before ... set's my script (python 2.3):
>
> from distutils.core import setup
> import py2exe
>
> setup(windows=['dpconf.py'],
> data_files=[ "", ["proj_db","gsd_db","dachs2.xbm"]]
> )
>
> When I create the distribution I got the following err msg:
>
> *** c
Nick Craig-Wood schrieb:
> Thomas Heller wrote:
>> Nick Craig-Wood schrieb:
>> > Interesting - I didn't know about h2xml and xml2py before and I've
>> > done lots of ctypes wrapping! Something to help with the initial
>> > drudge work of c
Nick Craig-Wood schrieb:
> Ralf Schoenian wrote:
>> Ryan wrote:
>> > I've been using Python for many years now. It's a wonderful language
>> > that I enjoy using everyday. I'm now interested in getting to know
>> > more about the guts (C/C++) and extending it. But, extending python
>> > still see
Steve Holden schrieb:
> Thomas Heller wrote:
>> Question from a non-native english speaker: is this now valid english?
>>
>> "One of Python’s great strengths"
>> ^
>> "and also teaches Python’s functional programming features&
Mark Summerfield schrieb:
> Just a follow-up to say that the book has now been published in the
> U.S.
> It is now in stock at InformIT, and should reach other stores, e.g.,
> Amazon, in a week or so.
>
> Also, the introduction, the first few pages of the first chapter, the
> whole of chapter 12 (
Jan Roelens schrieb:
> Dear python experts,
>
> How can I change the alignment of types in the ctypes package? I have
> a library that was built with gcc using the -malign-double option. I
> also have python code that can create ctypes wrapper code from the
> include files for that library. The pr
Roy Smith schrieb:
> I'm working with marshaling data over a binary wire protocol. I'm
> using struct.pack() to handle the low-level encoding of ints. One of
> the things I need to do is make sure an int can be represented in 4
> bytes. Is there a portable way to do that? For now, I'm doing sig
Paul Moore schrieb:
> I'm trying to implement an extension type with a power operator. The
> operator is unusual in that I want to allow my objects to be raised to
> an integer power:
>
>p = Pattern()
>p3 = p ** 3
>
> I've implemented the code for a nb_power slot, it converts the "other"
Philip Semanchuk schrieb:
> I'm writing a Python extension in C that wraps a function which takes
> a void * as a parameter. (The function is shmat() which attaches a
> chunk of shared memory to the process at the address supplied by the
> caller.) I would like to expose this function to Pyth
Andy schrieb:
> Dear Python dev community,
>
> [...] Basically,
> we use embedded python and use it to wrap our high performance C++
> class set which wraps OpenGL, DirectX and our own software renderer.
> In addition to wrapping our C++ frameworks, we use python to perform
> various "worker" tas
[EMAIL PROTECTED] schrieb:
> Kay Schluehr:
>> Sometimes it helps when people just make clear how they use technical
>> terms instead of invoking vague associations.
>
> And generally Python docs can enjoy growing few thousands examples...
Well, that may not be necessary. But I think that a clear
> Thomas Heller wrote:
>> Does Python 3 have no way anymore to sort with a comparison function?
>>
>> Both [].sort() and sorted() seem to accept only 'key' and 'reverse'
>> arguments,
>> the 'cmp' argument seems to be gone. Can that
Christian Heimes schrieb:
> Thomas Heller wrote:
>> Ok, so one has to write an extension to access or expose it.
>>
>> Oh, wait - there's ctypes:
>
> I wrote the type to help the Pyrex and Cython developers to port their
> software to 3.0. I planed t
Terry Reedy schrieb:
> Thomas Heller wrote:
>> Christian Heimes schrieb:
>>> I've written PyInstanceMethod_Type for this use case. It's not (yet)
>>> available for Python code.>> Oh, wait - there's ctypes:
>>
>> Python 3.0rc1 (r30rc1
Does Python 3 have no way anymore to sort with a comparison function?
Both [].sort() and sorted() seem to accept only 'key' and 'reverse' arguments,
the 'cmp' argument seems to be gone. Can that be?
Thomas
--
http://mail.python.org/mailman/listinfo/python-list
Christian Heimes schrieb:
> Thomas Heller wrote:
>> but this is very ugly, imo. Is there another way?
>> The raw_func instances that I have are not descriptors (they
>> do not implement a __get__() method...)
>
> I've written PyInstanceMethod_Type for this use c
I'm currently using code like this to create unbound methods
from functions and stick them into classes:
method = new.instancemethod(raw_func, None, cls)
setattr(cls, name, method)
Ok, python 2.6, run with the -3 flag, gives a warning that the new
module is going away in python 3.0, so the
Mark Dickinson schrieb:
> On Oct 5, 11:40 pm, Terry Reedy <[EMAIL PROTECTED]> wrote:
>> Your point, that taking floor(log2(x)) is redundant, is a good catch.
>> However, you should have added 'untested' ;-). When value has more
>> significant bits than the fp mantissa can hold, this expression can
Sayanan Sivaraman schrieb:
> Hey all,
>
> I'm trying to use DirectShow to display videos [I'm kind of new to
> Python, from more of a C++ background on windows]. I found some
> sample code online, but I am having trouble with calling the I
>
> import ctypes
> from ctypes import *
> from comtypes
Paul Rubin schrieb:
> I think I've asked about this before, but is there a way to set up
> Python to handle uncaught exceptions with pdb? I know about setting
> sys.except_hook to something that calls pdb, but this is normally done
> at the outer level of a program, and by the time that hook gets
Fredrik Lundh schrieb:
> Fredrik Lundh wrote:
>
>>> I do have the tidy.dll installed (if I didn't, I couldn't even import
>>> the tidy module).
>>
>> typing the following into the Python interpreter might give you some
>> more clues:
>>
>> >>> import _tidy
>> >>> _tidy.__file__
>>
Vinay Sajip schrieb:
> On Aug 27, 11:28 am, Thomas Heller <[EMAIL PROTECTED]> wrote:
>>
>> I came up with a workaround that seems to do what I want. I add a NULL
>> handler
>> to my top-level logger which is not the root logger but a logger named
>>
Paul McNett schrieb:
> Anyone have anything to suggest on this error:
>
> {{{
> Traceback (most recent call last):
>File "shutter_studio.py", line 41, in
>File "App.pyo", line 25, in
>File "ui\__init__.pyo", line 23, in
>File "ui\FrmProductionOrders.pyo", line 10, in
>File
Vinay Sajip schrieb:
> Suppose a user of logging configures it wrongly by mistake, so that
> there are no handlers configured. In this case, if the logging system
> were not to output anything at all, then you would have no information
> at all about why - leading to a longer time to diagnose the
I'm using the logging module in my comtypes library to log
'interesting' things that happen. In other words, the idea
is if the user of the library is interested in the details that
happen in the package internally, he (she?) would configure
a logging level and handlers that write the log messages
Virgil Stokes schrieb:
> I would appreciate python code for creating *.cab files.
>
> --V. Stokes
Here is some code that I have still laying around. It has never been
used in production and I do not know what you can do with the cab files
it creates, but I have been able to create a cab and open
waldek schrieb:
> Hi,
>
> I'm trying to handle data passed to Py Callback which is called from
> C dll. Callback passes data to another thread using Queue module and
> there the data are printed out.
>
> If data is printed out in a callback itself it's ok. If I put on
> queue and next get from
Philluminati schrieb:
> I'm a bit of a python newbie and I need to wrap a C library.
>
> I can initialise the library using CDLL('mcclient.so')
>
> and I can call functions correctly inside the library but I need to
> invoke one function which has this function definition:
>
> char ** CAPAPI McS
waldek schrieb:
> Hi,
>
> I'm using C dll with py module and wanna read value (buffer of bytes)
> returned in py callback as parameter passed to dll function.
>
The callback receives a pointer instance. You can dereference the pointer
to read individual bytes in this way:
print data[0], data
waldek schrieb:
> Hi,
>
> I have module A.py and B.dll which exports C functions by cdecl_
>
> In A.py I pass callback (py callable) to dll. Next, thread inside dll
> simply calls my callback (in a loop). After few secs I got crash of
> python.exe.
>
> How to debug it?
>
> I'm using winxp and
moreati schrieb:
> Recently I discovered the re module doesn't support POSIX character
> classes:
>
> Python 2.5.2 (r252:60911, Apr 21 2008, 11:12:42)
> [GCC 4.2.3 (Ubuntu 4.2.3-2ubuntu7)] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
import re
r = re
[EMAIL PROTECTED] schrieb:
> Hello,
>
> I'm trying to build an executable with py2exe, but unfortunately the
> version I have is 0.6.6, which has a rather annoying bug that doesn't
> let you rename the executable file if you bundle everything in a
> single executable. It seems fairly unacceptable
Neal Becker schrieb:
> In an earlier post, I was interested in passing a pointer to a structure to
> fcntl.ioctl.
>
> This works:
>
> c = create_string_buffer (...)
> args = struct.pack("iP", len(c), cast (pointer (c), c_void_p).value)
> err = fcntl.ioctl(eos_fd, request, args)
>
> Now to do the
Skye schrieb:
> Great, thanks for the help (I'm fairly new to Python, didn't know
> about ctypes)
>
> from ctypes import *
> libc = CDLL("libc.so.7")
> size = c_uint(0)
> libc.sysctlbyname("net.inet.ip.stats", None, byref(size), None, 0)
> buf = c_char_p(" " * size.value)
>
[EMAIL PROTECTED] schrieb:
> I have created an app using python and then converting it to an exe
> using py2exe, and have the following code:
>
> "icon_resources": [(1, "appFavicon.ico"), (2, "dataFavicon.ico")]
>
> in my py2exe setup file, the appFavicon works fine and it sets that as
> the app
Floris Bruynooghe schrieb:
> Hi
>
> We basically want the same as the OP in [1], i.e. when python starts
> up we don't want to load *any* sys.path entries from the registry,
> including subkeys of the PythonPath key. The result of that thread
> seems to be to edit PC/getpathp.c[2] and recompile.
Phil Thompson schrieb:
> On Thursday 03 April 2008, Thomas Heller wrote:
>> Phil Thompson schrieb:
>> > Could somebody confirm how well ctypes is supported on HP-UX (for both
>> > PA-RISC and Itanium) for both Python v2.4 and v2.5?
>> I cannot answer your questi
Phil Thompson schrieb:
> Could somebody confirm how well ctypes is supported on HP-UX (for both
> PA-RISC
> and Itanium) for both Python v2.4 and v2.5?
>
> I don't have access to an HP system and Google doesn't come up with a
> definitive answer (which may just mean it works fine, but prior exp
Knut schrieb:
>> The script can't resolve the server name. Try to do it by hand using
>> nslookup or even ping (you may want to add a few print statements inside
>> the script to see the exact host name it is trying to connect to, in case
>> it isn't what you expect)
>> If you can't resolve the hos
Jorgen Bodde schrieb:
> Hi All,
>
> I am trying to automate a 3rd party application, and all I have to
> work on is the type library and some documentation. I hope a Python /
> COM guru can answer this or put me on the right path because I don't
> know why it does not work.
>
> First I imported t
Doug Morse schrieb:
> Peter,
>
> Genius! You nailed it -- thanks!
>
> py2exe is apparently getting confused by the fact that packages "Numeric" and
> "numpy" both have files multiarray.pyd and umath.pyd. It copies just one of
> each -- from $PYTHONHOME/Lib/site-packages/numpy/core -- and puts b
Gerhard Häring schrieb:
> import sys
>
> def foo():
> class C(object):
> pass
>
> foo()
> print ">>", sys.gettotalrefcount()
> foo()
> print ">>", sys.gettotalrefcount()
> foo()
> print ">>", sys.gettotalrefcount()
>
> >> 21366
> >> 21387
> >> 21408
> [9779 refs]
>
> Both Pytho
c d saunter schrieb:
> Hi All,
>
> I'm trying to access individual video frames of an AVI file from within
> Python 2.4 or 2.5 under Windows XP.
>
> I have found this example code here for that does exactly what I want,
> using the windows avifile.dll but I am unable to find the AVIFile.h
> hea
Ambush Commander schrieb:
> I'm a newbie to Python; various packages I've used in the past (Lyx,
> LilyPond and Inkscape, to name a few) have bundled Python with them
> for various scripting needs, and Cygwin also had an install lying
> around, so when I started to use Mercurial (also Python) I dec
Helmut Jarausch schrieb:
> Thomas Heller wrote:
>> Helmut Jarausch schrieb:
>>> Hi,
>>>
>>> how can I specify the paths to be searched for a dynamic library
>>> to be loaded by ctypes' CDLL class on a Linux system.
>>>
>>> Do
1 - 100 of 430 matches
Mail list logo