Welcome, guest | Sign In | My Account | Store | Cart

Notice! PyPM is being replaced with the ActiveState Platform, which enhances PyPM’s build and deploy capabilities. Create your free Platform account to download ActivePython or customize Python with the packages you require and get automatic updates.


ztfy.utils is unavailable in PyPM, because there aren't any builds for it in the package repositories. Click the linked icons to find out why.

 Python 2.7Python 3.2Python 3.3
Windows (32-bit)
Windows (64-bit)
Mac OS X (10.5+)
Linux (32-bit)
Linux (64-bit)

What is ztfy.utils ?

ztfy.utils is a set of classes and functions which can be used to handle many small operations.

Internal sub-packages include :
  • date : convert dates to unicode ISO format, parse ISO datetime, convert date to datetime
  • request : get current request, get request annotations, get and set request data via annotations
  • security : get unproxied value of a given object ; can be applied to lists or dicts
  • timezone : convert datetime to a given timezone ; provides a server default timezone utility
  • traversing : get object parents until a given interface is implemented
  • unicode : convert any text to unicode for easy storage
  • protocol : utility functions and modules for several nerwork protocols
  • catalog : TextIndexNG index for Zope catalog and hurry.query "Text" query item
  • text : simple text operations and text to HTML conversion
  • html : HTML parser and HTML to text converter
  • file : file upload data converter
  • tal : text and HTML conversions for use from within TAL

How to use ztfy.utils ?

A set of ztfy.utils usage are given as doctests in ztfy/utils/doctests/README.txt


  • added "allow_none" and "headers" arguments in XML-RPC "getClient()" methods
  • change test for date types in tztime/gmtime functions (because datetime inherits from date!)
  • small correction in getHumanSize() function
  • added dates formatting functions
  • added check between date and datetime types in timezone module
  • use request locale formatter in getHumanSize function
  • move custom schema fields widgets to ZTFY.skin package
  • added legend on ZEO connection properties edit form
  • force usage of "escapeSlashes" argument when checking new content name
  • added ZEO connection interface, utility and tools
  • added "ztfy.utils.container" utility module
  • added a persistent utility to store ZEO connection settings
  • added "TextLine list" schema field and widget
  • added request and session cached properties
  • added Python 2.7 compatibility code and timeout parameter to XML-RPC protocol helper
  • changed request "data:" TAL namespace to basic HTTP request so it can be used in views called via JSON-RPC or XML-RPC
  • updated package source layout
  • added dotted decimal schema field, not handling locales :-/
  • upgraded for ztfy.jqueryui 0.6.0
  • added Color schema field and widget
  • added StringLine schema field
  • added "text:translate" TAL adapter
  • moved ITransactionManager adapter from ztfy.scheduler package
  • added HTTP client based on httplib2, handling authentication and proxies
  • corrected encodings vocabulary
  • added encodings vocabulary
  • corrected code and translations in MissingPrincipal class
  • added permissions on TextIndexNG index
  • re-add IList and IDict interfaces forgotten from bad merge :-(
  • better check for missing requests
  • Added "fanstatic:" TALES expression
  • Mark ztfy.utils.security functions and classes as deprecated
  • Updated signature in ztfy.utils.catalog.index to match last hurry.query release
  • Switched to ZTK-1.1.2 and Python 2.6
  • Added "getAge" function in date module
  • Added session module and TALES adapter to get/set session values
  • Check None value in catalog.getObjectId(...) and catalog.getObject(...) methods
  • Added 'site.locateAndRegister' facility function
  • Update ServerTimezoneUtility parent classes
  • Added 'data' namespace to access request data
  • Initial release

Subscribe to package updates

What does the lock icon mean?

Builds marked with a lock icon are only available via PyPM to users with a current ActivePython Business Edition subscription.

Need custom builds or support?

ActivePython Enterprise Edition guarantees priority access to technical support, indemnification, expert consulting and quality-assured language builds.

Plan on re-distributing ActivePython?

Get re-distribution rights and eliminate legal risks with ActivePython OEM Edition.