Skip to content

Commit

Permalink
note about axior error messages
Browse files Browse the repository at this point in the history
  • Loading branch information
Beej Jorgensen committed Sep 26, 2018
1 parent 0b99047 commit 8168019
Showing 1 changed file with 20 additions and 4 deletions.
24 changes: 20 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -222,8 +222,23 @@ MVP as soon as you can and get working the list of features.
## Troubleshooting
### `/admin` gives nondescript `500` error
### Nondescript `500` error
* [JavaScript] If this is an axios call, you can get more information by
catching the error and printing out `error.response` instead of just printing
`error`:
```javascript
axios.post(`${...}/api/registration`, this.state)
.then(response => {
console.log(response)
})
.catch(error => {
console.log(error.response)
});
```

* Set up whitenoise or a `STATIC_ROOT`.

* Run `create_world.py` on the server:
```
heroku run python manage.py shell
Expand Down Expand Up @@ -305,7 +320,9 @@ This one remains unsolved.
Hardcoding the app ID into the app (not using `config()`) seems to be a
workaround.

### JavaScript: username and password appearing in the URL
### Username and password appearing in the URL

[JavaScript]

If you log in and your URL changes to:

Expand Down Expand Up @@ -338,5 +355,4 @@ then add this line to **the bottom of the file**:
django_heroku.settings(locals())

del DATABASES['default']['OPTIONS']['sslmode'] # <-- Add this line
```

```

0 comments on commit 8168019

Please sign in to comment.