Pylons/pyramid — Issue #412: route decodes %2F to slash when it should not
Author: jerryji
Created: 2012-01-22 10:44:22+00:00
State: open

This is the application --

```python
from paste.httpserver import serve
from pyramid.config import Configurator
from pyramid.response import Response

def foo(request):
return Response('Foo')

def foobar(request):
return Response('FooBar')

if __name__ == '__main__':
config = Configurator()
config.add_route('foo', '/{foo}') # for /foo[^/]*bar
config.add_view(foo, route_name='foo')
config.add_route('foobar', '/{foo}/{bar}') # for /foo/bar
config.add_view(foobar, route_name='foobar')
app = config.make_wsgi_app()
serve(app, host='0.0.0.0')
```

This is the output --

```python
In [6]: print requests.get('http://localhost:8080/foobar').content
Foo

In [5]: print requests.get('http://localhost:8080/foo/bar').content
FooBar

In [7]: print requests.get('http://localhost:8080/foo%2Fbar').content
FooBar <----- should print "Foo" here
```