Correcting issue that exists while adding 2 packages with the same name but with different types

Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
Function _mark_file_not_processed was called with the wrong number of arguments for Binary objects

Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
docs: add a chapter about contributing

[hertzog@debian.org:
- Wrap text in list items
- Reword some sentences
- Put "Conventions" after "Usual workflow" ]

Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
docs: collectstatic is only needed with a webserver

Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
docs: test discovery was updated in Django 1.6

Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
docs: put database setup instructions where they belong

Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
docs: avoid repeating Distro Tracker in all titles
docs: put the contributing section at the end

Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
Add custom delete methods (for single and bulk delete) to PackageName proxy classes

[hertzog@debian.org:
- Simplify and cleanup the test code
- Factorize the delete method from PackageName proxy classes in PackageName ]

Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
Drop get_absolute_url methods that duplicate logic from the parent class
Cleanup of BinaryPackageName class

Also update some outdated docstrings.
Replace javascript tooltips with HTML titles

Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
Fix name 'BinaryPackageBugStats' is not defined

Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
Fix a test-suite failure with Django 1.6.2 and newer

Until version 1.6.1, Django was generating mails with the as_string()
method on the object returned by the message() method of a
django.core.mail.EmailMessage object. To avoid problemes in Python 3, we
used to override the default as_string() to return bytes in Python3 too.
This was the purpose of BytesEmailMessage.

Since version 1.6.2, it's now using the as_bytes() method which doesn't
exist in Python 2 but that they added in their own SafeMIMEText class.

Implementing as_bytes() is BytesEmailMessage could be enough to fix the
issue but I found it cleaner to get rid of this class and to monkey patch
the email.Message objects generated by our own message_from_bytes()
to override the as_string/as_bytes methods so that they behave like
Django expects them to behave and so that we ensure identical behaviour
between Python 2 and 3 with older versions of Django too.
Adding allow_redirect for http requests to fix issues with 301 and 302 HTTP return codes

Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
Fix up python-apt setup

Without those changes, python-apt was hooking into many system-wide
settings and would run stuff like APT hooks during a distro-tracker
repository update.

Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
Remove EmailUser 1/4: adapt tests

This is the first commit in a set of four. We want to completely remove
the obsolete EmailUser object, replacing it with UserEmail: Teams will
be composed of UserEmail objects, and Subscriptions will relate to
UserEmail.EmailSettings.
Remove EmailUser 2/4: adapt models.
Remove EmailUser 3/4: views.
Remove EmailUser 4/4: templates.