Content
View differences
Updated by Christophe Bliard almost 2 years ago
### Steps to reproduce
1. Get basic auth token for your account in community OP instance.
2. Make a request with curl.
```bash
curl -X PATCH "https://community.openproject.org/api/v3/work_packages/35643" -u "apikey:secretapikey" -H "Content-Type:application/hal+json" --data '{"lockVersion":2,"_links":{"status":{"href":"/api/v3/statuses/10"}}}'
```
### What is the buggy behavior?
Server error. 500
```json
{"_type":"Error","errorIdentifier":"urn:openproject-org:api:v3:errors:InternalServerError","message":"An internal error has occurred. can't convert String into Hash"}
```
### What is the expected behavior?
405 or similar error, processed by OP with error message as I don't have access to exact that ticket at community instance. Actually, it doesn't matter as param processing goes earlier.
### **Logs**
```text
F, [2024-07-01T14:47:16.825396 #1] FATAL -- :
TypeError (can't convert String into Hash):
lib/api/v3/work_packages/parse_params_service.rb:43:in `Hash'
lib/api/v3/work_packages/parse_params_service.rb:43:in `parse_attributes'
app/services/api/parse_resource_params_service.rb:50:in `call'
lib/api/utilities/endpoints/bodied.rb:103:in `parse'
lib/api/utilities/endpoints/bodied.rb:89:in `block in mount'
```
### Environment information
Docker development container. Op
**OpenProject installation type**
* [ ] Hosted cloud edition
* [ ] Packaged installation
* What distribution?
* [ ] Docker All-in-one container
* [x] Docker-compose installation
* [x] Other (please specify)
**OpenProject version**
_v14.1.1 and community instance._
**Browser**
* [ ] Chrome
* [ ] Firefox
* [ ] Safari
* [ ] Mobile Safari
* [x] Other (please specify)
**Language**
_English_
1. Get basic auth token for your account in community OP instance.
2. Make a request with curl.
```bash
curl -X PATCH "https://community.openproject.org/api/v3/work_packages/35643" -u "apikey:secretapikey" -H "Content-Type:application/hal+json" --data '{"lockVersion":2,"_links":{"status":{"href":"/api/v3/statuses/10"}}}'
```
### What is the buggy behavior?
Server error. 500
```json
{"_type":"Error","errorIdentifier":"urn:openproject-org:api:v3:errors:InternalServerError","message":"An internal error has occurred. can't convert String into Hash"}
```
### What is the expected behavior?
405 or similar error, processed by OP with error message as I don't have access to exact that ticket at community instance. Actually, it doesn't matter as param processing goes earlier.
### **Logs**
```text
F, [2024-07-01T14:47:16.825396 #1] FATAL -- :
TypeError (can't convert String into Hash):
lib/api/v3/work_packages/parse_params_service.rb:43:in `Hash'
lib/api/v3/work_packages/parse_params_service.rb:43:in `parse_attributes'
app/services/api/parse_resource_params_service.rb:50:in `call'
lib/api/utilities/endpoints/bodied.rb:103:in `parse'
lib/api/utilities/endpoints/bodied.rb:89:in `block in mount'
### Environment information
Docker development container. Op
**OpenProject installation type**
* [ ] Hosted cloud edition
* [ ] Packaged installation
* What distribution?
* [ ] Docker All-in-one container
* [x] Docker-compose installation
* [x] Other (please specify)
**OpenProject version**
_v14.1.1 and community instance._
**Browser**
* [ ] Chrome
* [ ] Firefox
* [ ] Safari
* [ ] Mobile Safari
* [x] Other (please specify)
**Language**
_English_