@# Quotes DB     useful, funny, interesting





Google
 
Web www.quotesdb.info
Undernet  |  EFnet  |  Quakenet  |  Freenode  |  Dalnet  |  Ircnet  |  Galaxynet
Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16



Comments:

<0> night
<1> thanks for your response jessie
<1> I'll be taking compilers next semester perhaps
<0> not a problem
<2> Can someone help me grab a piece of code that I'm having trouble isolating?
<3> so no one tried that before?
<4> jessie: UQ
<4> jessie: uq.edu.au
<0> ah I understood uni to be the abreviation for your school...would have been quite a coincidence if we went to the same school
<5> uni is short for university =)
<4> jessie: sorry, yeah, australianism. we call tertiary institutions that issue graduate and postgraduate degrees, 'univesities', which gets shortened to 'uni'
<5> we do the same in .uk
<4> jessie: 'college' means, 'on site residence for students', and 'school' means 'mandatory education institution for persons between 5 and 18 years'
<5> so you don't have say "School of computer science" ?
<4> stain: sometimes.
<4> stain: but in UQ's case, it's the school of information technology and electrical engineering.



<4> stain: no one says, "What school do you go to"
<6> ok, are python site-packages installed in the same places on all distros?
<5> Jerub: of course not!
<4> when they mean something to do with uni education.
<4> yonkeltron: no
<4> yonkeltron: under the HURD, they're installed in /lib/python2.4/site-packages/
<4> yonkeltron: on some platforms, python is installed under /opt/ too
<4> http://mfrost.typepad.com/cute_overload/images/heylerhe.jpg
<5> in OS X it is /System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages
<6> Jerub: the reason i ask is because i am making an autopackage for an application that needs modules to be installed. i need to know where to put them
<5> yonkeltron: just use the normal setup.py with distutils
<4> yonkeltron: use python setup.py
<4> stain: that depends, if you're using fink under OSX, it's /sw/lib/python2.3/site-packages
<6> stain: tried to..didn't work
<6> Jerub: tried to do that and it failed
<5> Jerub: yeah.. or it could be /Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-packages =)
<3> plz plz someone answer my question ... has anyone used th CGIHTTPServer module????
<3> :(
<6> __hAYnEs: nope
<3> :(
<7> mouaou i looks for a bug for 10hours on a udp connection before finding out that i was listening on the same port used by azureus udp a while ago. in fact it was just other azureus apps sending me packet.
<7> just wanted to share :)
<4> zorglu1: here's a tip. use ethereal and tcpdump.
<7> well, you know my legitimate packet contains only data that appears random, and azureus dht packet too
<7> but it is a good advice in a general case :)
<4> zorglu1: UDP has sequence numbers, doesn't it ?
<7> nope
<8> where to find a documentation for network programmming (socket) in python?>
<7> but in practice i didnt look at network dump :)
<4> TCP/IP Illustrated, Volume 1, W. Richard Stevens
<7> and if i did, i would have noticed :) once again due to my particular case. in my case my legitimate packets come from the lan and azureus one from the public internet
<7> google 'socket programming python' first link
<4> a_staff: what are you writing?
<8> Jerub just learn networking and socket programming..
<8> thanks
<9> hi
<9> has anybody using funkload?
<10> python/vim question.. I'm running a Python course today and want to know what to tell vim users, regarding making it Python-friendly. Any suggestions?
<11> strib: look at http://www.vim.org/scripts/script_search_results.php?keywords=python&script_type=&order_by=rating&direction=descending&search=search
<6> is python GLP2?
<10> prinewgirl: mmm, I think they'll just want a single line they can put into their .vimrc and have Everything Work (tm).
<11> strib: do you want look my .vimrc?
<10> prinewgirl: if it would be appropriate, yes please.
<10> Pop it in a pastebin for me?
<11> strib: wait a minute please, because the comments in this file are in portuguese ;)
<10> Hehe, no hurry.
<10> The course isn't for another 4 hours.
<7> yonkeltron: nope, it is some kind of bsd i think. the python.org explains it
<6> zorglu1: thanx
<11> strib: my english is very strong, but its "understadable" , i mean
<12> yonkeltron: you can also use license()
<13> hey
<13> how can i add items to a dict?
<10> prinewgirl: that shouldn't be a problem.
<10> cadu: so you have a dict d.. d['foo'] = 'bar'
<14> cadu: d[key] = value
<13> yacc: thanks :) silly me!"
<15> hi there. is there any alternative to 'movpy' for installing python on a usb stick?
<16> i created with swig a python interface for some 3rd-party c lib. is there a way to provide the imported functions with docstrings? i dont want to touch the (by swig generated) .py file, because it could easily get overwritten if someone reruns swig
<17> pfote: overwrite the __doc__ attribute of each object you want to provide documentation for



<18> Excuse my stupid question but "subsequent to the call to Py_Initialize()" is that before or after?
<4> after the call.
<18> Jeah.. http://www.answers.com/subsequent&r=67 sorry
<19> I can get my processes PID by using os.getpid(), and the parent ID with os.getppid(), how can I go beyond that? There's no os.getpppid()
<19> I only need it for linux, so it's not a problem if that can't be done cross-platformly.
<20> how can i extract plain text from html page ?
<4> sunubuntu: lynx -dump ? w3m -dump ? beautifulsoup?
<21> Foone: you could execute os.popen("ps " + pid) and parse the result
<22> Foone: well the man pages for getpid and getppid don't mention any useful related calls
<14> pythonologist: or just take a look at /proc/PID/*
<22> Foone: my guess is that 'ps' and other programs use OS-specific syscalls
<20> jerub:no using a sgml or html parser
<19> ps <PID> doesn't give my parent ID
<22> or yeah, they might just look at /proc
<14> teratorn: on linux they usually just read /proc
<20> jerub:HTMLParser cl***
<11> look process pids in /var/run/
<4> sunubuntu: beautifulsoup
<19> /proc/PID/ seems to be doable. Thanks.
<19> heh, whoops. Just realized I need it in the CGI that reports on the app, not the app itself. The CGI is PHP, not python... Sorry to waste your time :)
<20> jerub:thanks man.
<23> Hello! I've understood I can't use python shelve in multiple processes.
<4> pisi: use sqlite instead
<23> what would be another *really simple* way for data storage (from a cgi script)
<4> pisi: sqlite
<23> Jerub: you have a pointer to a really really simple tutorial ?
<22> I'll bet google does
<4> pisi: uhh, pysqlite webpage probably has docs
<16> ah. swig has a docstring feature. nice!
<24> i been getting some weird caching behaviour in apache2 mod_python - i got 2 sites running as separate vhosts in the one apache2 process - very careful about not leaking namespaces - the sites are intermittently serving pages from each other
<4> pisi: essentially sqlite is a file-based database suitable for small programs.
<4> aum: don't use mod_python.
<24> Jerub: is mod_python heavily deprecated?
<4> aum: while you're porting to django or turbogears, you should consider moving to cgi style instead
<4> aum: no, mod_python is poorly maintained ill-thought-through software
<4> for it to be deprecated, it would have to be part of the python project, but it's not, it's part of the apache project.
<24> i might run 'em both under separate processes via SimpleHttpServer, and proxy 'em in thru apache
<4> that's a good idea
<24> feels safest
<25> j #turbogears
<24> i got my own framework, so porting to turbogears would be much harder than just emulating mod_python under SimpleHttpServer
<24> it's just a matter of building something compatible with the the 'req' object that mod_python p***es in
<22> Jerub: not sure about just "small" programs
<4> teratorn: I have this thing where I seperate 'small' from 'big' by thinking, "Does it use more than 4U in the rack"
<4> teratorn: small is anything that's small enough to be run on just one chunky server. big is anything that requires gigabit switches, and a dozen database servers.
<22> Jerub: a useful distinction :)
<13> question: how to add all key:value pairs from dict -a- into -b-
<22> cadu: d.update()
<22> d.update(d2)
<13> this adds all k:v of d2 into d? nice :)
<26> when writing a python module in C, how do you import the compiled object files and use them?
<26> eg python foo.py build creates foo.so, how do you use the shared object as a python module, import it etc?
<18> nima: it needs to be libfoo.so in that case
<27> Greetings, is there a way to change Python's user agent?
<26> odl, ok and then what do you do with the .so?
<18> nima: If the libfoo.so is in the path you import it by import foo
<26> really? I get garble...
<26> hmmm, perhapse not =) Thankyou odl
<27> ...is it even possible to change the "user agent" in urllib / urllib2 ?
<26> urllib2 can
<27> ah, found thanks
<26> request.add_header('User-Agent', OpenAnything/1.0 +http://something.org/')
<28> Can anyone tell me where to 'os' module's source is placed at?
<28> *where the
<16> Freso: should be where your python root is, usually /usr/lib/python2.3 (your version may vary)
<28> pfote: Not my locally installed one. :)
<28> pfote: In SVN repos or whereever it is.
<29> import imp: imp.find_module('os')
<29> import imp; imp.find_module('os') *
<28> There we go - http://svn.python.org/view/python/trunk/Lib/os.py
<28> Thank you. :)
<30> hi a;;
<30> all


Name:

Comments:

Please enter the result of the sum 63 + 46 (to avoid spam):






Return to #python
or
Go to some related logs:

ubuntu changing scanner permissions
#perl
#css
mysql hibernate_sequence
bind 9 +init script -chroot
gnome ubuntu tape backup
centos yum [Errno -1] header
make link in ubuntu
inurl:gentoo No matching Device section for instance
sendmail.mc FC compile how to



Home  |  disclaimer  |  contact  |  submit quotes