Content
View differences
Updated by Eric Schubert 10 months ago
### Before filing a report
_Before you file a report, please ensure you are running the latest version of OpenProject and_
_have searched for similar bug reports._
### Steps to reproduce
_Please write down the steps to reproduce. Try to write down all necessary preconditions (what permissions do you have, are other users involved?). Example:_
1. Log into OpenProject or auth through the API
2. GET request to `project/{id}/work_packages?select=total` endpoint for a project with 0 work packages (filter dependent - if the filter responses with an empty set, this will reproduce)
### What is the buggy behavior?
_Please describe the bug in as much detail as possible. Example:_
* `?select=total` on empty set will cause the following error / server-side failure:
> {
> "\_type": "Error",
> "errorIdentifier": "urn:openproject-org:api:v3:errors:InternalServerError",
> "message": "An internal error has occurred.undefined method \`\[\]' for nil"
> }
### What is the expected behavior?
_Describe how the application should behave like. Example:_
1. No failure! It should return `{ "total" : 0 }`
### Environment information
_Please check and fill out the following details to help us identify in what versions and distributions of OpenProject the error occurs_
**OpenProject installation type**
* Hosted cloud edition
**Browser**
* [x] Chrome
* [x] Firefox
* [ ] Safari
* [ ] Mobile Safari
* [ ] Other (please specify)
**Operating System**
* [x] Windows
* [ ] Mac OS X
* [ ] Mobile iOS
* [ ] Mobile Android
* [ ] Linux (please specify distro)
* [ ] Chrome OS
* [ ] Other (please specify)
**Language**
_English_
### Hints for QA
* the endpoint to test this is `GET /api/v3/projects/:id/work_packages?select=total`
* it can be executed directly in the browser with the id of any project, that has or has no work packages
_Before you file a report, please ensure you are running the latest version of OpenProject and_
_have searched for similar bug reports._
### Steps to reproduce
_Please write down the steps to reproduce. Try to write down all necessary preconditions (what permissions do you have, are other users involved?). Example:_
1. Log into OpenProject or auth through the API
2. GET request to `project/{id}/work_packages?select=total` endpoint for a project with 0 work packages (filter dependent - if the filter responses with an empty set, this will reproduce)
### What is the buggy behavior?
_Please describe the bug in as much detail as possible. Example:_
* `?select=total` on empty set will cause the following error / server-side failure:
> {
> "\_type": "Error",
> "errorIdentifier": "urn:openproject-org:api:v3:errors:InternalServerError",
> "message": "An internal error has occurred.undefined method \`\[\]' for nil"
> }
### What is the expected behavior?
_Describe how the application should behave like. Example:_
1. No failure! It should return `{ "total" : 0 }`
### Environment information
_Please check and fill out the following details to help us identify in what versions and distributions of OpenProject the error occurs_
**OpenProject installation type**
* Hosted cloud edition
**Browser**
* [x] Chrome
* [x] Firefox
* [ ] Safari
* [ ] Mobile Safari
* [ ] Other (please specify)
**Operating System**
* [x] Windows
* [ ] Mac OS X
* [ ] Mobile iOS
* [ ] Mobile Android
* [ ] Linux (please specify distro)
* [ ] Chrome OS
* [ ] Other (please specify)
**Language**
_English_
### Hints for QA
* the endpoint to test this is `GET /api/v3/projects/:id/work_packages?select=total`
* it can be executed directly in the browser with the id of any project, that has or has no work packages