I am writing a web application for mod_python that catalogs my home
(book) library. For now, I am using the Python dbm module to store
string representations of mod_python's req.form (using the
mod_python.publisher handler) using unique IDs as keys. In the .db
file, there is a key 'next' that holds
Hi. I am trying to embed an interactive interpreter in a C++
application. I need to capture the output of int
PyRun_InteractiveOne(FILE *fp, const char *filename). Is redirecting
sys.stdout and sys.stderr after initializing the interpreter the best
way to do this?
Thanks,
Ryan
--
http://mail.pyt
I have a schedule of times in the future that I want to display in a
timezone the user sets. There is a useful module
http://www.purecode.com/~tsatter/python/README.txt (at that URL) with
a function that takes seconds from the epoch and a time zone and
returns what is basically a datetime object.
I have a schedule of times in the future that I want to display in a
timezone the user sets. There is a useful module
http://www.purecode.com/~tsatter/python/README.txt (at that URL) with
a function that takes seconds from the epoch and a time zone and
returns what is basically a datetime object.
On Oct 17, 1:52 pm, Steven D'Aprano <[EMAIL PROTECTED]
cybersource.com.au> wrote:
> On Wed, 17 Oct 2007 12:20:06 +, ryan k wrote:
> > I have a schedule of times in the future that I want to display in a
> > timezone the user sets. There is a useful module
> >
I'm trying to text wrap a string but not using the textwrap module. I
have 24x9 "matrix" and the string needs to be text wrapped according
to those dimensions. Is there a known algorithm for this? Maybe some
kind of regular expression? I'm having difficulty programming the
algorithm. Thanks,
Ryan
e. This connection is not visible on any external
interface and no data is sent to or received from the Internet."""
print wrap_text(sample_text, 24)
It doesn't even run but when I go through it interactively it seems
okay. Once again, any help is appreciated.
On Feb 28, 7:06
That works great but I need to replace the newlines with 24-(the index
of the \n) spaces.
On Feb 28, 8:27 pm, [EMAIL PROTECTED] wrote:
> On Feb 28, 4:06 pm, "Ryan K" <[EMAIL PROTECTED]> wrote:
>
> > I'm trying to text wrap a string but not using the textwra
Hello. I have a string like 'LNAME
PASTA ZONE'. I want to create a list of those words and
basically replace all the whitespace between them with one space so i
could just do lala.split(). Thank you!
Ryan Kaskel
--
http://mail.python.org/mailman/listinfo/python-list
On Jan 23, 2:04 pm, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote:
> On Wed, 23 Jan 2008 10:50:02 -0800, ryan k wrote:
> > Hello. I have a string like 'LNAME
> > PASTA ZONE'. I want to create a list of those words and
> > basical
I am taking a database class so I'm not asking for specific answers.
Well I have this text tile:
http://www.cs.tufts.edu/comp/115/projects/proj0/customer.txt
And this code:
# Table and row classes used for queries
class Row(object):
def __init__(self, column_list, row_vals):
print l
On Jan 23, 2:53 pm, John Machin <[EMAIL PROTECTED]> wrote:
> On Jan 24, 6:17 am, ryan k <[EMAIL PROTECTED]> wrote:
>
> > I am taking a database class so I'm not asking for specific answers.
> > Well I have this text tile:
>
> >http://www.cs.tufts.edu/com
On Jan 23, 3:02 pm, John Machin <[EMAIL PROTECTED]> wrote:
> On Jan 24, 6:57 am, ryan k <[EMAIL PROTECTED]> wrote:
>
> > So yea i will just have to count dashes.
>
> Read my lips: *you* counting dashes is dumb. Writing your code so that
> *code* is counting dash
On Jan 23, 5:37 pm, Steven D'Aprano <[EMAIL PROTECTED]
cybersource.com.au> wrote:
> On Wed, 23 Jan 2008 11:05:01 -0800, Paul Rubin wrote:
> > ryan k <[EMAIL PROTECTED]> writes:
> >> Hello. I have a string like 'LNAME
> >> PASTA
On Jan 23, 5:37 pm, Steven D'Aprano <[EMAIL PROTECTED]
cybersource.com.au> wrote:
> On Wed, 23 Jan 2008 11:05:01 -0800, Paul Rubin wrote:
> > ryan k <[EMAIL PROTECTED]> writes:
> >> Hello. I have a string like 'LNAME
> >> PASTA
On Jan 23, 6:30 pm, John Machin <[EMAIL PROTECTED]> wrote:
> On Jan 24, 9:50 am, ryan k <[EMAIL PROTECTED]> wrote:
>
> > Steven D'Aprano, you are a prick.
>
> And your reasons for coming to that stridently expressed conclusion
> after reading a posti
If I have a cElementTree.ElementTree (or the one from the Standard
Library), can I use lxml's validation features on it since it
implements the same ElementTree API?
Thanks,
Ryan
--
http://mail.python.org/mailman/listinfo/python-list
Greetings,
In order to avoid circular imports, I have a class that I want to
improve upon:
Class GenerateMenuXhtml(threading.Thread):
"""
Subclasses a threading.Thread class to generate a menu's XHTML in
a separate
thread. All Link objects that have this menu associated with it
are ga
Thanks for your help Peter.
I'm thinking that perhaps this isn't a circular import and that I
don't understand importing. Here is a better explanation of my case (I
am using Django):
I have file x.py that declares classes A, B, C.
There is also a file y.py that contains two methods T, U and the
Okay so below is the acutal code. I am starting to think there is no
reason why I can't install the post_save signal in signals.py itself
and thereby avoid this issue entirely.
models.py:
class Link(CommonAbstractModel):
...
class Menu(CommonAbstractModel):
class StaticPage(CommonA
Thank you for your replies. I have factored out the dependency and
everything is solved.
Cheers,
Ryan
--
http://mail.python.org/mailman/listinfo/python-list
21 matches
Mail list logo