Parth wrote:
I need some help regrading byassing firewalls.My college has internet
aces but it prevents us from dowloading music(*.mp3,*.mid,etc.)from the
net.
Hello everyone,
I need help getting my college degree. I downloaded a hack to bypass
the college internet firewall and the college
[EMAIL PROTECTED] wrote:
which feature of python do you like most?
Duck typing (All I care about is that it quacks, and it doesn't have to
derive from Duck() to do that!)
And decorating (the ability to add attributes to objects on-the-fly, not
the @XXX stuff)
--
Mike Meyer wrote:
This is a well-known phenomenon, having picked up the name bikeshed
something like 40 years ago. Google for bikeshed color.
My favourite bikeshed story:
A colleague just joined his local Primary School council. On the agenda
for his first meeting was that the shelter shed
My current solver does 1 level of backtracking (i.e. constant space, and
bounded time) only, and it has been able to solve every puzzle I've
thrown at it. It's based on the usual logic and book-keeping for the
most part. (It also explains how it comes up with each answer step as
it goes,
François Pinard wrote:
In computer
science, I often saw old concepts resurrecting with new names, and then
mistaken for recent inventions. New ideas are not so frequent...
There are very few problems in Computer Science that cannot be solved
with an additional level of indirection.
--
Hmmm... OK... you forced me into it.
Python uses whitespace
Where C++ uses a brace
New users fret,
But old pros forget -
it quickly all falls into place.
I could go on..
--
http://mail.python.org/mailman/listinfo/python-list
Paul Rubin wrote:
Aldo Cortesi [EMAIL PROTECTED] writes:
Thanks to Paul and Aldo... one more question on the implementation.
Why is the func_closure a tuple of Cells and not just a tuple of
objects? Why the extra level of indirection?
--
http://mail.python.org/mailman/listinfo/python-list
mg wrote:
Is it a bug or a control behavour ? I don't understand ?!?!?!?!...
It's a case of applying different float-to-text rounding in different
situations, on a variable that (even after round()) is not representable
in binary floatingpoint.
print var does one sort of string conversion
Paul Rubin wrote:
def FunctionMaker(avar, func, label):
def callback():
avar.set(label)
func()
return callback
I've seen this idiom a lot and I know _what_ it does. but I can't
work _how_ it does it. How does the name binding work so that avar
Kevin Little wrote:
I want to dynamically add or replace bound methods in a class. I want
I asked a seemingly-unrelated question a week or so ago, and learned
something interesting:
Python 2.3.4 (#2, Jul 12 2004, 12:46:36)
[GCC 3.3] on sunos5
Type help, copyright, credits or license for
Godwin wrote:
But the funny fact is that i want this class to be dynamically
generated at run
time simply from a table name string.
The thing you are looking for is called an object-relational mapper.
try SQLObject http://sqlobject.org/
This is mainly intended to work the other way (i.e.
km wrote:
Is python runtime slow at all aspects when compared to perl ?
And in addition to all that everyone else has said most of this is
startup time. The python interpreter is a fair bit slower to start up
(i.e. does much more at startup time) than the perl one:
lenford$ time
I'm building a class hierarchy that needs to keep as a class variable a
reference to a (non-member) function, so that different subclasses can
use different generator functions. But it seems Python is treating the
function as a member function because the reference to it is in class
scope
Peter Otten wrote:
You are on the right track with staticmethod, but you have to apply it to
fn:
... fn = staticmethod(foo)
Thanks Peter, that's a big help.
I can solve my problem now, but I'm chasing this further in the name of
education, because it seems there is some deep magic
Rex Eastbourne wrote:
def debug(aname, avalue):
print aname, 'is':
pprint.pprint(avalue)
use eval:
def debug(s):
print s, 'is'
pprint.pprint(eval(s))
(it does mean the arg is a string not code..)
On a
slightly different topic, is it also possible to make
J wrote:
I have looked at some of the source code in PyObject_GenericGetAttr and
it turns out that the object has no dictionary. It seens that the
address of the dictionary is computed somehow via tp_dictoffset in the
type object.
I asked this a few months ago..
Basically, you need a
Jeremy Moles wrote:
Or, perhaps, there's even a better way? I'm getting more and more
experienced with the Python/C API, so I don't need a walk-through or
anything. :) Just an experienced recommendation...
Better by far to create a new python type in C that has your struct
inside it and
Tim Roberts wrote:
PyGILState_STATE gil = PyGILState_Ensure();
result = PyEval_CallObject(my_callback, arglist);
PyGILState_Release(gil);
Py_DECREF(arglist);
Py_DECREF(result);
If someone else holds a reference to arglist, then the
Jorgen Grahn wrote:
Emacs and vim are almost always installed, or trivially installable. All I
need to remember is to bring my emacs config file.
And, fortunately, USB pen drives are now big enough to hold it!
--
http://mail.python.org/mailman/listinfo/python-list
Rocco Moretti wrote:
Actually, Google's answer to that question is something called ILOG
CPLEX,
We use this. It's a library / command line tool (not a language) for
doing optimization - linear programming, quadratic programming,
mixed-integer programming etc. Very cool and very, very
[EMAIL PROTECTED] wrote:
I'd like to dynamically find and invoke a method in a Python CGI.
boundmeth = obj.meth # nb: no ()
# stuff.
boundmeth() # call it, with args if needed
--
http://mail.python.org/mailman/listinfo/python-list
Rodrigo Dominguez wrote:
My question is: is there some kind of framework that works with mod_python?
I use and love Albatross, but there are heaps of others. Check the
mod_python FAQ, in particular
http://www.modpython.org/FAQ/faqw.py?req=showfile=faq03.010.htp
--
Mike Meyer wrote:
Unknown. Python relies on the C alloc/free routines for handling
memory. del may immediately free() the memory (I don't know), but that
doesn't mean it gets released to the OS. None of the implementations
of alloc/free I'm aware of ever give the memory back to the OS. They
DJTB wrote:
Hi,
I'm trying to manually parse a dataset stored in a file. The data should be
converted into Python objects.
In addition to what the others have mentioned, this sort of problem is
pretty easy to do with a C coded extension type, if you have (or can
buy/borrow) any C skills.
I wrote:
[snip]
What am I missing?
The fundamental problem is that this:
if (!(ro = PyObject_New(MyIter, MyIterType)))
return NULL;
is really only a malloc() - it doesn't call the tp_new function at all.
This is not really clear in the 2.3 version of the C API document that
I was
One of the cool things about Python is the ability to decorate objects
with random extra members:
class C:
def __init__(self):
self.foo = 0
c = C()
c.bar = 1
I have a class implemented in C using tp_members to specify (read-only)
access to data members in the C struct. I'd like to be
I've had a solid hunt through the (2.3) documentation but it seems
silent on this issue.
I have an problem that would naturally run as 2 threads: One monitors a
bunch of asyncrhonous external state and decides if things are good or
bad. The second thread processes data, and the processing
27 matches
Mail list logo