aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeLines
...
| * | | | | | | | Migrate undesirable active infraction to inactiveGravatar Sebastiaan Zeeff2019-10-08-0/+754
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://github.com/python-discord/site/issues/273 This commit adds a data migration to migrate active infractions that should not be active to inactive. There are two types of infractions that this migration will migrate to inactive: - Infractions of types that should never be active (e.g. notes) - Secondary active infractions if a given user already has an active infraction of the same type. Since this makes the migration file fairly complex, I have written tests to make sure the migration works as expected. In order to do this, I've subclassed `django.test.TestCase` to create a `MigrationsTestCase` that takes care of reverting the database back to a state prior to the migrations we want to test and injects test data before applying the migrations we want to test. For more information, see `pydis_site.apps.api.tests.migrations.base` This implements the last part of and closes #273
| * | | | | | | | Add validation rules to Infraction serializerGravatar Sebastiaan Zeeff2019-10-07-1/+99
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://github.com/python-discord/site/issues/273 This commit adds validation rules to the Infraction serializer that validate if a given infraction should be accepted based on its status of being considered `active`. If the validation fails, the API will reject the request and return a 400 status. Specifically, this validator checks that: - infractions that can never be active do not have `active=True` set; - a user can never receive a second active infraction of the same type. Tests have been added to `test_infractions.py` to ensure that the validators work as expected. This commit implements the first part of #273
| | | * | | | | | Merge branch 'master' into allauth-user-settingsGravatar Gareth Coles2019-10-28-35/+50
| | | |\ \ \ \ \ \
| | | * \ \ \ \ \ \ Merge branch 'master' into allauth-user-settingsGravatar Gareth Coles2019-10-23-1/+1
| | | |\ \ \ \ \ \ \
| | | * | | | | | | | Full coverage and finish cleanupGravatar Gareth Coles2019-10-23-5/+96
| | | | | | | | | | |
| | | * | | | | | | | Add user settings modal, with connections management and account deletionGravatar Gareth Coles2019-10-23-13/+310
| | | | | | | | | | |
| | | * | | | | | | | Add role mapping migration I forgot to commitGravatar Gareth Coles2019-10-23-0/+18
| | | | | | | | | | |
| | | * | | | | | | | Finalize orange and purple custom coloursGravatar Gareth Coles2019-10-22-3/+3
| | | | | | | | | | |
| | | * | | | | | | | New colours, as discussed on DiscordGravatar Gareth Coles2019-10-22-7/+7
| | | | | | | | | | |
| | | * | | | | | | | Full test coverage, better redirect testingGravatar Gareth Coles2019-10-22-4/+110
| | | | | | | | | | |
| | | * | | | | | | | Prevent user signup when they've never joined+verifiedGravatar Gareth Coles2019-10-22-13/+110
| | | | | | | | | | |
| | | * | | | | | | | Merge branch 'master' into allauth-user-settingsGravatar Gareth Coles2019-10-22-1/+1
| | | |\ \ \ \ \ \ \ \
| | | * | | | | | | | | Implement account deletion at /accounts/deleteGravatar Gareth Coles2019-10-22-3/+76
| | | | | | | | | | | |
| | | * | | | | | | | | Merge branch 'master' into allauth-user-settingsGravatar Gareth Coles2019-10-22-0/+0
| | | |\ \ \ \ \ \ \ \ \ | | | | | |_|_|/ / / / / | | | | |/| | | | | | |
| | | * | | | | | | | | Update Django users with Discord username+discrim.Gravatar Gareth Coles2019-10-20-3/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This sets both the Django User's `username` and `first_name` params.
| | | * | | | | | | | | Signals: Complete coverage in testsGravatar Gareth Coles2019-10-20-0/+41
| | | | | | | | | | | |
| | | * | | | | | | | | Tests for the new signal listener is_staff changesGravatar Gareth Coles2019-10-20-5/+26
| | | | | | | | | | | |
| | | * | | | | | | | | Add is_staff to role mappings, and the logic to go with itGravatar Gareth Coles2019-10-20-11/+63
| | | | | | | | | | | |
| | | * | | | | | | | | Signals: Move group changes outside of the loopGravatar Gareth Coles2019-10-20-6/+6
| | | | | | | | | | | |
| | | * | | | | | | | | GH signup prevention, views and templates for settings pagesGravatar Gareth Coles2019-10-20-5/+126
| | | | | | | | | | | |
| | | * | | | | | | | | Allauth: Re-add GitHub provider, prevent GH signupsGravatar Gareth Coles2019-10-19-0/+48
| | | | | | | | | | | |
| | | * | | | | | | | | Bring navbar styling in line on mobile as wellGravatar Gareth Coles2019-10-19-0/+10
| | | | | | | | | | | |
| | | * | | | | | | | | Initial navbar change to add settings button next to logoutGravatar Gareth Coles2019-10-19-3/+9
| | |/ / / / / / / / /
| | | | | | | | | * | Delete useless migration fileGravatar Matteo Bertucci2019-11-15-19/+0
| | | | | | | | | | |
| | | | | | | | | * | Allow blank attachment fieldGravatar Matteo Bertucci2019-11-15-1/+1
| | | | | | | | | | |
| | | | | | | | | * | Allow empty attachment fieldGravatar Matteo Bertucci2019-10-31-0/+20
| | | | | | | | | | |
| | | | | | | | | * | Merge branch 'master' into bot#549-show-attachments-staffGravatar Matteo Bertucci2019-10-31-77/+72
| | | | | | | | | |\ \ | |_|_|_|_|_|_|_|_|/ / |/| | | | | | | | | |
| | | | | | | | * | | Test for the attachment image to be in the staff logGravatar Akarys422019-11-20-0/+15
| | | | | | | | |/ /
| | | | | | | | * | Write tests for message.attachmentsGravatar Akarys422019-10-28-3/+8
| | | | | | | | | |
| | | | | | | | * | Show attachments in staff logsGravatar Akarys422019-10-28-0/+5
| | | | | | | | | |
| | | | | | | | * | Add migration for message.attachmentsGravatar Akarys422019-10-28-0/+20
| | | | | | | | | |
| | | | | | | | * | Add a attachments field to the message modelGravatar Akarys422019-10-28-1/+8
| | | | | | | |/ /
| | | | | | | | * Make newlines visible in deleted messagesGravatar Sebastiaan Zeeff2019-10-31-10/+53
| |_|_|_|_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://github.com/python-discord/site/issues/302 This commit makes newlines in deleted messages visible in the deleted messages front-end and makes sure they are not stripped during the conversion to HTML. To represent newlines, I've chosen a commonly used symbol: `↵`. In addition, I've kaizened the colour filter that translates integer representations of colours to their RGB hex-value. The Discord dark theme shows black colours (int: 0; hex: #000000) as white instead, to make reading them against the dark background easier. This commit makes sure our front-end displays the same behavior. This closes #302
* | | | | | | | Merge pull request #293 from python-discord/update-dependency-pinningGravatar Leon Sandøy2019-10-28-45/+54
|\ \ \ \ \ \ \ \ | |_|_|_|_|_|/ / |/| | | | | | | Update dependency pinning
| * | | | | | | Merge branch 'master' into update-dependency-pinningGravatar Leon Sandøy2019-10-28-37/+52
| |\ \ \ \ \ \ \ | |/ / / / / / / |/| | | | | | |
* | | | | | | | Merge pull request #301 from python-discord/new-rulesGravatar scragly2019-10-26-32/+18
|\ \ \ \ \ \ \ \ | |_|_|_|_|_|_|/ |/| | | | | | | Add new rules.
| * | | | | | | Add new rules.Gravatar scragly2019-10-26-32/+18
|/ / / / / / /
* | | | | | | Merge pull request #294 from bsoyka/patch-1Gravatar Sebastiaan Zeeff2019-10-25-2/+2
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | Remove breadcrumb truncation
| * \ \ \ \ \ \ Merge branch 'master' into patch-1Gravatar Sebastiaan Zeeff2019-10-25-3/+32
| |\ \ \ \ \ \ \ | |/ / / / / / / |/| | | | | | |
* | | | | | | | Merge pull request #288 from python-discord/bot#466-reminder-jump_urlGravatar Sebastiaan Zeeff2019-10-25-1/+30
|\ \ \ \ \ \ \ \ | |_|_|_|_|_|_|/ |/| | | | | | | Add a jump_url field to the reminder model
| * | | | | | | Merge branch 'master' into bot#466-reminder-jump_urlGravatar Sebastiaan Zeeff2019-10-25-2/+2
| |\ \ \ \ \ \ \ | |/ / / / / / / |/| | | | | | |
* | | | | | | | Merge pull request #297 from python-discord/constant-debug-secret-keyGravatar Mark2019-10-22-1/+1
|\ \ \ \ \ \ \ \ | |_|_|_|_|_|_|/ |/| | | | | | | Set SECRET_KEY to a constant in DEBUG mode
| * | | | | | | Set SECRET_KEY to constant in debug modeGravatar Sebastiaan Zeeff2019-10-22-1/+1
|/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The SECRET_KEY in debug mode was auto-generated each time the config file was loaded. This had the unwanted side-effect of requiring testers to login again on the site as the SECRET_KEY had changed during the reload process. This commit resolves that by turning it into a constant. Since having a constant secret results in the linting error `S105`, I have added a specific `noqa` ignore for that.
* | | | | | | Add bulma content class to home page content for proper formatti… (#291)Gravatar scragly2019-10-23-1/+1
|\ \ \ \ \ \ \ | |_|_|_|_|_|/ |/| | | | | | Add bulma content class to home page content for proper formatting.
| * | | | | | Add bulma content class to home page content for proper formatting.Gravatar scragly2019-10-21-1/+1
| | |_|_|_|/ | |/| | | |
* / | | | | blank commit to trigger deploymentGravatar Derek2019-10-22-0/+0
|/ / / / /
| * | | | Add migrations for the reminder modelGravatar Akarys422019-10-21-0/+19
| | | | |
| * | | | Change reminder.jump_url field to URLFieldGravatar Akarys422019-10-21-1/+1
| | | | | | | | | | | | | | | | | | | | This make sure that the data receivied is valid
| * | | | Add max_lengh for reminder.jump_urlGravatar Akarys422019-10-19-0/+1
| | | | |
| * | | | Add a jump-url field in the reminder modelGravatar Akarys422019-10-19-1/+10
|/ / / /