News: Paste Script¶
3.7.0 (2025-01-22)¶
Open, read and write files in binary mode in copydir.py.
Fix locking for modern Python.
3.6.0 (2024-04-27)¶
Pastescript is moved to https://github.com/pasteorg/pastescript
With version 3.6.0 pastescript development moves to the pasteorg GitHub organization and will be going deeper into maintenance mode unless more active maintainers step forward to take over. “Deeper” in this case means that releases will be much less frequent and patches will only be accepted for security issues or major problems. Current consumers of pastescript should prepare to migrate away to more modern solutions.
3.5.1 (2024-03-15)¶
Be explicit about Python 3 being required.
3.5.0 (2024-03-14)¶
Remove remains of Python 2 in code. Thanks to Alexandre Detiste (a-detiste)
3.4.0 (2024-01-22)¶
Correct working with PasteDeploy >=3. Thanks brondsem.
3.3.0 (2023-01-03)¶
Remove support for Python 2 in tests. It may still work outside tests.
Fix homepage link. Thanks to Guillaume Gauvrit (mardiros).
Stop using nose to run tests.
Run tests in GitHub actions instead of travis CI.
3.2.1 (2021-04-27)¶
Require
setuptoolsininstall_requires. Thanks to Tomáš Hrnčiar (hrnciar)Fix tests to run again.
3.2.0 (2019-09-24)¶
Use wsgiserver.WSGIServer instead of wsgiutils.wsgiServer.WSGIServer for Python 3 compatibility.
3.1.0 (2019-03-04)¶
Remove dependency on
unittest2.
3.0.0 (2018-11-26)¶
Moved to GitHub.
Put into maintenance mode, meaning: critical bugs will be fixed, and support for new versions of Python will be handled, but new features are not being considered.
2.0.2 (2015-05-27)¶
Issue #20: Fix “paster points –list” on Python 3.
Fix cgi_server on Python 3.
Fix usage of the sort() method on Python 3.
Fix grep on Python 3.
2.0.1 (2015-05-26)¶
Fix –help command on Python 3. Patch written by Atsushi Odagiri (aodag).
Fix “paster create –template=basic_package test” command on Python 3. Patch written by Atsushi Odagiri (aodag).
Fix error when ‘paster create –list-template’ on Python 3. Patch written by FGtatsuro.
Create universal wheel package.
2.0 (2015-05-26)¶
Experimental Python 3 support.
six module is now required.
Drop support of Python 2.5 and older
1.7.5¶
Import CherryPy directly instead of including its server inline in the
paste.scriptpackage. You must install CherryPy before usingegg:PasteScript#cherrypy
1.7.4.2¶
1.7.4 had package release problems, was reverted; 1.7.4.1 also had package problems.
Include special
hereand__file__default vars for logging config files, similar to PasteDeploy config loading.Allow Jython to import various bits from
paste.script.commandandpaste.script.copydirwithout throwing an import error (subprocess module cannot be imported on Jython). This allows PasteScript to work minimally on Jython, although execution will fail forcommand.run_commandandcopydir.copydir.
1.7.3¶
CherryPy wsgiserver updated to 3.1.1, fixes a regression in Python 2.5 plus a couple other small fixes.
1.7.2¶
Fix a packaging issue that could cause problems when installing PasteScript.
1.7.1¶
filemaker.py’s FileOp can now handle a tuple as a source_dir argument that should function the same as the _template_dir option for pkg_resources.
CherryPy wsgiserver updated to trunk@2063 for Python 2.6 compatibility.
1.7¶
_template_dir now takes a tuple argument, which should be the package name, and the relative location to the package of its template directory. pkg_resources will then be used to load make the templates rather than raw file access making it zip-safe.
CherryPy wsgiserver updated to the 3.1.0 release’s.
Support Python 2.6.
Added experimental support for a quicker paster serve –reload for Jython.
Non-Python files in
paste/script/templates/causes an error on 2.6; renamed directory to avoid this.
1.6.3¶
Fixes for
paste.script.filemakerA setuptools
egg_info.writersentry point is now provided that’s responsible for writing paster_plugins.txt for projects that define a newpaster_pluginssetup() keyword. paster_plugins.txt will still be created for new projects that need it and lack apaster_pluginssetup() keyword, but this is deprecated. Projects definingpaster_pluginsin setup() should also define asetup_requiressetup() keyword including PasteScript.An
egg_pluginsvariable (a list of strings based off the Templates classes’egg_pluginsvariables) is now available to paster create templates for the newpaster_pluginssetup() keyword.PasteScript is no longer included in
egg_plugins/paster_plugins.txt by default.
1.6.2¶
Fix SkipTemplate (could raise
TypeError: argument 1 must be string or read-only buffer, not Nonebefore)
1.6.1 (and 1.6.1.1)¶
Fix paster serve under Windows.
1.6¶
Added commands
paster request config.ini URLandpaster post config.ini URL < post-body, that allow you to do artificial requests to applications.Check the writability of the pid and log files earlier. This caused particular problems if you started it in daemon mode, and the files weren’t writable. From Chris Atlee.
Start the monitor (when using
--monitor) after daemonizing, so thatpaster serve --monitor --daemonworks (before it would constantly restart).In Paste Script templates, you can give
should_echo=Falsein variable definitions, and if the user is queried for the variable then the input will not be echoed (as for a password). From Dirceu Pereira Tiegs.Added a method
paste.script.appinstall.Installer.template_renderer, which can be used to override template substitution withpaster make-config. The function is similar to the same function used withpaster createtemplates.Remove
--daemonoption from Windows, as it depends onos.forkWhen using
paster createand inserting text with a-*-marker, multi-line text will no longer be reinserted.Improved output when skipping templates with
paster create.When starting a server with
paster serve --daemonand the pid file exists and describes a running process, do not start another process.Added
umaskoption toegg:PasteScript#flup_fcgi_thread/fork.Deprecate the flup entry points, as flup now has the necessary entry points in its own package.
1.3.6¶
CherryPy wsgiserver updated to the 3.0.2 release’s
paster no longer hides
pkg_resources.DistributionNotFounderror messages describing the target project’s requirements. Aids the somewhat confusing “did you run setup.py develop?” message when it had already been ran, but since then had a requirement added that wasn’t installed.Logging configuration is now read from the config file during
paster setup-app.Custom Formatters and Handlers (Handlers outside of the logging module) are now supported in logging configuration files.
1.3.5¶
Initialize logging earlier in the serve command for components that want to utilize it. Patch from Christopher Lenz.
Fixed Python 2.3 incompatibility (no
string.Template) inpaste.script.appinstall.
1.3.4¶
Make sure that when using
--monitoror--reload, if the parent monitoring process dies, also kill the subprocess.When using
paster serve --log-file, append to the log file (was truncating any previous contents).Read logging information from the server file, using the logging module’s standard configuration format
When adding files don’t fail because an svn command fails. Helpful particularly on Windows, when the svn command-line isn’t installed (e.g., using TortoiseSVN).
1.3.3¶
Fixed problem with
paster serveon Windows. Also on Windows, fixed issue with executables with spaces in their names (this case requires thewin32allmodule).You can use
+dot+in your project template filenames, specifically so that you can use leading dots in the filename. Usually leading dots cause the file to be ignored. So if you want to have new projects contain a.cvsignorefile, you can put a+dot+cvsignorefile in your template.Relatedly,
+plus+has been added so you can include pluses.
1.3.2¶
pasterwas largely broken under Windows; fixed.
1.3.1¶
Fix related to Python 2.5 (when there are errors creating files, you could get infinite recursion under Python 2.5).
Use
subprocessmodule inpaster servecommand. Added--monitoroption which will restart the server if it exits.The
execommand now does % substitution in keys (e.g.,pid_file=%(here)s/paste.pid).Some import problems with Cheetah should be improved.
1.3¶
Fixed an exception being raised when shutting down flup servers using sockets.
Fixed the CherryPy 3 WSGI server entry point’s handling of SIGHUP and SIGTERM.
The CherryPy wsgiserver is now available at
paste.script.wsgiserver(no longer requiring CherryPy to be installed).Added entry point for twisted server.
Made
paste.script.pluginlib:egg_info_dirwork with packages that put thePackage.egg-info/directory in a subdirectory (typicallysrc/).Remove Cheetah requirement. Packages using Cheetah templates should require Cheetah themselves. If you are using
paster make-configand you don’t want to use Cheetah, you must adduse_cheetah = Falseto yourInstallersubclass (it defaults to true for backward compatibility).Make scripts work when there is no
setup.py(if you aren’t making a Python/setuptools package).When using
paste.script.copydir.copy_dir(as with mostpaster createtemplates), you can raiseSkipTemplate(or call theskip_template()function) which will cause the template to be skipped. You can use this to conditionally include files.When using
paster serve c:/..., it should no longer confusec:with a scheme (such asconfig:oregg:).More careful about catching import errors in
websetup, so if you have a bug in yourapp.websetupmodule it won’t swallow it.
1.1¶
Added a
warn_returncodeoption toCommand.run_command, and makeensure_fileuse this for its svn command.If the svn command-line program isn’t working for you, commands that use
ensure_filewill continue to work but just with a warning.Removed copyright notice that was accidentally included in new packages created by
paster create.Allow variable assignments at the end of
paster serve, likepaster serve http_port=80; then you can use%(http_port)sin your config files (requires up-to-date Paste Deploy).Allow a
package_dirvariable so that you can put your package into subdirectories of the base directory (e.g.,src/).Changes to the
twisted.web2wrapper (from pythy).Warn when you run
paster setup-appand no modules are listed intop_level.txt(which can happen with a newly checked out project).
1.0¶
Added entry point for CherryPy 3’s WSGI server.
Fixed
paster serveto hide KeyboardInterrupt (CTRL-C) tracebacks in--reloadmode.Added
template_rendererargument topaste.script.copydir.copydir. This allows you to use arbitrary template languages, instead of juststring.Templateand Cheetah.
0.9.9¶
egg:PasteScript#test (the paste.script.testapp) now accepts
lintandtextboolean configuration.lintwill turn onpaste.lintvalidation.textwill cause it to return a simple text/plain response with the environ, instead of an HTML table.Improvements all around to
paster points, plus documentation for existing entry point groups.
0.9.8¶
New projects will now ignore
Package.egg-info/dependency_links.txt, just like all the other derivative files in theegg-infodirectorypaster serve --reloadwas broken on Windows when the Python executable was in a directory with spaces in it. This is probably a bug in thesubprocessmodule.
0.9.7¶
Update to filemaker commands to take optional argument so that when new directories are for a Python package, they will have a __init__.py created as well.
0.9.6¶
Do all variable assignment during package creation up-front, before actually creating the files.
Added the
eggtemplate variable: provides projects with a safe egg name as generated by setuptools. This should be used for egg-info directories in templates (e.g.+egg+.egg-infoinstead of+project+.egg-info), and anywhere else the egg name is expected, to prevent errors with project names containing hyphens.
0.9¶
Installer calls
websetup.setup_app(command, conf, vars);setup_config()will be deprecated in the futureAdded copyright information
paster serve config.ini#sectionworks nowpaster make-config/setup-appwill read$PASTE_SYSCONFIGto find extrasysconfig.pyfiles.paster createwill now query interactively for variables if they aren’t explicitly provided.
0.5¶
If the output directory doesn’t exist when running
paster create, do not default to having interactive (confirmation) on.
0.4.2¶
Fixed the Flup FastCGI interface. (There seem to still be problems with forking FastCGI.)
The
prepare-appcommand has been renamedmake-configChanged the way
make-configandsetup-appusesysconfig– these are now modules that can define various functionsAllow for default config file names
Consider config generation that may produce a directory (this case is now generally workable)
Allow for multiple config files (specifically with –edit)
Give config file generation the variables
app_install_uuidandapp_install_secretthat they can use for their config filesInclude Ka-Ping Yee’s uuid module in
paste.script.util.uuidpaster helpdoesn’t bail when commands can’t be loadedBe a little safer when
--editfails and--setupis provided (don’t automatically set up if the edit seems to have failed)
0.4.1¶
Two small bugfixes, one related to the
basic_packagetemplate (it included a reference tofinddata, which it should not have), and a fix to how the.egg-infodirectory is determined.
0.4¶
Added
pointscommand, for entry-point related queries.paste.deploy config files that start with
#!/usr/bin/env pastercan make a script into an executable.Improvements to
paster servecommand:Handle bad PID files better
Daemonization is more reliable
Allow
start,stop,restartinstead of just options
Improvements to
paster createcommand:Invoked interactively by default (so that you are warned before overwriting files)
Added new commands:
pointsfor viewing Egg entry point informationprepare-appandsetup-appfor installing web applications
Fixed bug in how Egg distributions are loaded.
0.3.1¶
Fixed small bug with running
paster serveon Windows. (Small to fix, kept script from running on Windows entirely).
0.3¶
Initial release.