Cannot change board milestone via API

Summary

When a request to update a board's milestone is sent via the API, the board's API does not change from its previous value.

Steps to reproduce

  1. Create a new project
  2. Create a board in that project
  3. Make HTTP request:
PUT /api/v4/projects/{ projectID }/boards/{ boardID }
    
{
    "milestone_id": -3
}

-3 is the value for "started" milestones.

  1. Notice in the response that the milestone field is still null.
  2. Verify in the UI that the milestone has not updated.

Example Project

https://gitlab.com/natemara/issue-board-issues/boards/660055

What is the current bug behavior?

Milestone field is not updated

What is the expected correct behavior?

Milestone field should be updated

Relevant logs and/or screenshots

Screen_Shot_2018-08-28_at_09.28.50

Logs from EE omnibus container:

gitlab_1         | ==> /var/log/gitlab/gitlab-rails/production.log <==
gitlab_1         | Started PUT "/api/v4//projects/43/boards/8" for 172.18.0.1 at 2018-08-28 13:39:30 +0000
gitlab_1         |
gitlab_1         | ==> /var/log/gitlab/gitaly/current <==
gitlab_1         | 2018-08-28_13:39:31.36269 time="2018-08-28T13:39:31Z" level=info msg="finished unary call" grpc.code=OK grpc.meta.client_name=gitlab-web grpc.method=FindDefaultBranchName grpc.request.glRepository=project-43 grpc.request.repoPath=NM46057/board-sync.git grpc.request.repoStorage=default grpc.request.topLevelGroup=NM46057 grpc.service=gitaly.RefService grpc.time_ms=2 peer.address=@ span.kind=server system=grpc
gitlab_1         | 2018-08-28_13:39:31.41808 time="2018-08-28T13:39:31Z" level=info msg="finished unary call" grpc.code=OK grpc.meta.client_name=gitlab-web grpc.method=FindDefaultBranchName grpc.request.glRepository=project-43 grpc.request.repoPath=NM46057/board-sync.git grpc.request.repoStorage=default grpc.request.topLevelGroup=NM46057 grpc.service=gitaly.RefService grpc.time_ms=2 peer.address=@ span.kind=server system=grpc
gitlab_1         | 2018-08-28_13:39:31.42676 time="2018-08-28T13:39:31Z" level=info msg="finished unary call" grpc.code=OK grpc.meta.client_name=gitlab-web grpc.method=FindDefaultBranchName grpc.request.glRepository=project-43 grpc.request.repoPath=NM46057/board-sync.git grpc.request.repoStorage=default grpc.request.topLevelGroup=NM46057 grpc.service=gitaly.RefService grpc.time_ms=2 peer.address=@ span.kind=server system=grpc
gitlab_1         |
gitlab_1         | ==> /var/log/gitlab/gitlab-rails/api_json.log <==
gitlab_1         | {"time":"2018-08-28T13:39:31.519Z","severity":"INFO","duration":720.16,"db":31.86,"view":688.3,"status":200,"method":"PUT","path":"/api/v4/projects/43/boards/8","params":{"milestone_id":null},"host":"localhost","ip":"172.18.0.1","ua":"insomnia/6.0.2","user_id":1,"username":"root","queue_duration":58.63}
gitlab_1         |
gitlab_1         | ==> /var/log/gitlab/gitlab-workhorse/current <==
gitlab_1         | 2018-08-28_13:39:31.52678 localhost @ - - [2018/08/28:13:39:31 +0000] "PUT /api/v4//projects/43/boards/8 HTTP/1.1" 200 1149 "" "insomnia/6.0.2" 0.787
gitlab_1         |
gitlab_1         | ==> /var/log/gitlab/nginx/gitlab_access.log <==
gitlab_1         | 172.18.0.1 - - [28/Aug/2018:13:39:31 +0000] "PUT /api/v4//projects/43/boards/8 HTTP/1.1" 200 1149 "" "insomnia/6.0.2"

Output of checks

This bug happens on GitLab.com, and in an omnibus EE container.

Results of GitLab environment info

System information
System:		
Proxy:		https_proxy: http://mitmproxy:8080/
		http_proxy: http://mitmproxy:8080/
		no_proxy: localhost 127.0.0.1
Current User:	git
Using RVM:	no
Ruby Version:	2.4.4p296
Gem Version:	2.7.6
Bundler Version:1.16.2
Rake Version:	12.3.1
Redis Version:	3.2.11
Git Version:	2.18.0
Sidekiq Version:5.1.3
Go Version:	unknown

GitLab information
Version:	11.2.1-ee
Revision:	df8846c
Directory:	/opt/gitlab/embedded/service/gitlab-rails
DB Adapter:	postgresql
DB Version:	9.6.8
URL:		http://gitlab
HTTP Clone URL:	http://gitlab/some-group/some-project.git
SSH Clone URL:	git@gitlab:some-group/some-project.git
Elasticsearch:	no
Geo:		no
Using LDAP:	no
Using Omniauth:	no

GitLab Shell
Version:	8.1.1
Repository storage paths:
- default: 	/var/opt/gitlab/git-data/repositories
Hooks:		/opt/gitlab/embedded/service/gitlab-shell/hooks
Git:		/opt/gitlab/embedded/bin/git

Results of GitLab application Check

Checking GitLab Shell ...

GitLab Shell version >= 8.1.1 ? ... OK (8.1.1)
Repo base directory exists?
default... yes
Repo storage directories are symlinks?
default... no
Repo paths owned by git:root, or git:git?
default... yes
Repo paths access is drwxrws---?
default... yes
hooks directories in repos are links: ...
2/1 ... repository is empty
2/2 ... repository is empty
1/3 ... ok
1/4 ... repository is empty
1/5 ... repository is empty
1/6 ... repository is empty
1/7 ... repository is empty
1/8 ... repository is empty
1/9 ... repository is empty
1/10 ... repository is empty
1/11 ... repository is empty
1/12 ... repository is empty
1/13 ... repository is empty
1/14 ... repository is empty
1/15 ... repository is empty
1/16 ... repository is empty
1/17 ... repository is empty
1/18 ... repository is empty
1/19 ... repository is empty
1/20 ... repository is empty
1/21 ... repository is empty
1/22 ... repository is empty
1/23 ... repository is empty
1/24 ... repository is empty
1/25 ... repository is empty
1/26 ... repository is empty
1/27 ... repository is empty
1/28 ... repository is empty
1/29 ... repository is empty
1/30 ... repository is empty
1/31 ... repository is empty
1/32 ... repository is empty
1/33 ... repository is empty
1/34 ... repository is empty
1/35 ... repository is empty
1/36 ... repository is empty
1/37 ... repository is empty
1/38 ... repository is empty
1/39 ... repository is empty
1/40 ... repository is empty
1/41 ... repository is empty
2/42 ... repository is empty
2/43 ... repository is empty
Running /opt/gitlab/embedded/service/gitlab-shell/bin/check
Check GitLab API access: OK
Redis available via internal API: OK

Access to /var/opt/gitlab/.ssh/authorized_keys: OK
gitlab-shell self-check successful

Checking GitLab Shell ... Finished

Checking Sidekiq ...

Running? ... yes
Number of Sidekiq processes ... 1

Checking Sidekiq ... Finished

Reply by email is disabled in config/gitlab.yml
Checking LDAP ...

LDAP is disabled in config/gitlab.yml

Checking LDAP ... Finished

Checking GitLab ...

Git configured correctly? ... yes
Database config exists? ... yes
All migrations up? ... yes
Database contains orphaned GroupMembers? ... no
GitLab config exists? ... yes
GitLab config up to date? ... yes
Log directory writable? ... yes
Tmp directory writable? ... yes
Uploads directory exists? ... yes
Uploads directory has correct permissions? ... yes
Uploads directory tmp has correct permissions? ... yes
Init script exists? ... skipped (omnibus-gitlab has no init script)
Init script up-to-date? ... skipped (omnibus-gitlab has no init script)
Projects have namespace: ...
2/1 ... yes
2/2 ... yes
1/3 ... yes
1/4 ... yes
1/5 ... yes
1/6 ... yes
1/7 ... yes
1/8 ... yes
1/9 ... yes
1/10 ... yes
1/11 ... yes
1/12 ... yes
1/13 ... yes
1/14 ... yes
1/15 ... yes
1/16 ... yes
1/17 ... yes
1/18 ... yes
1/19 ... yes
1/20 ... yes
1/21 ... yes
1/22 ... yes
1/23 ... yes
1/24 ... yes
1/25 ... yes
1/26 ... yes
1/27 ... yes
1/28 ... yes
1/29 ... yes
1/30 ... yes
1/31 ... yes
1/32 ... yes
1/33 ... yes
1/34 ... yes
1/35 ... yes
1/36 ... yes
1/37 ... yes
1/38 ... yes
1/39 ... yes
1/40 ... yes
1/41 ... yes
2/42 ... yes
2/43 ... yes
Redis version >= 2.8.0? ... yes
Ruby version >= 2.3.5 ? ... yes (2.4.4)
Git version >= 2.9.5 ? ... yes (2.18.0)
Git user has default SSH configuration? ... yes
Active users: ... 2
Elasticsearch version 5.1 - 5.5? ... skipped (elasticsearch is disabled)

Checking GitLab ... Finished
Assignee Loading
Time tracking Loading