a some python directories laying around from an odd svn
installation or something...
Thanks again!
From: Fabio Zadrozny
To: Joshua Jodrey
Cc: "python-list@python.org"
Sent: Friday, December 16, 2011 12:57 PM
Subject: Re: Python Interpreter Error
It seems you have a version of Python 2.5 in your system and when
starting up Python 3.2.2 it's getting things from 2.5 (this would
probably also happen on the command line).
The usual suspect is that you defined a PYTHONROOT variable which is
pointing to Python 2.5 and not to the python you're us
On 01/-10/-28163 02:59 PM, nair rajiv wrote:
Hi,
I was exploring python. I wanted to know more about the python
interpreter i.e the technical details of how it has been written. If I am
directed
to the code that also will be fine. The implementation of python data
structures lists, tuples and d
Fabio Zadrozny wrote:
Further, I have an accounting software which was previously in java, but
now in python and the performance gain is ausom.
Yes it depends on how we write the code but comparing the 2 at least at
the middle layer and front-end (pygtk) python is faster than java.
Infact I am m
> Further, I have an accounting software which was previously in java, but
> now in python and the performance gain is ausom.
>
> Yes it depends on how we write the code but comparing the 2 at least at
> the middle layer and front-end (pygtk) python is faster than java.
> Infact I am most certain t
Tim Roberts wrote:
> The Python you're thinking of (CPython) is compiled to an intermediate
> language, which is then interpreted by an interpreter loop, somewhat
> remeniscent of Forth. It takes more cycles per instruction to run that
> interpreter loop than it does to run the machine language, b
Ryniek90 wrote:
>
>Standard Python interpreter's implementation is written in C language. C
>code while compilation, is compilled into machine code (the fastest
>code). Python code is compiled into into byte-code which is also some
>sort of fast machine code. So why Python interpreter is slower
On Mon, 2009-04-20 at 20:12 +0100, Tim Wintle wrote:
>
> I can't remember Java properly, but...
>
> Firstly, speed will depend on what you're writing. I dont' actually know
> how much slower python is, but I'm sure there are some things that run
> faster in python.
>
I know many instences which
On Sun, 2009-04-19 at 18:11 +0200, Ryniek90 wrote:
> Hi.
>
> Standard Python interpreter's implementation is written in C language. C
> code while compilation, is compilled into machine code (the fastest
> code). Python code is compiled into into byte-code which is also some
> sort of fast mach
Hello
I'm not expert in low level languages, but I'd say that Python and Java
are "compiled" to bytecodes of similar level. The difference lies in the
information contained in those bytecodes : java is statically typed, so
attribute access and other basic operations are rather quick, allowing
I don't mean to start a flame war, but a productive debate will be
wonderful. I have been writing heavy applications in java for a few
years untill recent past.
My experience is that python is not just fast but also zippy and smooth
when it comes to running the applications.
Infact I have a coupl
On Dec 26, 2:52 am, Scott David Daniels wrote:
> Chris Rebert wrote:
> > On Thu, Dec 25, 2008 at 3:32 PM, Gandalf wrote:
> >> I use WX gui so the user doesn't actually need it, Is their any way to
> >> hide it?
>
> > Make sure your Python program is run by pythonw.exe as opposed to python.exe
> >
Chris Rebert wrote:
On Thu, Dec 25, 2008 at 3:32 PM, Gandalf wrote:
I use WX gui so the user doesn't actually need it, Is their any way to
hide it?
Make sure your Python program is run by pythonw.exe as opposed to python.exe
pythonw.exe exists specifically for the purpose of suppressing the D
On Thu, Dec 25, 2008 at 3:32 PM, Gandalf wrote:
> I use WX gui so the user doesn't actually need it, Is their any way to
> hide it?
Make sure your Python program is run by pythonw.exe as opposed to python.exe
pythonw.exe exists specifically for the purpose of suppressing the DOS
Box on Windows.
On Aug 12, 10:06 am, Wojtek Walczak
<[EMAIL PROTECTED]> wrote:
>
> And keep in mind that reload() is removed in Py3k. Hope this helps.
It's not gone; it's just renamed to imp.reload.
>
> --
> Regards,
> Wojtek Walczak,http://www.stud.umk.pl/~wojtekwa/
--
http://mail.python.org/mailman/listinfo/py
On Aug 12, 7:46 pm, "Calvin Spealman" <[EMAIL PROTECTED]> wrote:
> The best answer is: Don't do that!
>
> That isn't how you test things. Write test scripts, probably using the
> unittest framework. You'll save yourself time and trouble having
> easily reproducible tests. Many people suggested relo
The best answer is: Don't do that!
That isn't how you test things. Write test scripts, probably using the
unittest framework. You'll save yourself time and trouble having
easily reproducible tests. Many people suggested reload(), but you
should know it is dangerous. It can have results you don't e
Alexandru Mosoi wrote:
> I'm using python's interpreter's to run various commands (like a
> normal shell). However if sources are modified changes are not
> reflected so I have to restart interpreter. Is there any way to avoid
> restarting this?
Other gave you advice on how to - partially - achi
Dnia Tue, 12 Aug 2008 07:58:52 -0700 (PDT), [EMAIL PROTECTED] napisa�(a):
>> I'm using python's interpreter's to run various commands (like a
>> normal shell). However if sources are modified changes are not
>> reflected so I have to restart interpreter. Is there any way to avoid
>> restarting this
On Tue, Aug 12, 2008 at 10:49 AM, Alexandru Mosoi <[EMAIL PROTECTED]> wrote:
> I'm using python's interpreter's to run various commands (like a
> normal shell). However if sources are modified changes are not
> reflected so I have to restart interpreter. Is there any way to avoid
> restarting this?
On Aug 12, 9:49 am, Alexandru Mosoi <[EMAIL PROTECTED]> wrote:
> I'm using python's interpreter's to run various commands (like a
> normal shell). However if sources are modified changes are not
> reflected so I have to restart interpreter. Is there any way to avoid
> restarting this?
>
> example:
FWIIW,
On my stock Ultra 20 / Solaris 10 / Opteron box, python, idle, etc.
just run fine provided /usr/sfw/bin is in your PATH environment
variable. That is Python 2.3.3, however.
In addition, I installed the Python 2.4.3 build for Solaris from
ActiveState and python, idle, etc. run without any
> I would try to use the python executable located in /usr/bin if it is
> exists, otherwise use the python executable in /usr/sfw/bin.
>
> casevh
lordy lord, is that where it was. i just found it now. i had been
thinking that idle was the name of the python interpreter, not just the
IDE, hence m
> > /usr/bin/python
> not found
>
> /usr/lib/python2.4/idlelib/idle.py
> /usr/sfw/python2.3/idlelib/idle.py gives
>
> 'there is no action associated with "idle.py"'
> configure gnome to associate application?
>
> click yes:
> edit file type window pops up.
> program to run menu is empty.
> browse i
[EMAIL PROTECTED] wrote:
> > i think i've tracked down the equivalent files on my pc. one opens the
> > interpreter in a white-backed text editor, the other at the
> > black-backed command prompt. i have equivalent files of the same size
> > on the workstation, which must be the same. does anyone k
> i think i've tracked down the equivalent files on my pc. one opens the
> interpreter in a white-backed text editor, the other at the
> black-backed command prompt. i have equivalent files of the same size
> on the workstation, which must be the same. does anyone know why i'm
> getting 'there is n
sam> does anyone know why i'm getting 'there is no installed viewer
sam> capable of displaying the document'?
You probably need to associate files having .py file extensions with the
Python interpreter. You've given no indication of the environment you're
using other than "Solaris 10".
to update:
i think i've tracked down the equivalent files on my pc. one opens the
interpreter in a white-backed text editor, the other at the
black-backed command prompt. i have equivalent files of the same size
on the workstation, which must be the same. does anyone know why i'm
getting 'there is
thx ian. exactly what I wanted.
best,
alex.
--
http://mail.python.org/mailman/listinfo/python-list
In message <[EMAIL PROTECTED]>,
Alexandre Guimond <[EMAIL PROTECTED]> writes
>Hi i was wondering if there already existed a simple python interpreter
>widget for tkinter? Basically, i would like to be able to lauch a
>python interpreter in a seperate window from my tkinter app for
>debugging purpo
Corey Carter <[EMAIL PROTECTED]> wrote:
> I am interested in creating programs in python. I am not sure how I would
> run the programs on other machines without having to install python on each
> machine. Is there a way to run python programs on machines without the
> python interpreter?
There a
g.franzkowiak wrote:
> Hi everybody,
>
> my interest is for the internals of the Python interpreter.
>
> I've used up to now FORTH for something and this indirect interpreter is
> very smart.
> --- ASM ---
>
> Where can I find information
In <[EMAIL PROTECTED]>, g.franzkowiak wrote:
> my interest is for the internals of the Python interpreter.
>
> I've used up to now FORTH for something and this indirect interpreter is
> very smart.
> --- ASM ---
>
> NEXT: LODSW
"g.franzkowiak" <[EMAIL PROTECTED]> writes:
> Where can I find informations like this for Python ?
"Use the force, read the source". Python's interpreter is more like a
big switch statement on bytecodes, though.
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
>>Steve Holden wrote:
>>Consider:
>
>
> >>> a = {1:'one'}
> >>> b = {2:'two'}
> >>> c = {1:'one'}
> >>> a is c
> False
> >>> a in [b, c]
> True
> >>>
>
>
>>What would you have Python do differently in these circumstances?
>
>
> You mean: What i would do i if i w
> Steve Holden wrote:
>Consider:
>>> a = {1:'one'}
>>> b = {2:'two'}
>>> c = {1:'one'}
>>> a is c
False
>>> a in [b, c]
True
>>>
>What would you have Python do differently in these circumstances?
You mean: What i would do i if i was the benevolent dictator ?
I would make a distinction bet
[EMAIL PROTECTED] wrote:
> I understand this, Steve.
> I thought the _cmp_ method was a helper for sorting purposes. Why is it
> that a membership test needs to call the __cmp__ method?
Can you suggest another way to test for set membership, given that
instances aren't singletons? The only way to
[EMAIL PROTECTED] wrote:
> No doubt you're right but common sense dictates that membership testing
> would test identity not equality.
what does "common sense" have to say about this case:
>>> L = ("aa", "bb", "cc", "dd")
>>> S = "a" + "a"
>>> L
('aa', 'bb', 'cc', 'dd')
>>> S
'aa'
>>> S in L
# T
[EMAIL PROTECTED] wrote:
> No doubt you're right but common sense dictates that membership testing
> would test identity not equality.
> This is one of the rare occasions where Python defeats my common sense
But object identity is almost always a fairly ill-defined concept.
Consider this (Python
No doubt you're right but common sense dictates that membership testing
would test identity not equality.
This is one of the rare occasions where Python defeats my common sense
;-(
Alain
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
> In fact, i want to sort the list based on the 'allocated attribute' and
> at the same time, test membership based on the id attribute.
> __cmp__ logically implies an ordering test
really?
http://dictionary.reference.com/search?q=compare
com·pare
v. com·pare
[EMAIL PROTECTED] wrote:
> Sorry Fredrik but I don't understand. Just comment out the assert and
> you have different results depending on whether an unrelated sort
> function is defined.
> This seems weird to me !
code snippet:
> from random import choice
> class OBJ:
> def __init__(self,i
[EMAIL PROTECTED] wrote:
> In fact, i want to sort the list based on the 'allocated attribute' and
> at the same time, test membership based on the id attribute.
> __cmp__ logically implies an ordering test, not an identity test. These
> two notions seems to be confounded in python which is unfortu
On Fri, 2005-10-07 at 10:33, [EMAIL PROTECTED] wrote:
> In fact, i want to sort the list based on the 'allocated attribute' and
> at the same time, test membership based on the id attribute.
> __cmp__ logically implies an ordering test, not an identity test. These
> two notions seems to be confound
For this, you can also define the __eq__ method, which will be
preferred to __cmp__ for equallity tests while still using __cmp__ for
searching / comparisons.
--
http://mail.python.org/mailman/listinfo/python-list
In fact, i want to sort the list based on the 'allocated attribute' and
at the same time, test membership based on the id attribute.
__cmp__ logically implies an ordering test, not an identity test. These
two notions seems to be confounded in python which is unfortunate. Two
objects could have the
[EMAIL PROTECTED] wrote:
> Why is it that a membership test needs to call the __cmp__ method?
because the membership test has to check if the tested item is a member
of the sequence. if it doesn't do that, it's hardly qualifies as a membership
test. from the reference manual:
For the list a
Your __cmp__ method will always return 0, so all objects will be equal
when you add the method, as Simon and Steve pointed out. The result is
all objects will pass the test of being a member of excluded.
If you do not add a __cmp__ method objects will be compared on identy -
call the id() function
Your __cmp__ method will always return 0, so all objects will be equal
when you add the method, as Simon and Steve pointed out. The result is
all objects will pass the test of being a member of excluded.
If you do not add a __cmp__ method objects will be compared on identy -
call the id() function
[EMAIL PROTECTED] wrote:
> Sorry Fredrik but I don't understand. Just comment out the assert and
> you have different results depending on whether an unrelated sort
> function is defined.
>
> This seems weird to me !
not if you look at what it prints.
(if it seems weird to you that 0 equals 0, i
I understand this, Steve.
I thought the _cmp_ method was a helper for sorting purposes. Why is it
that a membership test needs to call the __cmp__ method?
If this isn't a bug, it is at least unexpected in my eyes.
Maybe a candidate for inclusion in the FAQ?
Thank you for answering
Alain
--
http:/
[EMAIL PROTECTED] wrote:
> Sorry Fredrik but I don't understand. Just comment out the assert and
> you have different results depending on whether an unrelated sort
> function is defined.
> This seems weird to me !
>
Perhaps you don't understand what's going on. The test
obj in excluded
is
Sorry Fredrik but I don't understand. Just comment out the assert and
you have different results depending on whether an unrelated sort
function is defined.
This seems weird to me !
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
> I came accross what i think is a serious bug in the python interpreter.
> Membership testing seems not to work for list of objects when these
> objects have a user-defined __cmp__ method.
it does not work if they have *your* __cmp__ method, no. if you add
a print stat
There is definitely a bug.
Maybe the follownig snippet is more clear:
class OBJ:
def __init__(self,identifier):
self.id=identifier
self.allocated=0
#def __cmp__(self,other):
# return cmp(other.allocated,self.allocated)
mylist=[OBJ(i) for
[EMAIL PROTECTED] wrote:
> Hello,
>
> I came accross what i think is a serious bug in the python interpreter.
>
> Membership testing seems not to work for list of objects when these
> objects have a user-defined __cmp__ method.
> It is present in Python 2.3 and 2.4. I don't know about other versi
Why would it be a bug? You've made it so that every instance of OBJ is
equal to every other instance of OBJ. The behaviour is as expected.
--
http://mail.python.org/mailman/listinfo/python-list
yaffa a écrit :
> hey folks i get this error: Python interpreter error: unsupported
> operand type(s) for |:
>
> when i run this line of code:
>
> for incident in bs('tr', {'bgcolor' : '#ee'} | {'bgcolor' :
> 'white'} ):
>
> any idea what i'm doing wrong here?
yes: trying to do a bitwis
Szabolcs Nagy a écrit :
> you cannot use | with two dict (dict has no .__or__ method)
>
> what are you trying to do?
>
read the post: "need help with python syntax"...
(posted one hour sooner)
--
http://mail.python.org/mailman/listinfo/python-list
you cannot use | with two dict (dict has no .__or__ method)
what are you trying to do?
--
http://mail.python.org/mailman/listinfo/python-list
On 1 May 2005 at 6:18, Engineer wrote:
> The security 'droids have decided that since the MS Office Suite is a
> "standard" application then software written in MS Office VBA must be
> "safe." Any other development environments (such as Java, Perl,
> Cygwin) are "unsafe" and can't be installed.
On Sun, 01 May 2005 06:18:27 -0700, Engineer wrote:
> The security 'droids have decided that since the MS Office Suite is a
> "standard" application then software written in MS Office VBA must be
> "safe."
"Melissa". (Google hint: "Virus".)
Given the brazen stupidity demonstrated by these decisio
Hi !
VBA is at the end of his lifetime. The next MS-Office will not have VBA
(because dotNet).
You should really adopt Python.
@-salutations
--
Michel Claveau
--
http://mail.python.org/mailman/listinfo/python-list
I don't think this is going to happen.
Applications that drive MS Office applications merely call COM
objects that perform the actual operations. It doesn't really
matter what language calls the COM objects, they are the same
objects all the time. If they don't like the "installation"
of the Pyt
George Yoshida wrote:
> Rakesh wrote:
>
> > To quote a much smaller trimmed-down example, here is how it looks
> > like:
> > ## ---
> > # Entry Point to the whole program
> > ## ---
> > def main():
> >
Rakesh wrote:
> To quote a much smaller trimmed-down example, here is how it looks
> like:
> ## ---
> # Entry Point to the whole program
> ## ---
> def main():
> mylist = GenerateList()
> minnumber = min
To quote a much smaller trimmed-down example, here is how it looks
like:
<-->
import sys
##
##
def GenerateList():
array = ' '
for i in xrange(10):
array = (array, i)
return array
## --
67 matches
Mail list logo