semvec/pypi-packages huggingface dataset:
procrustes 0.2.1
validation library
License: BSD

============
 Procrustes
============

Procrustes is a validation library, suitable for validating user input data,
i.e. web forms or API calls. With procrustes you can validate any structure.

For doing this procrustes has three container classes - Tuple, List and Dict.
Tuple come from FP, has fixed count of elements with fixed types.
List can include any amount of values of one type.
And Dict is a dict.


Procrustes consist of validators and forms. You can use validators without
forms functionality. Forms adds mainly widgets and form data parsing.


Validators
~~~~~~~~~~

Most simple what you can to do with procrustes is build validator and use it:

    >>> from procrustes import validators as v
    >>> two_strings_v = v.Tuple(v.String(), v.String())
    >>> auth = two_strings_v(['login', 'password'])
    >>> auth.data
    ('login', 'password')
    >>> auth.errors
    []
    >>> auth = two_strings_v(['login'])
    >>> auth.data
    >>> auth.errors
    ['Must be iterable of length 2']

We have very powerful `List`:

    >>> list_of_pairs_v = v.List(two_strings_v)
    >>> pairs = list_of_pairs_v([(str(x), str(x)) for x in xrange(10)])
    >>> pairs.data
    [('0', '0'), ('1', '1'), ('2', '2'), ('3', '3'), ('4', '4'), ('5', '5'), ('6', '6'), ('7', '7'), ('8', '8'), ('9', '9')]
    >>> pairs.errors
    []

`List`, `Tuple` and `Dict` are recursive, so you can build any data structure you want.

`Dict` example:

    >>> dict_v = v.Dict({'pair': two_strings_v, 'pairs': list_of_pairs_v})
    >>> data = dict_v({'pair': ['a', 'b'], 'pairs': [['a', 'b'], ['c', 'd']]})
    >>> data.data
    {'pair': ('a', 'b'), 'pairs': [('a', 'b'), ('c', 'd')]}
    >>> data.errors
    []

Validators have `required` keyword argument:

    >>> two_strings_v = v.Tuple(v.String(), v.String(), required=False)
    >>> dict_v = v.Dict({'pair': two_strings_v, 'pairs': list_of_pairs_v})
    >>> data = dict_v({'pairs': [['a', 'b'], ['c', 'd']]})
    >>> data.data
    {'pair': None, 'pairs': [('a', 'b'), ('c', 'd')]}
    >>> data.errors
    []

Flat
~~~~

Procrustes can `flat` data:

    >>> list(data.flatten())
    [('pairs__0__0', 'a'), ('pairs__0__1', 'b'), ('pairs__1__0', 'c'), ('pairs__1__1', 'd')]

And unflat it back:

    >>> dict_v.deepen(dict([('pairs__0__0', 'a'), ('pairs__0__1', 'b'), ('pairs__1__0', 'c'), ('pairs__1__1', 'd')]))
    {'pair': (None, None), 'pairs': [('c', 'd'), ('a', 'b')]}


Forms
~~~~~

Forms derived from validators and implemented as mixins to them. Every Field
can work as form. Your form may consist from one `forms.String()`.
In addition to validators forms adds methods `widgets`, `template_widgets`,
`unflat` and `is_valid`.
django-nojs 0.0.1
UNKNOWN
License: BSD

==============
Django noJS
==============

Simple application to plug to manage "javascript disabled" events


Installation
------------

Add `nojs` to your `INSTALLED_APPS`::

    INSTALLED_APPS = (
            ...,
            ...,
            'nojs',
        )

Add `django.core.context_processors.request` and `django.core.context_processors.static` to your `TEMPLATE_CONTEXT_PROCESSORS`::

    TEMPLATE_CONTEXT_PROCESSORS = ("django.contrib.auth.context_processors.auth",
                               "django.core.context_processors.debug",
                               "django.core.context_processors.i18n",
                               "django.core.context_processors.media",
                               "django.core.context_processors.static",
                               "django.core.context_processors.request",
                               "django.contrib.messages.context_processors.messages")

Into your templates::

    <link href="{{ STATIC_URL }}nojs/nojs.css" rel="stylesheet" type="text/css" media="screen" />

    <body>
    {% checkjs %}
    </body>
django-farm 0.4.2
An application for managing farm related items, specifically animals and products.
License: BSD

Django Farm
=============

A pluggable django application to keep track of animals on a farm. Simple.

Models
--------

Species
  name -> char
  slug -> from(name)
  
Breed
  species -> species
  name -> char
  slug -> from(name)
  
Animal
  name -> char
  slug -> from(name)
  breed -> breed
  mother -> animal
  father -> animal
  birthday -> date
  birthtime -> time
  description -> text
  photos -> photo[photologue]

ProductType
  name -> char (e.g. produce, meat, soap, preserves...)
  slug -> from(name)
  description -> text

Product
  name -> char
  type -> product type
  description -> text
  photos -> photo(s)[photologue]
  price -> float
  unit -> char (e.g. dozen, lb, half, whole)
  flexible_price -> char
Flask-Compass 0.2
Adds automatic Compass compilation to Flask
License: BSD

Flask-Compass
=============

Flask-Compass provides a simple integration of Compass_ into Flask applications
especially to help during the development process.

The extension scans the project's directory for Compass configuration files
in order to compile the associated Compass project.


Note that you need to have compass installed before being able to use this
extension.

Links
-----

* `Documentation <http://packages.python.org/Flask-Compass>`_

.. _compass: http://compass-style.org/
django-addons 0.6.6
Addon framework for Django
License: BSD

=============
Django-addons
=============

A Django app used to add true plug-n-play functionality to your own Django
applications and projects

Django-addons is a bunch of code that makes writing addon/plugins for your
Django project much easier. Add django-addons to your Django project and 
you can drop all the addons to '<projectdir>/addons' directory.


Installing
==========

You can install the latest version of django-addons running 
``pip install django-addons`` or ``easy_install django-addons``
You can also install the `in-development version`_ of django-addons with
``pip install django-addons==dev`` or ``easy_install django-addons==dev``.

.. _in-development version: http://code.indifex.com/django-addons/get/tip.tar.gz#egg=django-addons-dev


Features
========

* Addons overview page
* Automatic signal connecting of addons
* Automatic URL discovery of addons
* Template hooking system (inject code from addons to your main project)
* Django-staticfiles to serve site media from each addon
* Django-notifications support (automatic registration of noticetypes)
* Per addon localization
* Per addon settings
* Disabling addons via ./manage.py addons

For full documentation please refer to the 'docs/' directory.