Skip to content

milestones.json and labels.json return html page instead of JSON

Summary

We noticed today that our gitlab instance upgraded to 10.3.2 no longer allows us to select milestones or labels from the issue page. The milestone dropdown is empty and says "No Milestone" and if we click Edit for Labels there is a search box with "undefined" appearing underneath.

Steps to reproduce

  1. Open any issue
  2. Click on Edit beside Milestone or Labels

Example Project

This is on our own self-hosted gitlab.

What is the current bug behavior?

No milestones appear, and under labels it says undefined.

What is the expected correct behavior?

I should see a list of milestones, or labels.

Relevant logs and/or screenshots

If I open the Chrome developer tools and look at the network requests, the requests it's making to /some-group/some-project/milestones.json is return a HTML page response instead of a JSON object. Same with the labels request.

I can attach a screenshot if it helps. Here is a log of a milestone request.

Request URL:https://git.example.com/groupName/projectName/milestones.json
Request Method:GET

Response Headers:
cache-control:max-age=0, private, must-revalidate
content-type:text/html; charset=utf-8
date:Tue, 02 Jan 2018 16:29:01 GMT
etag:W/"16c9b94ef0b4cfb843c85d494b73de28"
server:nginx
status:200
strict-transport-security:max-age=31536000
x-content-type-options:nosniff
x-frame-options:DENY
x-request-id:bab71337-86ef-4035-838b-00fb3f2d204f
x-runtime:0.099707
x-ua-compatible:IE=edge
x-xss-protection:1; mode=block

Output of checks

Results of GitLab environment info

Expand for output related to GitLab environment info

System information System: Debian 8.10 Current User: git Using RVM: no Ruby Version: 2.3.5p376 Gem Version: 2.6.13 Bundler Version:1.13.7 Rake Version: 12.3.0 Redis Version: 3.2.11 Git Version: 2.14.3 Sidekiq Version:5.0.4 Go Version: go1.7.4 linux/amd64

GitLab information Version: 10.3.2 Revision: 5fbc5f2 Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: postgresql URL: https://git.nerdsonsite.com HTTP Clone URL: https://git.nerdsonsite.com/some-group/some-project.git SSH Clone URL: git@git.nerdsonsite.com:some-group/some-project.git Using LDAP: no Using Omniauth: yes Omniauth Providers: google_oauth2

GitLab Shell Version: 5.10.2 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

Expand for output related to the GitLab application check

Checking GitLab Shell ...

GitLab Shell version >= 5.10.2 ? ... OK (5.10.2) 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: ... 4/2 ... ok 4/5 ... ok 4/6 ... ok 4/7 ... ok 4/8 ... ok 4/9 ... ok 4/11 ... ok 4/14 ... ok 4/17 ... ok 13/18 ... ok 13/19 ... ok 13/20 ... ok 13/21 ... ok 13/22 ... ok 13/23 ... ok 13/24 ... ok 13/25 ... ok 13/26 ... ok 13/27 ... ok 13/28 ... ok 13/29 ... ok 13/30 ... ok 13/31 ... ok 13/32 ... repository is empty 13/33 ... ok 13/34 ... ok 13/35 ... repository is empty 13/36 ... ok 13/37 ... ok 13/38 ... ok 13/39 ... ok 13/40 ... ok 13/41 ... ok 13/42 ... ok 18/43 ... ok 18/44 ... ok 3/45 ... ok 20/46 ... repository is empty 9/47 ... ok 4/48 ... ok 9/49 ... ok 3/50 ... ok 4/51 ... ok 9/52 ... ok 9/53 ... ok 9/54 ... ok 9/55 ... ok 9/56 ... ok 9/57 ... ok 11/58 ... ok 15/59 ... ok 26/60 ... repository is empty 9/61 ... ok 9/62 ... ok 13/63 ... ok 9/64 ... ok 9/66 ... ok 3/67 ... ok 9/68 ... ok 4/69 ... ok 9/70 ... ok 3/71 ... ok 3/72 ... ok 34/73 ... ok 34/74 ... ok 9/75 ... repository is empty 9/76 ... ok 3/77 ... ok 13/78 ... ok 38/79 ... ok 13/80 ... ok 4/81 ... ok 9/84 ... ok 9/85 ... ok 9/86 ... ok 9/87 ... ok 9/88 ... ok 9/89 ... ok 9/90 ... ok 9/91 ... ok 9/92 ... ok 9/93 ... ok 9/94 ... ok 9/95 ... ok 9/96 ... ok 9/97 ... ok 9/98 ... ok 9/99 ... ok 9/100 ... ok 9/101 ... ok 9/102 ... ok 9/103 ... ok 9/104 ... ok 9/105 ... ok 9/106 ... ok 9/107 ... ok 9/108 ... ok 9/109 ... ok 9/110 ... ok 9/111 ... ok 3/112 ... repository is empty 4/113 ... ok 9/114 ... ok 9/115 ... ok 9/116 ... ok 9/117 ... ok 9/118 ... ok 9/119 ... ok 9/120 ... ok 9/121 ... ok 9/122 ... ok 9/123 ... ok 9/124 ... ok 9/125 ... ok 9/126 ... repository is empty 9/127 ... ok 9/128 ... ok 9/129 ... ok 9/130 ... ok 9/131 ... ok 9/132 ... ok 9/133 ... ok 9/134 ... ok 9/135 ... ok 9/136 ... ok 9/137 ... ok 9/138 ... ok 9/139 ... ok 9/140 ... ok 9/141 ... ok 9/142 ... ok 9/143 ... ok 9/144 ... ok 9/145 ... ok 9/146 ... ok 13/147 ... ok 4/148 ... ok 4/150 ... ok 9/151 ... ok 9/153 ... ok 9/154 ... ok 9/155 ... ok 38/157 ... ok 38/158 ... ok 15/159 ... ok 4/160 ... ok 4/161 ... repository is empty 4/163 ... ok 4/164 ... ok 4/165 ... ok 3/167 ... ok 9/168 ... ok 4/169 ... ok 4/170 ... ok 3/171 ... repository is empty 9/172 ... ok 4/173 ... ok 9/174 ... ok 4/175 ... ok 9/176 ... ok 4/177 ... ok 4/178 ... repository is empty 4/179 ... ok 4/180 ... repository is empty 3/181 ... ok 4/182 ... repository is empty 4/183 ... repository is empty 13/184 ... ok 4/185 ... ok 56/186 ... ok 56/187 ... ok 4/188 ... ok 4/189 ... repository is empty 4/190 ... 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

Checking Reply by email ...

IMAP server credentials are correct? ... yes Init.d configured correctly? ... skipped MailRoom running? ... skipped

Checking Reply by email ... Finished

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: ... 4/2 ... yes 4/5 ... yes 4/6 ... yes 4/7 ... yes 4/8 ... yes 4/9 ... yes 4/11 ... yes 4/14 ... yes 4/17 ... yes 13/18 ... yes 13/19 ... yes 13/20 ... yes 13/21 ... yes 13/22 ... yes 13/23 ... yes 13/24 ... yes 13/25 ... yes 13/26 ... yes 13/27 ... yes 13/28 ... yes 13/29 ... yes 13/30 ... yes 13/31 ... yes 13/32 ... yes 13/33 ... yes 13/34 ... yes 13/35 ... yes 13/36 ... yes 13/37 ... yes 13/38 ... yes 13/39 ... yes 13/40 ... yes 13/41 ... yes 13/42 ... yes 18/43 ... yes 18/44 ... yes 3/45 ... yes 20/46 ... yes 9/47 ... yes 4/48 ... yes 9/49 ... yes 3/50 ... yes 4/51 ... yes 9/52 ... yes 9/53 ... yes 9/54 ... yes 9/55 ... yes 9/56 ... yes 9/57 ... yes 11/58 ... yes 15/59 ... yes 26/60 ... yes 9/61 ... yes 9/62 ... yes 13/63 ... yes 9/64 ... yes 9/66 ... yes 3/67 ... yes 9/68 ... yes 4/69 ... yes 9/70 ... yes 3/71 ... yes 3/72 ... yes 34/73 ... yes 34/74 ... yes 9/75 ... yes 9/76 ... yes 3/77 ... yes 13/78 ... yes 38/79 ... yes 13/80 ... yes 4/81 ... yes 9/84 ... yes 9/85 ... yes 9/86 ... yes 9/87 ... yes 9/88 ... yes 9/89 ... yes 9/90 ... yes 9/91 ... yes 9/92 ... yes 9/93 ... yes 9/94 ... yes 9/95 ... yes 9/96 ... yes 9/97 ... yes 9/98 ... yes 9/99 ... yes 9/100 ... yes 9/101 ... yes 9/102 ... yes 9/103 ... yes 9/104 ... yes 9/105 ... yes 9/106 ... yes 9/107 ... yes 9/108 ... yes 9/109 ... yes 9/110 ... yes 9/111 ... yes 3/112 ... yes 4/113 ... yes 9/114 ... yes 9/115 ... yes 9/116 ... yes 9/117 ... yes 9/118 ... yes 9/119 ... yes 9/120 ... yes 9/121 ... yes 9/122 ... yes 9/123 ... yes 9/124 ... yes 9/125 ... yes 9/126 ... yes 9/127 ... yes 9/128 ... yes 9/129 ... yes 9/130 ... yes 9/131 ... yes 9/132 ... yes 9/133 ... yes 9/134 ... yes 9/135 ... yes 9/136 ... yes 9/137 ... yes 9/138 ... yes 9/139 ... yes 9/140 ... yes 9/141 ... yes 9/142 ... yes 9/143 ... yes 9/144 ... yes 9/145 ... yes 9/146 ... yes 13/147 ... yes 4/148 ... yes 4/150 ... yes 9/151 ... yes 9/153 ... yes 9/154 ... yes 9/155 ... yes 38/157 ... yes 38/158 ... yes 15/159 ... yes 4/160 ... yes 4/161 ... yes 4/163 ... yes 4/164 ... yes 4/165 ... yes 3/167 ... yes 9/168 ... yes 4/169 ... yes 4/170 ... yes 3/171 ... yes 9/172 ... yes 4/173 ... yes 9/174 ... yes 4/175 ... yes 9/176 ... yes 4/177 ... yes 4/178 ... yes 4/179 ... yes 4/180 ... yes 3/181 ... yes 4/182 ... yes 4/183 ... yes 13/184 ... yes 4/185 ... yes 56/186 ... yes 56/187 ... yes 4/188 ... yes 4/189 ... yes 4/190 ... yes Redis version >= 2.8.0? ... yes Ruby version >= 2.3.5 ? ... yes (2.3.5) Git version >= 2.7.3 ? ... yes (2.14.3) Git user has default SSH configuration? ... yes Active users: ... 27

Checking GitLab ... Finished

Possible fixes

Have not been able to find any possible fixes.

Edited by Arthur Wiebe