Is there an easy way to set MIME types for static files?

2009-01-01 Thread Nopparat C

I am learning to do RIA application using curl and pylons. I wonder if
there is a way to configure MIME types for static files like I usually
do in apache

   AddType text/vnd.curl .curl
   AddType text/vnd.curl.dcurl .dcurl



--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
pylons-discuss group.
To post to this group, send email to pylons-discuss@googlegroups.com
To unsubscribe from this group, send email to 
pylons-discuss+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/pylons-discuss?hl=en
-~--~~~~--~~--~--~---



Re: Is there an easy way to set MIME types for static files?

2009-01-01 Thread Philip Jenvey


On Jan 1, 2009, at 3:25 AM, Nopparat C wrote:


 I am learning to do RIA application using curl and pylons. I wonder if
 there is a way to configure MIME types for static files like I usually
 do in apache

   AddType text/vnd.curl .curl
   AddType text/vnd.curl.dcurl .dcurl

You just need to register these with Python's mimetypes module. The  
WSGI middleware that serves static files, paste.fileapp.FileApp, uses  
that module to determine content-types.

--
Philip Jenvey

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
pylons-discuss group.
To post to this group, send email to pylons-discuss@googlegroups.com
To unsubscribe from this group, send email to 
pylons-discuss+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/pylons-discuss?hl=en
-~--~~~~--~~--~--~---



pylons.decorators.secure.https throws away the query string ?

2009-01-01 Thread Tycon

This decorator is supposed to redirect HTTP GET requests to HTTPS. But
guess what ? The query string in the request URI is lost, so the
redirected (https) request will not have any request.params even if
the original (http) request did.



--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
pylons-discuss group.
To post to this group, send email to pylons-discuss@googlegroups.com
To unsubscribe from this group, send email to 
pylons-discuss+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/pylons-discuss?hl=en
-~--~~~~--~~--~--~---



Re: Do beaker session store supports using memcached ?

2009-01-01 Thread Michael Bayer



On Dec 31 2008, 5:01 pm, Tycon adie...@gmail.com wrote:
 if it's not a system service then why does it have it's own /etc/
 init.d file
 (the way it's packaged for most major distributions) ?

oh I always just build it from source :) .that theres an /etc/
init.d entry indicates its a decision of those distros to have a
single memcached daemon running, its not a decision of memcached.
I've read through the memcached website very thoroughly regarding this
question and I don't see any guidelines on this issue in either
direction.  I wouldn't think memcached itself has much of an opinion
on how its run.   I would almost guarantee that high volume websites
which use memcached do not multipurpose a single memcached instance
across multiple unrelated applications, though...apart from the
difficulty of multiple performance profiles affecting the single
memcached process in different ways, why bother taking the risk that
two different applications might use the same keynames for different
purposes.

 While it is possible to have a memcached server dedicated to one
 application, you can't assume this is the default.

with that said, of course I agree on this.   I made it pretty clear in
the CHANGELOG that the remove() method with the memcached backend now
does flush_all(), which is not a method that's called by the library
except by the erroneous usage of it in Session, and I've sent Ben a
patch which changes Session to store a single dict on one key in the
namespace regardless of backend so namespace.remove() would not be
used.   I've also advised that namespace.remove(), just like
namespace.keys(), raise a NotImplementedError() when using the
memcached backend.


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
pylons-discuss group.
To post to this group, send email to pylons-discuss@googlegroups.com
To unsubscribe from this group, send email to 
pylons-discuss+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/pylons-discuss?hl=en
-~--~~~~--~~--~--~---



Problems with installation through easy_install

2009-01-01 Thread baluviki

Installation of pylons (easy_install Pylons==0.9.6.2) fails with
traceback. Last error is:

  File /usr/lib/python2.5/httplib.py, line 604, in _safe_read
raise IncompleteRead(s)
httplib.IncompleteRead:

The same thing appears for

 easy_install -U setuptools

too. I do not use easy_install normally. For example originally I
installed setuptools as an ubuntu-pkg.

So is there any magic, I have to do?


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
pylons-discuss group.
To post to this group, send email to pylons-discuss@googlegroups.com
To unsubscribe from this group, send email to 
pylons-discuss+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/pylons-discuss?hl=en
-~--~~~~--~~--~--~---