Re: oop in python
novice schrieb: > class Point: >def _func_that_we_want_(self): > return ... return self.__class__.__name__ http://docs.python.org/ref/types.html#l2h-109 -- http://mail.python.org/mailman/listinfo/python-list
Re: viewcvs 1.0 dev
Robin Becker schrieb: > Does anyone know the status of the svn handling version of viewCVS. http://viewvc.tigris.org/index.html -- http://mail.python.org/mailman/listinfo/python-list
Re: viewcvs 1.0 dev
Robin Becker schrieb: > Uwe Hoffmann wrote: > >> Robin Becker schrieb: >> > unfortunately there's no mention of svn handling there and the files > only show 0.9[.x] versions. > at least you can get the sources via subversion and have a look at the INSTALL file (e.g. http://viewvc.tigris.org/source/browse/viewvc/trunk/INSTALL?rev=1213&view=auto&content-type=text/vnd.viewcvs-markup ) -- http://mail.python.org/mailman/listinfo/python-list
Re: cx_Oracle question
Richard Schulman schrieb: > > cursor.execute("""select mean_eng_txt from mean > where mean_id=:arg_1""",arg_1) cursor.execute("""select mean_eng_txt from mean where mean_id=:arg_1""",{"arg_1":arg_1}) > Traceback (most recent call last): >File "oracle_test.py", line 7, in ? > cursor.execute('select mean_eng_txt from mean where > mean_id=:arg_1',arg_1) > TypeError: expecting a dictionary, sequence or keyword args -- http://mail.python.org/mailman/listinfo/python-list
Re: Running python from a usb drive
cjl schrieb: > > > I do set pythonpath, see above. > is pythonpath really case insensitive on windows ? -- http://mail.python.org/mailman/listinfo/python-list
Re: Running python from a usb drive
Steve Holden schrieb: > Uwe Hoffmann wrote: > >> cjl schrieb: >> >> >>> >>> I do set pythonpath, see above. >>> >> >> is pythonpath really case insensitive on windows ? > > > Only because the Windows filesystem implements case-insensitive > semantics. This is nothing to do with Python: no, i mean't the name not the content. Is the handling of the env variable pythonpath case insensitive: pythonpath <--> PYTHONPATH. regards uwe -- http://mail.python.org/mailman/listinfo/python-list
Re: find login name of user?
[EMAIL PROTECTED] schrieb: > Is there a function/module to find the login name of the user under > UNIX environment? http://docs.python.org/lib/os-procinfo.html http://docs.python.org/lib/module-pwd.html -- http://mail.python.org/mailman/listinfo/python-list
dependencies on subclassing Extensiontypes: tp_richcompare <--> tp_hash
Hi, i have used Pyrex to build some python Extensionclasses. Now i stumbled over the fact that if a subclass has a __hash__ method the __richcmp__ of the base is not called. # pseudocode class Base: def __richcmp__(): print 'hi' class Immutable(Base): def __hash__(): pass if two instances of Immutable are compared ( e.g. Immutable() == Immutable() ) 'hi' is not printed. Somebody (on pyrex mailing list) showed me that the cpython has this feature. If you look at typeobject.c you see the following sequence: if (type->tp_flags & base->tp_flags & Py_TPFLAGS_HAVE_RICHCOMPARE) { if (type->tp_compare == NULL && type->tp_richcompare == NULL && type->tp_hash == NULL) { type->tp_compare = base->tp_compare; type->tp_richcompare = base->tp_richcompare; type->tp_hash = base->tp_hash; } } That means either all three slots are inherited or no slot at all and only if there is not already one slot set. Does anybody know why there is this strict relationship between type->tp_richcompare and type->tp_hash . I have the feeling that this should avoid some "incompatible" changes of __hash__ or __richcmp__ in the subclass but I have no clear picture (subclass compares equal but has a different hash ? ). regards Uwe -- http://mail.python.org/mailman/listinfo/python-list
Re: Group Membership in Active Directory Query
[EMAIL PROTECTED] schrieb: > ldap_obj = ldap_obj.simple_bind_s('[EMAIL PROTECTED]', > 'password') > > > AttributeError: 'NoneType' object has no attribute 'search_Ext_s' > dummy = ldap_obj.simple_bind_s('[EMAIL PROTECTED]', 'password') or better simply ldap_obj.simple_bind_s('[EMAIL PROTECTED]', 'password') -- http://mail.python.org/mailman/listinfo/python-list