Re: SLUT distibution mangled?

2006-01-28 Thread Ido Yehieli
So I can't run SLUT on windows then? -- http://mail.python.org/mailman/listinfo/python-list

Python loading library containing embedded python...

2006-01-28 Thread Brennus
I have a dll/so which embeds python. I can verify it works by compiling it as an executable and adding an appropriate main. I tried to write unit tests for this library with ctypes and a simple python script. Access violations and other strange things result. I suspect this is because I am basica

Re: Decoupling the version of the file from the name of the module.

2006-01-28 Thread bobueland
Xavier Morel wrote: > Just get rid of the version number in the name (what's the point) and >define a __version__ attribute in the module, that's what is usually done. Thanks Xavier, but as I said I'm newbie and I'm not sure how to do that. Here's my module # circle.py from math import pi __ver

Re: String Manipulation Help!

2006-01-28 Thread Richard Schneiderman
I really enjoyed your article. I will try to understand this. Will you be doing more of this in the future with more complicated examples? Paul McGuire wrote: > "Dave" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] >> OK, I'm stumped. >> >> I'm trying to find newline characters (

Re: Decoupling the version of the file from the name of the module.

2006-01-28 Thread Kirk McDonald
[EMAIL PROTECTED] wrote: > Now suppose I have make a new version with __version__ = 1.1. What > shall I call this file and (I don't want to overwrite the old file if I > need to go back to it) how do I import it from the shell. Your advice > sounds nice, but I would appreciate if you could give me

Re: VB to Python migration

2006-01-28 Thread John M. Gabriele
Josh wrote: > We have a program written in VB6 (over 100,000 lines of code and 230 UI > screens) that we want to get out of VB and into a better language. The > program is over 10 years old and has already been ported from VB3 to > VB6, a job which took over two years. We would like to port it t

Re: Calling C++ function from python script

2006-01-28 Thread Ravi Teja
Pankaj wrote: > The module which i am creating is like > > Part A: > 1. It does some processing by using python code. > 2. The result of this python code execution is written to a text file. > [This part is already compelete]] > > Part B: > 1. I read a text file which is outputted by above python

Re: calling python from C#...

2006-01-28 Thread Ravi Teja
I actually find Python for .NET most convenient http://www.zope.org/Members/Brian/PythonNet I did not try py2exe with these applications, so I cannot comment. -- http://mail.python.org/mailman/listinfo/python-list

Re: calling python from C#...

2006-01-28 Thread Ravi Teja
Python for .NET http://www.zope.org/Members/Brian/PythonNet -- http://mail.python.org/mailman/listinfo/python-list

Re: Calling C++ function from python script

2006-01-28 Thread Pankaj
In my case, i want to use python script as parent script and call C++ function from within the python script. If this is the case, then what am i doing? 1. extending 2. embedding. ? Ravi Teja wrote: > Pankaj wrote: > > The module which i am creating is like > > > > Part A: > > 1. It does some

Re: Calling C++ function from python script

2006-01-28 Thread Ravi Teja
Extending -- http://mail.python.org/mailman/listinfo/python-list

Re: String Manipulation Help!

2006-01-28 Thread Paul McGuire
"Richard Schneiderman" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I really enjoyed your article. I will try to understand this. > Will you be doing more of this in the future with more complicated examples? > I'm giving two presentations at PyCon at the end of February, so I thin

Re: Are there memory limits for external C modules?

2006-01-28 Thread Marc 'BlackJack' Rintsch
In <[EMAIL PROTECTED]>, [EMAIL PROTECTED] wrote: > I was able to modify my C code so that instead of being a Python > module, it runs as a standalone binary, and it works as it should. > Calling it with os.spawn* works. The two versions are essentially the > same, the primary differences being th

Data Crunching and Charting....

2006-01-28 Thread [EMAIL PROTECTED]
Hi all. Question: I have a project nearly complete written in VB.Net using charts from 3rd party vendors...expensive, yes, fast, not really. The data I am plotting is about 30 columns by 3000-9000 rows, all in a tab delimited file(43 files total). My question is whether or not I can accomplish the

Re: Loading a Python collection from an text-file

2006-01-28 Thread Ilias Lazaridis
Ken Starks wrote: > Ilias Lazaridis wrote: > >>within a python script, I like to create a collection which I fill with >>values from an external text-file (user editable). >> >>How is this accomplished the easiest way (if possible without the need >>of libraries which are not part of the standard

Re: Calling C++ function from python script

2006-01-28 Thread Pankaj
The examples given are too complicated. So, if it can be explained using my sample example. Would be thankful for that. /* 1.c File **/ func( char a[10] ) { int i; for( i =0; i < 10; i++) printf("\n array element is: %c", a[i]); } /* 1.py File **/ f = o

Re: Decoupling the version of the file from the name of the module.

2006-01-28 Thread Roy Smith
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] wrote: > I'm a newbie experimenting with Python. I want to incrementally develop > a module called 'circle'. The problem is now that the file name is used > for two purposes. To keep track of the version number and as the name > for the module. So

Re: SLUT distibution mangled?

2006-01-28 Thread Paul McGuire
"Ido Yehieli" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > So I can't run SLUT on windows then? > Well, here's what I did (I'm running on WinXP). 1. Opened up slut.zip with a text editor (used Scite.exe), and changed all of the "/aux" references to "/bux" 2. Expanded the ZIP file.

Re: Decoupling the version of the file from the name of the module.

2006-01-28 Thread Steven D'Aprano
On Sat, 28 Jan 2006 23:13:12 +0100, Xavier Morel wrote: > [EMAIL PROTECTED] wrote: >> I'm a newbie experimenting with Python. I want to incrementally develop >> a module called 'circle'. The problem is now that the file name is used >> for two purposes. To keep track of the version number and as t

Re: Decoupling the version of the file from the name of the module.

2006-01-28 Thread Roy Smith
[EMAIL PROTECTED] wrote: > Now suppose I have make a new version with __version__ = 1.1. What > shall I call this file and (I don't want to overwrite the old file if I > need to go back to it)? Stop everything right now and get yourself some kind of version control system. CVS (http://ximbiot.co

Re: How do I tell if I'm running in the PyWin interpreter?

2006-01-28 Thread Charles Krug
On 2006-01-28, Charles Krug <[EMAIL PROTECTED]> wrote: > On 2006-01-28, Peter Otten <[EMAIL PROTECTED]> wrote: >> Charles Krug wrote: >> >>> Is there a way to detect that I'm running the the PyWin interpreter so >>> that I can bypass its raw_input behavior? >> >> You could test >> >> if pywin_speci

Trouble opening files

2006-01-28 Thread Westbrook, Christopher L (WESTBCL04)
I am having some trouble, and I can't figure out why. I'm trying to use the simple keylogger project from source forge, and then create a web interface to open the resulting files, so people from the outside can see the keys logged on a server. I've got the keylogger script working fine, and I ha

Re: Data Crunching and Charting....

2006-01-28 Thread Mr BigSmoke
Hi Tom. I had more or less the same problem about 1 year and a half ago... Since then i've tried either Matplotlib and chaco. I've started using matplotlib but for some features reason i've decided to use only chaco. Chaco is really cool but has some neg. points: - documentation is not really deta

Re: Calling C++ function from python script

2006-01-28 Thread Ravi Teja
Right. They are complicated(Assuming that you are reading Python API docs), especially if you have not done a substantial amount of C. You spent 8 minutes trying to understand them. What did you expect? People spend days sorting out the API issues. If you are in a hurry, Pyrex is easiest approch t

Builder Pattern

2006-01-28 Thread Jason
Hi I really need an example of a builder pattern in python, the closest I could find to something resembling builder was on this thread... http://groups.google.co.uk/group/it.comp.lang.python/browse_thread/thread/44f79c1def2583ca/200adefeefa5f3fa?lnk=st&q=design+pattern+builder+python+-build&rnum=

Re: Data Crunching and Charting....

2006-01-28 Thread [EMAIL PROTECTED]
Thanks for the response. I did look at the plot class for wxpython and that looks worth checking out too. I really just need to plot the data, optionally print, and save each as an image. Sounds like from what you've done it is alot faster than what Im doing now. Thanks again. -- http://mail.pyt

Using bytecode, not code objects

2006-01-28 Thread Fabiano Sidler
Hi folks! I'm looking for a way to compile python source to bytecode instead of code-objects. Is there a possibility to do that? The reason is: I want to store pure bytecode with no additional data. The second question is, therefore: How can I get the correct values for a given bytecode, such as

a!k ***Hot stuff - check this out !!! a!k

2006-01-28 Thread tinman4
http://www.kaneva.com/checkout/stream.aspx?assetId=2017&free=0 -- http://mail.python.org/mailman/listinfo/python-list

Re: Data Crunching and Charting....

2006-01-28 Thread Robert Kern
Mr BigSmoke wrote: > Hi Tom. > > I had more or less the same problem about 1 year and a half ago... > Since then i've tried either Matplotlib and chaco. I've started using > matplotlib but for some features reason i've decided to use only chaco. > Chaco is really cool but has some neg. points: > -

Re: ANN: SPE 0.8.2.a Python IDE: configure styles, interactive terminals & ubuntu

2006-01-28 Thread dimitri pater
Hi,From: http://www.serpia.org/spe switching to http://www.serpia.org/sorry"""please enable _javascript_ in your browser to visit serpia.orgif you think that sucks, please contact me about it if not, enable _javascript_ and click here"""If you would like to know how much people find, it sucks, thi

Re: Calling DLL with several data fields in output params

2006-01-28 Thread Peter Hansen
Java script Dude wrote: > I basically need to write a script that will make calls to a DLL and > parse the return result for API calls that consist of several data > fields in the input and output parameters. > > [Questions] > [q1] Is ctypes the right Python library to use for this interaction. >

Re: Builder Pattern

2006-01-28 Thread Alex Martelli
Jason <[EMAIL PROTECTED]> wrote: > Hi > > I really need an example of a builder pattern in python, the closest I > could find to something resembling builder was on this thread... > http://groups.google.co.uk/group/it.comp.lang.python/browse_thread/threa d/44f79c1def2583ca/200adefeefa5f3fa?lnk=st

Re: Decoupling the version of the file from the name of the module.

2006-01-28 Thread Peter Hansen
Roy Smith wrote: > [EMAIL PROTECTED] wrote: > >>Now suppose I have make a new version with __version__ = 1.1. What >>shall I call this file and (I don't want to overwrite the old file if I >>need to go back to it)? > > Stop everything right now and get yourself some kind of version control > sys

Re: textvariable help

2006-01-28 Thread swisscheese
Thanks - actually I have some of those books on the way from amazon. The first couple of days with a new language are always the hardest! -- http://mail.python.org/mailman/listinfo/python-list

A new French Python Book

2006-01-28 Thread Tarek Ziadé
Hello, I would like to annouce here a new book for French Python programmers: "Programmation Python" at Eyrolle's It contains, beside a syntax review and a presentation of builtins and some modules from the standard library -- yes nothing very new here, but my prompt examples are very funny--, 

Re: Calling DLL with several data fields in output params

2006-01-28 Thread Java script Dude
>Why wouldn't you just use the target DLL that you already have? Still in the process of getting the software from the vendor. However, I have had luck in playing around with win32 api and am now getting the hang of using ctypes. Looks like I am going down the Python road. Thanks for the info :

Re: Placing graphics & text on printed page - jan06call.jpg (0/1)

2006-01-28 Thread eric.howland
Michael Galvin wrote: > I am trying to use Python to send to the printer a calender filled > with a mix of text and simple graphics. I want to draw on the printed > page something like a table with 6 rows and 7 columns to represent a > calendar. I want to place text precisely within those boxes o

Re: Calling C++ function from python script

2006-01-28 Thread Pankaj
See, i tell u, nothing is difficult in this world. I achieved the thing which i was asking for. Thanks for the advice. I used this paper: http://www.swig.org/tutorial.html for creating python modules from C code. Which is what i needed. In order to interface both things, we need convert atleas

Re: Calling C++ function from python script

2006-01-28 Thread Pankaj
One small thing was incorrect there. gcc -c TestCase.c TestCase_wrap.c -I /usr/include/python2.2/ This include path is required for Python.h file -- http://mail.python.org/mailman/listinfo/python-list

Re: SLUT distibution mangled?

2006-01-28 Thread Paul McGuire
"Paul McGuire" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > "Ido Yehieli" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > > So I can't run SLUT on windows then? > > > Well, here's what I did (I'm running on WinXP). > > 1. Opened up slut.zip with a text editor (used

Re: Problem with odbc (pywin32) and unicode

2006-01-28 Thread Frank Millman
Diez B. Roggisch wrote: > > Unicode is one of those grey areas that I know I will have to try to > > understand one day, but I am putting off that day as long as possible! > > I suggest you better start right away instead of stumbling over it all the > time. The most problems in that field don't c

Re: Using bytecode, not code objects

2006-01-28 Thread Raymond Hettinger
[Fabiano Sidler] > I'm looking for a way to compile python source to bytecode instead of > code-objects. Is there a possibility to do that? The reason is: I want > to store pure bytecode with no additional data. > > The second question is, therefore: How can I get the correct values > for a given b

newbie: working iwth list of tuples

2006-01-28 Thread falcon
Hi All, I am fairly new to Python (less than a week). My goal is to write a small prototype of a database. Rather than build it using the typical method where one provides selection, projection, aggregation, union, intersection, etc. functions, I would like to do it in a more 'functional' style (

Re: newbie: working iwth list of tuples

2006-01-28 Thread Paul Rubin
"falcon" <[EMAIL PROTECTED]> writes: > I didn't find any examples of using idioms from functional programming > beyond basic explanation of reduce and map (I have a couple of Haskell > and ML books, but I know those languages even less than Python). The book you really want is SICP, http://mitpre

Re: newbie: working iwth list of tuples

2006-01-28 Thread falcon
I forgot to add that I passing a tuple of functions to the reduce function but apparently that is not allowed. My guess was that a tuple made up of individual (simple) functions might be easier to manipulate programatically than a function which has to know the structure of a list. (My test code)

Re: newbie: working iwth list of tuples

2006-01-28 Thread Paul Rubin
"falcon" <[EMAIL PROTECTED]> writes: > I forgot to add that I passing a tuple of functions to the reduce > function but apparently that is not allowed. My guess was that a tuple > made up of individual (simple) functions might be easier to manipulate > programatically than a function which has to

Re: newbie: working iwth list of tuples

2006-01-28 Thread Raymond Hettinger
[falcon] > I am fairly new to Python (less than a week). My goal is to write a > small prototype of a database. Rather than build it using the typical > method where one provides selection, projection, aggregation, union, > intersection, etc. functions, I would like to do it in a more > 'function

Re: Python vs C for a mail server

2006-01-28 Thread Dan Lowe
On Jan 28, 2006, at 8:39 PM, Dennis Lee Bieber wrote: > On Sat, 28 Jan 2006 18:03:56 +1100, Steven D'Aprano said: >> >> Google is your friend. The first four mail servers listed are, in >> order: >> >> sendmail >> postfix >> Microsoft Exchange >> qmail >> > Dig a bit deeper, and exim migh

<    1   2