If I'd been writing a PR in this form for this commit, it would have looked like:
This is a:
- ✨ New feature - new behaviour has been implemented
- 🐛 Bug fix - existing behaviour has been made to behave
- ♻️ Refactor - the behaviour has not changed, just the implementation
- ✅ Test backfill - tests for existing behaviour were added but the behaviour itself hasn't changed
- ⚙️ Chore - maintenance task, behaviour and implementation haven't changed
- Purpose - Prevents the client app from crashing when the server returns a 500 error without a body. This is a 🚑 critical hotfix to stop the app crashing, we can come back later for a proper fix to the fundamental behaviour (what should happen when there are too few words for the given configuration) later. In that context I've only tested this at the client API service level and this should only be rejected if there are major problems.
- How to check - Go to the main page. Set the minimum word length to 1, then set the maximum word length to 1. You can see the 500 error in the network tab. On the production site this causes client to crash, but now "Something went wrong" shows on the error list instead.
- Issue: textbook/impasse#613
See example PR.