@Mike - I tend to feel like the effort should be officially sanctioned
in some way, but thanks for offering up a stopgap.
@whit - By "current documentation structure," do you mean inline
documentation? As in, documentation that lives in line with the code?
Where do we go from here? Does anybody e
``sio.getvalue()`` has always been the way to get the contents of a
StringIO "file". ``sio.buff`` is undocumented so who knows what it
might do.
http://docs.python.org/library/stringio.html
On Thu, Dec 2, 2010 at 5:54 PM, snfct...@sacfoodcoop.com
wrote:
> Thanks, Ian - that worked!
>
> @Marco:
Thanks, Ian - that worked!
@Marco: Thanks for the alternative technique - I think I like the
idea of using StringIO and not creating/ deleting the file.
On Dec 2, 4:20 pm, Ian Wilson wrote:
> Seems that you want something like this when using StringIO (in python 2.6
> at least):
>
> try:
>
Can't you just cache the result of the f.read() call, delete the file
and then return from the call?
f.close()
f.open('barcode.jpg')
tmp = f.read()
os.remove('barcode.jpg') # should really create a unique temp
name to avoid concurrency problems
On Dec 2, 2:33 pm,
Seems that you want something like this when using StringIO (in python 2.6
at least):
try:
return f.getvalue()
finally:
f.close()
On Thu, Dec 2, 2010 at 2:33 PM, snfct...@sacfoodcoop.com <
snfct...@sacfoodcoop.com> wrote:
> I want my controller to return a UPC barcode as action with one
I want my controller to return a UPC barcode as action with one
argument, like so: mycontroller/barcode/012345678901
It works fine if I read a file object, like so:
def barcode(self, data):
f = open('barcode.jpg', 'r')
barcode_('upc-a', str(data)).save(f, format='JPEG')
On Thu, Dec 2, 2010 at 7:38 AM, Antonio Beamud Montero
wrote:
> Hi all:
> I'm trying to download the 1.1 pylons stable release via mercurial, but I
> cannot find a tag in mercurial pointing to that release...
> How can I get it?
The latest version is 1.0. The repository is missing some tags, whic
Hi all:
I'm trying to download the 1.1 pylons stable release via mercurial, but
I cannot find a tag in mercurial pointing to that release...
How can I get it?
Greetings.
--
You received this message because you are subscribed to the Google Groups
"pylons-discuss" group.
To post to this group,
On Thu, Dec 02, 2010 at 02:59:54PM +0100, Stéphane Klein wrote:
> in a Pylons Framework project, I've this error :
>
> ProgrammingError: (ProgrammingError) SQLite objects created in a
> thread can only be used in that same thread.The object was created
> in thread id 1091357552 and this is thread
Le 02/12/2010 15:14, Stéphane Klein a écrit :
Le 02/12/2010 14:59, Stéphane Klein a écrit :
Hi,
in a Pylons Framework project, I've this error :
ProgrammingError: (ProgrammingError) SQLite objects created in a thread
can only be used in that same thread.The object was created in thread id
1091
Le 02/12/2010 14:59, Stéphane Klein a écrit :
Hi,
in a Pylons Framework project, I've this error :
ProgrammingError: (ProgrammingError) SQLite objects created in a thread
can only be used in that same thread.The object was created in thread id
1091357552 and this is thread id 1099762544
I use
Hi,
in a Pylons Framework project, I've this error :
ProgrammingError: (ProgrammingError) SQLite objects created in a thread
can only be used in that same thread.The object was created in thread id
1091357552 and this is thread id 1099762544
I use a standard sqlalchemy pylons skeleton.
I us
12 matches
Mail list logo