Cannot merge MR after commit #0aff29f9
Summary
Cannot merge MR on current master.
Steps to reproduce
production server. use master code. cannot merge any MR
Example Project
What is the current bug behavior?
cannot merge and show GitLab: API is not accessible
What is the expected correct behavior?
MR gets merged.
Relevant logs and/or screenshots
error log below:
Started POST "/api/v4/internal/allowed" for 127.0.0.1 at 2017-10-16 18:02:51 +0800
TypeError (no implicit conversion of Array into String):
/usr/local/lib/ruby/2.3.0/open3.rb:199:in `spawn'
/usr/local/lib/ruby/2.3.0/open3.rb:199:in `popen_run'
/usr/local/lib/ruby/2.3.0/open3.rb:95:in `popen3'
/home/git/gitlab/lib/gitlab/git/popen.rb:21:in `popen'
/home/git/gitlab/lib/gitlab/git/rev_list.rb:31:in `execute'
/home/git/gitlab/lib/gitlab/git/rev_list.rb:25:in `missed_ref'
/home/git/gitlab/lib/gitlab/checks/force_push.rb:19:in `block in force_push?'
/home/git/gitlab/lib/gitlab/gitaly_client.rb:165:in `block (2 levels) in migrate'
/home/git/gitlab/lib/gitlab/gitaly_client.rb:205:in `allow_n_plus_1_calls'
/home/git/gitlab/lib/gitlab/gitaly_client.rb:161:in `block in migrate'
/home/git/gitlab/lib/gitlab/metrics/influx_db.rb:92:in `measure'
/home/git/gitlab/lib/gitlab/gitaly_client.rb:159:in `migrate'
/home/git/gitlab/lib/gitlab/checks/force_push.rb:10:in `force_push?'
/home/git/gitlab/lib/gitlab/checks/change_access.rb:125:in `forced_push?'
/home/git/gitlab/lib/gitlab/checks/change_access.rb:64:in `protected_branch_checks'
/home/git/gitlab/lib/gitlab/checks/change_access.rb:58:in `branch_checks'
/home/git/gitlab/lib/gitlab/checks/change_access.rb:37:in `exec'
/home/git/gitlab/lib/gitlab/git_access.rb:215:in `check_single_change_access'
/home/git/gitlab/lib/gitlab/git_access.rb:204:in `block in check_change_access!'
/home/git/gitlab/lib/gitlab/changes_list.rb:12:in `each'
/home/git/gitlab/lib/gitlab/changes_list.rb:12:in `each'
/home/git/gitlab/lib/gitlab/git_access.rb:201:in `check_change_access!'
/home/git/gitlab/lib/gitlab/git_access.rb:182:in `check_push_access!'
/home/git/gitlab/lib/gitlab/git_access.rb:52:in `check'
/home/git/gitlab/lib/api/internal.rb:46:in `block (2 levels) in <class:Internal>'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/endpoint.rb:57:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/endpoint.rb:57:in `block (2 levels) in generate_api_method'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.8/lib/active_support/notifications.rb:166:in `instrument'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/endpoint.rb:56:in `block in generate_api_method'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/endpoint.rb:262:in `block in run'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.8/lib/active_support/notifications.rb:166:in `instrument'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/endpoint.rb:243:in `run'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/endpoint.rb:313:in `block in build_stack'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/middleware/base.rb:31:in `call!'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/middleware/base.rb:24:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/middleware/base.rb:31:in `call!'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/middleware/base.rb:24:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape_logging-1.7.0/lib/grape_logging/middleware/request_logger.rb:60:in `block in call!'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape_logging-1.7.0/lib/grape_logging/middleware/request_logger.rb:58:in `catch'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape_logging-1.7.0/lib/grape_logging/middleware/request_logger.rb:58:in `call!'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/middleware/base.rb:24:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-oauth2-1.2.3/lib/rack/oauth2/server/resource.rb:20:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-oauth2-1.2.3/lib/rack/oauth2/server/resource/bearer.rb:8:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/middleware/error.rb:34:in `block in call!'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/middleware/error.rb:33:in `catch'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/middleware/error.rb:33:in `call!'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/middleware/base.rb:24:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/head.rb:13:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/endpoint.rb:227:in `call!'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/endpoint.rb:221:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/router/route.rb:72:in `exec'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/router.rb:119:in `process_route'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/router.rb:74:in `block in identity'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/router.rb:93:in `transaction'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/router.rb:72:in `identity'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/router.rb:57:in `block in call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/router.rb:135:in `with_optimization'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/router.rb:56:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/api.rb:119:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/api.rb:45:in `call!'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/grape-1.0.0/lib/grape/api.rb:40:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/routing/mapper.rb:51:in `serve'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/journey/router.rb:43:in `block in serve'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/journey/router.rb:30:in `each'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/journey/router.rb:30:in `serve'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/routing/route_set.rb:817:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/peek-performance_bar-1.3.0/lib/peek/views/performance_bar/process_utilization.rb:120:in `call'
/home/git/gitlab/lib/gitlab/middleware/multipart.rb:93:in `call'
/home/git/gitlab/lib/gitlab/request_profiler/middleware.rb:14:in `call'
/home/git/gitlab/lib/gitlab/middleware/go.rb:17:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/flipper-0.10.2/lib/flipper/middleware/memoizer.rb:55:in `call'
/home/git/gitlab/lib/gitlab/etag_caching/middleware.rb:11:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/warden-1.2.6/lib/warden/manager.rb:35:in `block in call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/warden-1.2.6/lib/warden/manager.rb:34:in `catch'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/warden-1.2.6/lib/warden/manager.rb:34:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-cors-0.4.0/lib/rack/cors.rb:80:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-attack-4.4.1/lib/rack/attack.rb:107:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/etag.rb:24:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/conditionalget.rb:38:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/head.rb:13:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/middleware/params_parser.rb:27:in `call'
/home/git/gitlab/lib/gitlab/middleware/read_only.rb:30:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/middleware/flash.rb:260:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/session/abstract/id.rb:225:in `context'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/session/abstract/id.rb:220:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/middleware/cookies.rb:560:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/activerecord-4.2.8/lib/active_record/query_cache.rb:36:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/activerecord-4.2.8/lib/active_record/connection_adapters/abstract/connection_pool.rb:653:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/middleware/callbacks.rb:29:in `block in call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.8/lib/active_support/callbacks.rb:88:in `__run_callbacks__'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.8/lib/active_support/callbacks.rb:778:in `_run_call_callbacks'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.8/lib/active_support/callbacks.rb:81:in `run_callbacks'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/middleware/callbacks.rb:27:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/middleware/remote_ip.rb:78:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/middleware/debug_exceptions.rb:17:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/middleware/show_exceptions.rb:30:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/railties-4.2.8/lib/rails/rack/logger.rb:38:in `call_app'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/railties-4.2.8/lib/rails/rack/logger.rb:20:in `block in call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.8/lib/active_support/tagged_logging.rb:68:in `block in tagged'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.8/lib/active_support/tagged_logging.rb:26:in `tagged'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.8/lib/active_support/tagged_logging.rb:68:in `tagged'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/railties-4.2.8/lib/rails/rack/logger.rb:20:in `call'
/home/git/gitlab/lib/gitlab/request_context.rb:18:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/request_store-1.3.1/lib/request_store/middleware.rb:9:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/actionpack-4.2.8/lib/action_dispatch/middleware/request_id.rb:21:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/methodoverride.rb:22:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/runtime.rb:18:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/lock.rb:17:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/sendfile.rb:113:in `call'
/home/git/gitlab/lib/gitlab/metrics/requests_rack_middleware.rb:27:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/sentry-raven-2.5.3/lib/raven/integrations/rack.rb:50:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/railties-4.2.8/lib/rails/engine.rb:518:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/railties-4.2.8/lib/rails/application.rb:165:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/railties-4.2.8/lib/rails/railtie.rb:194:in `public_send'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/railties-4.2.8/lib/rails/railtie.rb:194:in `method_missing'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/urlmap.rb:66:in `block in call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/urlmap.rb:50:in `each'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/rack-1.6.8/lib/rack/urlmap.rb:50:in `call'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/unicorn-5.1.0/lib/unicorn/http_server.rb:562:in `process_client'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/unicorn-worker-killer-0.4.4/lib/unicorn/worker_killer.rb:52:in `process_client'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/unicorn-5.1.0/lib/unicorn/http_server.rb:658:in `worker_loop'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/unicorn-5.1.0/lib/unicorn/http_server.rb:508:in `spawn_missing_workers'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/unicorn-5.1.0/lib/unicorn/http_server.rb:519:in `maintain_worker_count'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/unicorn-5.1.0/lib/unicorn/http_server.rb:283:in `join'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/gems/unicorn-5.1.0/bin/unicorn_rails:209:in `<top (required)>'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/bin/unicorn_rails:22:in `load'
/home/git/gitlab/vendor/bundle/ruby/2.3.0/bin/unicorn_rails:22:in `<top (required)>'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/lib/bundler/cli/exec.rb:74:in `load'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/lib/bundler/cli/exec.rb:74:in `kernel_load'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/lib/bundler/cli/exec.rb:27:in `run'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/lib/bundler/cli.rb:362:in `exec'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/lib/bundler/vendor/thor/lib/thor/invocation.rb:126:in `invoke_command'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/lib/bundler/vendor/thor/lib/thor.rb:387:in `dispatch'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/lib/bundler/cli.rb:22:in `dispatch'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/lib/bundler/vendor/thor/lib/thor/base.rb:466:in `start'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/lib/bundler/cli.rb:13:in `start'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/exe/bundle:30:in `block in <top (required)>'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/lib/bundler/friendly_errors.rb:121:in `with_friendly_errors'
/usr/local/lib/ruby/gems/2.3.0/gems/bundler-1.15.4/exe/bundle:22:in `<top (required)>'
/usr/local/bin/bundle:22:in `load'
/usr/local/bin/bundle:22:in `<main>'
details
after commit of #0aff29f9 witch gitlab choose to use gitaly to merge MR,but
in production mode ,master code feature was not default turn on so https://gitlab.com/gitlab-org/gitlab-ce/blob/master/lib/gitlab/checks/force_push.rb#L11
gets fales
.
witch lead to run https://gitlab.com/gitlab-org/gitlab-ce/blob/master/lib/gitlab/git/rev_list.rb#L25
and throw exec failed.
Possible fixes
enable GITALY_FEATURE_DEFAULT_ON=1
from master or merge gitaly to enable this feature.