<commit_before>Greenmine Backend
=================

.. image:: http://kaleidos.net/static/img/badge.png
    :target: http://kaleidos.net/community/greenmine/

.. image:: https://travis-ci.org/kaleidos/greenmine-back.png?branch=master
    :target: https://travis-ci.org/kaleidos/greenmine-back

.. image:: https://coveralls.io/repos/kaleidos/greenmine-back/badge.png?branch=master
    :target: https://coveralls.io/r/kaleidos/greenmine-back?branch=master


Setup development environment.
------------------------------

You need to install django 1.6,...

.. code-block:: console

    git clone git://github.com/django/django.git django-trunk
    cd django-trunk
    git checkout stable/1.6.x
    python setup.py install
    cd ..
    rm -r django-trunk

... django-reversion for django 1.6 ...

.. code-block:: console

    git clone https://github.com/etianen/django-reversion.git django-reversion-trunk
    cd django-reversion-trunk
    git checkout django-1.6
    python setup.py install
    cd ..
    rm -r django-reversion-trunk


...ant then, you must install all the dependencies

.. code-block:: console

    pip install -r requirements.txt
    python manage.py syncdb --migrate --noinput
    python manage.py loaddata initial_user
    python manage.py sample_data
    python manage.py createinitialrevisions

Also, greenmine only runs over python 3.3+.


Auth: admin/123123


Polyfills
----------

Django-Rest Framework by default returns 403 for not authenticated requests and permission denied
requests. The file ``greenmine/base/monkey.py`` contains a temporary fix for this bug.

This patch is applied when the module ``base.models`` it's loaded. Once it's solved on django rest
framework, this patch can be removed.
<commit_msg>Remove obsolete doc from README.rst file.<commit_after>Greenmine Backend
=================

.. image:: http://kaleidos.net/static/img/badge.png
    :target: http://kaleidos.net/community/greenmine/

.. image:: https://travis-ci.org/kaleidos/greenmine-back.png?branch=master
    :target: https://travis-ci.org/kaleidos/greenmine-back

.. image:: https://coveralls.io/repos/kaleidos/greenmine-back/badge.png?branch=master
    :target: https://coveralls.io/r/kaleidos/greenmine-back?branch=master


Setup development environment
-----------------------------

Just execute these commands in your virtualenv(wrapper):

.. code-block:: console

    pip install -r requirements.txt
    python manage.py syncdb --migrate --noinput
    python manage.py loaddata initial_user
    python manage.py sample_data
    python manage.py createinitialrevisions


Note: greenmine only runs with python 3.3+.

Note: Initial auth data: admin/123123


Polyfills
---------

Django-Rest Framework by default returns 403 for not authenticated requests and permission denied
requests. The file ``greenmine/base/monkey.py`` contains a temporary fix for this bug.

This patch is applied when the module ``base.models`` it's loaded. Once it's solved on django rest
framework, this patch can be removed.

{'fraction_non_alphanumeric': 0.1388796818031157, 'fraction_numerical': 0.009943652635067949, 'mean_word_length': 3.226890756302521, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 9, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2514089', 'n_tokens_mistral': 930, 'n_tokens_neox': 880, 'n_words': 257}