C
Collin Winter
Hello all,
I have released version 0.3.5 of my typecheck module, a Python module
providing run-time typechecking facilities for function parameters and
return values, as well as generator yield values.
The main workhorses of this module, the functions accepts, returns and yields,
are used as function/method decorators. These operate on a function
arguments, function return values and generator yield values,
respectively.
A number of utility classes are provided to assist in building more complex
signatures, for example, by creating boolean expressions based on classes
and/or types.
It is possible to incorporate typechecking facilities into user-defined
classes. A mixin class, UnorderedIteratorMixin, is provided to allow easy
typechecking of iterators. Numerous examples are provided as to how to
integrate your own container classes into typecheck.
Where to get it:
#########
typecheck is available from the project's website at
http://oakwinter.com/code/typecheck/
and from the Python Package Index at
http://cheeseshop.python.org/pypi/typecheck
Both source tarballs and Python Eggs for Python versions 2.4 and 2.5
are available.
Release Notes
########
This is a bug-fix release:
+ After fixing an issue with the test suite, typecheck is now
compatible with Python 2.5
+ Compatibility issues:
- Typeclass instances are no longer callable. This means that
"Number() is not Number" is True. This was done to fix a bug
with typeclasses.
+ Bug fixes:
- Add an __all__ list to typecheck/__init__.py
- Instances with __call__ methods can now be used as
functions (ie, in conjunction with Function)
- Unicode can now be used to specify type variables
- Rename all message() methods on the internal _TC_* extensions
to error_message() (Python 2.5's exceptions already have
message attribute)
- Add repr() and str() support to Typeclass instances
- Fix a bug related to typecheck_args()'s checking of the number of
arguments passed to the typechecked function
- Fix SF #1495358; typeclasses can now actually be used.
As always, feedback welcome!
Collin Winter
I have released version 0.3.5 of my typecheck module, a Python module
providing run-time typechecking facilities for function parameters and
return values, as well as generator yield values.
The main workhorses of this module, the functions accepts, returns and yields,
are used as function/method decorators. These operate on a function
arguments, function return values and generator yield values,
respectively.
A number of utility classes are provided to assist in building more complex
signatures, for example, by creating boolean expressions based on classes
and/or types.
It is possible to incorporate typechecking facilities into user-defined
classes. A mixin class, UnorderedIteratorMixin, is provided to allow easy
typechecking of iterators. Numerous examples are provided as to how to
integrate your own container classes into typecheck.
Where to get it:
#########
typecheck is available from the project's website at
http://oakwinter.com/code/typecheck/
and from the Python Package Index at
http://cheeseshop.python.org/pypi/typecheck
Both source tarballs and Python Eggs for Python versions 2.4 and 2.5
are available.
Release Notes
########
This is a bug-fix release:
+ After fixing an issue with the test suite, typecheck is now
compatible with Python 2.5
+ Compatibility issues:
- Typeclass instances are no longer callable. This means that
"Number() is not Number" is True. This was done to fix a bug
with typeclasses.
+ Bug fixes:
- Add an __all__ list to typecheck/__init__.py
- Instances with __call__ methods can now be used as
functions (ie, in conjunction with Function)
- Unicode can now be used to specify type variables
- Rename all message() methods on the internal _TC_* extensions
to error_message() (Python 2.5's exceptions already have
message attribute)
- Add repr() and str() support to Typeclass instances
- Fix a bug related to typecheck_args()'s checking of the number of
arguments passed to the typechecked function
- Fix SF #1495358; typeclasses can now actually be used.
As always, feedback welcome!
Collin Winter