Skip to content

GitLab

  • Menu
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • G gitlabhq1
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 21
    • Issues 21
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 12
    • Merge requests 12
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Infrastructure Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • gpt
  • large_projects
  • gitlabhq1
  • Issues
  • #6953

Closed
Open
Created 11 years ago by Administrator@rootOwner
  • New issue

  • Report abuse

  • New issue

  • Report abuse

Closing a merge request through API gives mr page a 500 error

Closed

Closing a merge request through API gives mr page a 500 error

Created by: blackeyedboy

If I do send an API call to close a merge request (with state_event: "close" in parameters), here is what i get in the logs :

Parameters: {"project_id"=>"dev/testing-project", "id"=>"13"}
Started PUT "/api/v3/projects/17/merge_request/136" for 127.0.0.1 at 2014-05-10 18:13:01 +0200
Completed 200 OK in 242ms (Views: 157.6ms | ActiveRecord: 15.4ms)

Completed 200, everything seems fine.

But then, if I get to the merge request page, I got a 500 error. Here are the logs :

Started GET "/dev/testing-project/merge_requests/13" for 127.0.0.1 at 2014-05-10 18:14:41 +0200
Processing by Projects::MergeRequestsController#show as HTML
Parameters: {"project_id"=>"dev/testing-project", "id"=>"13"}
Completed 500 Internal Server Error in 88ms
ActionView::Template::Error (undefined method `author' for nil:NilClass):
11:
12: - if @merge_request.closed?
13: %h4
14: Closed by #{link_to_member(@project, @merge_request.closed_event.author, avatar: false)}
15: #{time_ago_with_tooltip(@merge_request.closed_event.created_at)}
16: %p Changes was not merged into target branch
17:

Checks : Gitlab 6.8.1 3197990with tests full ok.

System information
System:     
Current User:   git
Using RVM:  no
Ruby Version:   2.0.0p353
Gem Version:    2.0.14
Bundler Version:1.6.2
Rake Version:   10.1.1
Sidekiq Version:2.17.0

GitLab information
Version:    6.8.1
Revision:   3197990

GitLab Shell
Version:    1.9.3

Linked issues
...

    Related merge requests

    • You're only seeing other activity in the feed. To add a comment, switch to one of the following options.
    Please register or sign in to reply
    0 Assignees
    Assign to
    Milestone
    No milestone
    None
    None
    Time tracking
    Due date
    None
    None
    1
    Labels
    API
    Assign labels
    • No matching results
    • Manage project labels
    Confidentiality
    Not confidential

    You are going to turn on confidentiality. Only team members with at least Reporter access will be able to see and leave comments on the issue.

    Lock issue
    Unlocked
    participants
    Reference: