Martyn Inglis
c3ffae3cf7
Live deployment on api codedeploy groups
2016-03-18 10:23:32 +00:00
Martyn Inglis
fc7ad7d556
Bring DB script into line with other prod scripts
2016-03-18 09:55:19 +00:00
Martyn Inglis
8871d4eda6
Env specific firetext from numbers
2016-03-18 09:15:05 +00:00
Martyn Inglis
c052f88408
Adding specific staging/live property for API HOST
2016-03-18 09:12:19 +00:00
Martyn Inglis
8b83e6a02a
Moved import until after env setup
2016-03-17 13:21:01 +00:00
minglis
cb0b091468
Merge pull request #164 from alphagov/staging-live-config-seperation
...
Allowing overrides on a per environment basis
2016-03-17 12:56:26 +00:00
Martyn Inglis
6aec6a0bda
Update as per pull request comments:
...
- context manager for file handling
- os.environ.update for setting overrides
2016-03-17 12:51:14 +00:00
Rebecca Law
bbd5274000
Merge pull request #163 from alphagov/default-stats-to-zero
...
Set default to 0 for the notification_statistics table.
2016-03-17 11:55:07 +00:00
Rebecca Law
b0c6a1a7c6
Fix the order for the migration script
2016-03-17 11:50:32 +00:00
Martyn Inglis
9a7788a6f5
Allowing overrides on a per environment basis
2016-03-17 11:47:44 +00:00
Rebecca Law
bd26c4740c
Merge branch 'master' into default-stats-to-zero
2016-03-17 11:40:49 +00:00
Rebecca Law
15fac879e3
Merge pull request #162 from alphagov/platform-admin-role
...
Add platform_admin boolean on the User data model.
2016-03-17 11:33:52 +00:00
Rebecca Law
b7f65feadd
Set default to 0 for the notification_statistics table.
2016-03-17 11:32:55 +00:00
Rebecca Law
bd2d77fec8
Add platform_admin boolean on the User data model.
2016-03-17 10:37:24 +00:00
minglis
e7532d2c64
Merge pull request #158 from alphagov/set-application-name
...
Pass application name in from start scripts
2016-03-16 14:51:50 +00:00
Martyn Inglis
6ceddf0ebf
pep8 fixed
2016-03-16 14:08:25 +00:00
NIcholas Staples
03e2f4a244
Merge pull request #159 from alphagov/validate-number
...
Format and validate phone number
2016-03-16 13:50:27 +00:00
Rebecca Law
4268f8453b
Use the same validation in the endpoint and the task to validate the phone number is ok to send to.
...
Format the phone number before sending it to the sms provider.
2016-03-16 13:36:46 +00:00
Martyn Inglis
27d48a9746
Pass application name in from start scripts
...
- allows logger to log as correct application
2016-03-16 13:25:09 +00:00
minglis
977ac4f566
Merge pull request #157 from alphagov/travis-builds-to-deployment-group
...
Add all deplpyment groups to travis
2016-03-16 10:59:57 +00:00
Martyn Inglis
35f4cca62d
Add all deplpyment groups to travis
2016-03-16 10:56:27 +00:00
NIcholas Staples
1425290eef
Merge pull request #155 from alphagov/notification_api_get_update
...
Update schemas to return more details about the job and template for …
2016-03-16 10:30:09 +00:00
minglis
041ac318d7
Merge pull request #156 from alphagov/codedeploy-scripts-update
...
Updated aws start/stop scripts to handle multiple start/stop scripts
2016-03-16 09:48:33 +00:00
Nicholas Staples
16882961ad
Added check for job in notifications json dump.
2016-03-15 14:57:15 +00:00
Martyn Inglis
001c875d02
Updated aws start/stop scripts to handle multiple start/stop scripts
...
Primarily to handle the two celery processes
2016-03-15 14:51:40 +00:00
Nicholas Staples
356083e8ac
Update schemas to return more details about the job and template for notifications.
2016-03-15 14:24:10 +00:00
Rebecca Law
0be235e551
Merge pull request #153 from alphagov/fix-created-at
...
Fix dates in the models
2016-03-15 09:47:25 +00:00
Rebecca Law
2caea40212
Pass the utcnow function, rather than the result of executing the function.
2016-03-15 09:32:43 +00:00
minglis
c2b2ce3878
Merge pull request #151 from alphagov/order-jobs
...
Order jobs
2016-03-14 16:43:48 +00:00
Martyn Inglis
35b2ec513b
Fixed pep8
2016-03-14 16:37:51 +00:00
Martyn Inglis
b88b0499b9
Order jobs on dashboard page
2016-03-14 16:31:57 +00:00
Martyn Inglis
beb6f7ca57
Order jobs by service
...
- newest first
2016-03-14 16:15:39 +00:00
Rebecca Law
fb24c1d04e
Merge pull request #150 from alphagov/format-auth-errors
...
Format authentication error messages for the client.
2016-03-14 16:15:09 +00:00
Rebecca Law
fe9bf13064
Format authentication error messages for the client.
2016-03-14 15:51:04 +00:00
minglis
1aa6856ec0
Merge pull request #149 from alphagov/client-callbacks
...
SES Callback testing
2016-03-14 14:51:53 +00:00
Martyn Inglis
3192f5f6d1
SES Callback testing
...
- SES/AWS JSON is horrible and not valid.
- JSON in tests did not test accurately what it looked like in reality
- Using very odd looking bytes/strings as input into API which is more accurate
2016-03-14 14:49:02 +00:00
minglis
2982c51e83
Merge pull request #146 from alphagov/client-callbacks
...
Client callbacks
2016-03-14 11:49:10 +00:00
Martyn Inglis
1ff4ebad5c
Merge branch 'master' into client-callbacks
...
Conflicts:
app/notifications/rest.py
tests/app/celery/test_tasks.py
2016-03-14 11:45:21 +00:00
Martyn Inglis
fd973179cc
- Commit session on job update
...
- log at exception level
2016-03-14 11:34:09 +00:00
Rebecca Law
c75bb9c5c3
Merge pull request #148 from alphagov/error-handing
...
Error handing
2016-03-14 09:31:59 +00:00
Rebecca Law
b96b226bad
Log exception
2016-03-11 15:52:28 +00:00
Rebecca Law
123b0ead3a
Replaced first queries with one queries, which throws a NoResultFound.
...
Able to remove many of the None checks as a result of this.
Fixed the tests were needed.
2016-03-11 15:34:20 +00:00
Rebecca Law
ef5969be77
Merge branch 'master' into error-handing
2016-03-11 13:59:16 +00:00
Chris Hill-Scott
ee3f2c3e65
Merge pull request #147 from alphagov/fix-phone-number-matching-restricted-service
...
Be agnostic about format when comparing phone numbers
2016-03-11 13:51:00 +00:00
Chris Hill-Scott
d6cf15469f
Be agnostic about format when comparing phone #s
...
If a service is in restricted mode then a user can’t send messages to anyone
other than themselves and members of their team. To do this the API has to
compare the numbers they are sending to with those of their team members.
It will (falsely) say the numbers do not match if they are in a different
format, eg 07700 900849 vs +447700900849
This commit uses the code we use elsewhere for formatting phone numbers to
make sure that both numbers are in a consistent format before doing a
comparison.
I have a strong preference for doing it this way, rather than formatting numbers
before we store them:
1. https://en.wikipedia.org/wiki/Robustness_principle
2. It’s confusing to a user to see their own phone number formatted in a
different way to that which they entered it, and the alternative, storing
the phone number in two different formats is grim
2016-03-11 13:19:54 +00:00
Rebecca Law
e055590b07
Changed db queries to use one, which throws NoResultFound exception, this exception is dealt with in our error handlers.
...
Now a lot of the if none checks can be removed.
2016-03-11 12:39:55 +00:00
Martyn Inglis
62a7b8bcd0
Update notification status by message reference
...
- SES sends a reference to allow us to identify the notification
- use this to update status
If source of email is one of our internal emails (invites or validations) - don't try and update a notification.
2016-03-11 10:19:40 +00:00
Martyn Inglis
901d04605f
Ad a reference to the model
...
- used if 3rd party needs to record an ID for reconciliation purposes
2016-03-11 09:40:35 +00:00
Martyn Inglis
8d9b5b172b
Changed exception type to ValueError
2016-03-11 09:06:22 +00:00
Martyn Inglis
58c78f864b
Changed path to decode error for 3.4.x compatibility
2016-03-11 09:00:02 +00:00