Python Paste
Encyclopedia
Python Paste, often simply called paste, is a set of utilities
for web development
in Python
. Paste has been described as "a framework for web frameworks".
The package includes a WSGI wrapper for CGI
applications. It also includes a simple webserver that can produce WSGI requests.
serves content created by Python code.
There are, however, other uses: WSGI middleware is Python code that receives a WSGI request and then performs logic based upon this request, before passing the request on to a WSGI application or more WSGI middleware. WSGI middleware appears to an application as a server, and to the server as an application. This is analogous to the function of pipes on Unix systems
. Functionality provided by WSGI middleware may include authentication, logging, url redirection
, creation of sessions
, and compression.
Paste helps in developing such WSGI middleware systems. For example, it is used in the Pylons web application framework.
As it has grown, it has unbundled several other utilities from the Paste core. These utilities are part of the Paste project, but form their own packages and have their own version numbers. They include:
Utility software
Utility software is system software designed to help analyze, configure, optimize or maintain a computer. A single piece of utility software is usually called a utility or tool....
for web development
Web development
Web development is a broad term for the work involved in developing a web site for the Internet or an intranet . This can include web design, web content development, client liaison, client-side/server-side scripting, web server and network security configuration, and e-commerce development...
in Python
Python (programming language)
Python is a general-purpose, high-level programming language whose design philosophy emphasizes code readability. Python claims to "[combine] remarkable power with very clear syntax", and its standard library is large and comprehensive...
. Paste has been described as "a framework for web frameworks".
Python Paste
The Python Paste package contains Python modules that help in implementing WSGI middleware.The package includes a WSGI wrapper for CGI
Common Gateway Interface
The Common Gateway Interface is a standard method for web servers software to delegate the generation of web pages to executable files...
applications. It also includes a simple webserver that can produce WSGI requests.
WSGI middleware
The WSGI standard is an interface that allows applications to use Python code to handle HTTP requests. A WSGI application is passed a Python representation of an HTTP request by an application, and returns content which will normally eventually be rendered by a web browser. A common use for this is when a web serverWeb server
Web server can refer to either the hardware or the software that helps to deliver content that can be accessed through the Internet....
serves content created by Python code.
There are, however, other uses: WSGI middleware is Python code that receives a WSGI request and then performs logic based upon this request, before passing the request on to a WSGI application or more WSGI middleware. WSGI middleware appears to an application as a server, and to the server as an application. This is analogous to the function of pipes on Unix systems
Pipeline (Unix)
In Unix-like computer operating systems , a pipeline is the original software pipeline: a set of processes chained by their standard streams, so that the output of each process feeds directly as input to the next one. Each connection is implemented by an anonymous pipe...
. Functionality provided by WSGI middleware may include authentication, logging, url redirection
URL redirection
URL redirection, also called URL forwarding and the very similar technique domain redirection also called domain forwarding, are techniques on the World Wide Web for making a web page available under many URLs.- Similar domain names :...
, creation of sessions
Sessions
Sessions can refer to:* Quarter Sessions, a periodic court formerly held in counties of England and Wales* Petty Sessions, the lowest level of court in England and Wales* Sessions, an EP by Australian Reggae/Rocksteady band Rogerthat...
, and compression.
Paste helps in developing such WSGI middleware systems. For example, it is used in the Pylons web application framework.
Subcomponents of Paste
Paste has been a long-running open source project, dating from at least 2005.As it has grown, it has unbundled several other utilities from the Paste core. These utilities are part of the Paste project, but form their own packages and have their own version numbers. They include:
- WebOb is a wrapper around the WSGI environment.
- Paste Deploy is a system for finding and configuring WSGI applications and servers.
- Paste Script, WebTest, ScriptType, INITools, Tempita, WaitForIt, WPHP, WSGIFilter, and WSGIProxy are other notable bundles.
See also
- TurboGearsTurboGearsTurboGears is a Python web application framework consisting of several WSGI components such as Pylons, SQLAlchemy, Genshi and Repoze.TurboGears is designed around the model-view-controller architecture, much like Struts or Ruby on Rails, designed to make rapid web application development in Python...
- Pylons (web framework)
- Smalltalk Seaside
- Java ServletJava ServletA servlet is a Java programming language class used to extend the capabilities of servers that host applications accessed via a request-response programming model. Although servlets can respond to any type of request, they are commonly used to extend the applications hosted by Web servers...
- ISAPIISAPIThe Internet Server Application Programming Interface is an N-tier API of Internet Information Services , Microsoft's collection of Windows-based web server services...
- FastCGIFastCGIFastCGI is a protocol for interfacing interactive programs with a web server. FastCGI is a variation on the earlier Common Gateway Interface ; FastCGI's main aim is to reduce the overhead associated with interfacing the web server and CGI programs, allowing a server to handle more web page...
- Apache ThriftThrift (protocol)Thrift is an interface definition language that is used to define and create services for numerous languages. It is used as a remote procedure call framework and was developed at Facebook for "scalable cross-language services development"...
(from Facebook and Evernote teams) - Server-side JavaScriptServer-side JavaScriptServer-side JavaScript refers to JavaScript that runs on the server-side. This term was coined because the language is predominantly used on the client-side, i.e. client-side JavaScript ....
- PHPPHPPHP is a general-purpose server-side scripting language originally designed for web development to produce dynamic web pages. For this purpose, PHP code is embedded into the HTML source document and interpreted by a web server with a PHP processor module, which generates the web page document...
- Web application frameworkWeb application frameworkA web application framework is a software framework that is designed to support the development of dynamic websites, web applications and web services. The framework aims to alleviate the overhead associated with common activities performed in Web development...
External links
- Python Paste: official site
- Ian Bicking page
- Ben Bangert's Google Tech Talk, Sep 13, 2006
- Ian Bicking's Topics of Interest, 4:30-9:30, PyCon 2009