Bug 247616 - www/gitlab-ce upgrade from 12.9 to 13.1 fails
Summary: www/gitlab-ce upgrade from 12.9 to 13.1 fails
Status: Closed Overcome By Events
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Matthias Fechner
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-06-28 11:17 UTC by Vikash Badal
Modified: 2020-07-03 13:23 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (mfechner)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vikash Badal 2020-06-28 11:17:20 UTC
after upgrading from 12.9 to 13.1

root@necropolis:/usr/local/www/gitlab-ce # su -l git -c "cd /usr/local/www/gitlab-ce && rake gitlab:env:info RAILS_ENV=production --trace"
** Invoke gitlab:env:info (first_time)
** Invoke gitlab_environment (first_time)
** Invoke environment (first_time)
** Execute environment
** Execute gitlab_environment
** Execute gitlab:env:info

System information
System:		
Current User:	git
Using RVM:	no
Ruby Version:	2.6.6p146
Gem Version:	3.0.6
Bundler Version:2.0.2
Rake Version:	12.3.3
Redis Version:	5.0.9
Git Version:	2.27.0
Sidekiq Version:5.2.9
Go Version:	go1.14.4 freebsd/amd64
rake aborted!
NoMethodError: undefined method `first' for nil:NilClass
/usr/local/www/gitlab-ce/app/models/application_setting_implementation.rb:314:in `pick_repository_storage'
/usr/local/www/gitlab-ce/lib/gitlab/current_settings.rb:20:in `method_missing'
/usr/local/www/gitlab-ce/app/models/concerns/has_repository.rb:23:in `pick_repository_storage'
/usr/local/www/gitlab-ce/app/models/project.rb:72:in `block in <class:Project>'
/usr/local/lib/ruby/gems/2.6/gems/default_value_for-3.3.0/lib/default_value_for.rb:43:in `evaluate'
/usr/local/lib/ruby/gems/2.6/gems/default_value_for-3.3.0/lib/default_value_for.rb:185:in `block in set_default_values'
/usr/local/lib/ruby/gems/2.6/gems/default_value_for-3.3.0/lib/default_value_for.rb:155:in `each'
/usr/local/lib/ruby/gems/2.6/gems/default_value_for-3.3.0/lib/default_value_for.rb:155:in `set_default_values'
/usr/local/lib/ruby/gems/2.6/gems/activesupport-6.0.3.2/lib/active_support/callbacks.rb:428:in `block in make_lambda'
/usr/local/lib/ruby/gems/2.6/gems/activesupport-6.0.3.2/lib/active_support/callbacks.rb:238:in `block in halting_and_conditional'
/usr/local/lib/ruby/gems/2.6/gems/activesupport-6.0.3.2/lib/active_support/callbacks.rb:517:in `block in invoke_after'
/usr/local/lib/ruby/gems/2.6/gems/activesupport-6.0.3.2/lib/active_support/callbacks.rb:517:in `each'
/usr/local/lib/ruby/gems/2.6/gems/activesupport-6.0.3.2/lib/active_support/callbacks.rb:517:in `invoke_after'
/usr/local/lib/ruby/gems/2.6/gems/activesupport-6.0.3.2/lib/active_support/callbacks.rb:136:in `run_callbacks'
/usr/local/lib/ruby/gems/2.6/gems/activesupport-6.0.3.2/lib/active_support/callbacks.rb:825:in `_run_initialize_callbacks'
/usr/local/lib/ruby/gems/2.6/gems/activerecord-6.0.3.2/lib/active_record/core.rb:328:in `initialize'
/usr/local/lib/ruby/gems/2.6/gems/default_value_for-3.3.0/lib/default_value_for.rb:143:in `initialize'
/usr/local/www/gitlab-ce/app/models/project.rb:727:in `initialize'
/usr/local/lib/ruby/gems/2.6/gems/activerecord-6.0.3.2/lib/active_record/inheritance.rb:70:in `new'
/usr/local/lib/ruby/gems/2.6/gems/activerecord-6.0.3.2/lib/active_record/inheritance.rb:70:in `new'
/usr/local/lib/ruby/gems/2.6/gems/activerecord-6.0.3.2/lib/active_record/reflection.rb:158:in `build_association'
/usr/local/lib/ruby/gems/2.6/gems/activerecord-6.0.3.2/lib/active_record/associations/association.rb:321:in `build_record'
/usr/local/lib/ruby/gems/2.6/gems/activerecord-6.0.3.2/lib/active_record/associations/collection_association.rb:108:in `build'
/usr/local/lib/ruby/gems/2.6/gems/activerecord-6.0.3.2/lib/active_record/associations/collection_proxy.rb:316:in `build'
/usr/local/www/gitlab-ce/lib/tasks/gitlab/info.rake:48:in `block (3 levels) in <top (required)>'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/task.rb:273:in `block in execute'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/task.rb:273:in `each'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/task.rb:273:in `execute'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/task.rb:214:in `block in invoke_with_call_chain'
/usr/local/lib/ruby/2.6/monitor.rb:235:in `mon_synchronize'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/task.rb:194:in `invoke_with_call_chain'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/task.rb:183:in `invoke'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/application.rb:160:in `invoke_task'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/application.rb:116:in `block (2 levels) in top_level'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/application.rb:116:in `each'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/application.rb:116:in `block in top_level'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/application.rb:125:in `run_with_threads'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/application.rb:110:in `top_level'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/application.rb:83:in `block in run'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/application.rb:186:in `standard_exception_handling'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/lib/rake/application.rb:80:in `run'
/usr/local/lib/ruby/gems/2.6/gems/rake-12.3.3/exe/rake:27:in `<top (required)>'
/usr/local/bin/rake:23:in `load'
/usr/local/bin/rake:23:in `<main>'
Tasks: TOP => gitlab:env:info
Comment 1 Matthias Fechner freebsd_committer 2020-06-29 05:53:22 UTC
I cannot reproduce the problem, works fine here.
Make sure you follow the upgrade manual (both) very carefully:
https://gitlab.fechner.net/mfechner/Gitlab-docu/-/blob/master/update/12.9-12.10-freebsd.md
https://gitlab.fechner.net/mfechner/Gitlab-docu/-/blob/master/update/13.0-13.1-freebsd.md

You maybe forgot to edit a configuration file.

If it does not work please feel free to post here again.
Comment 2 Vikash Badal 2020-07-02 21:42:08 UTC
FYI:
https://gitlab.com/gitlab-org/gitlab/-/issues/225203

fixed it by going to /admin/application_settings/repository as admin and just clicking Save changes under the Repository storage
Comment 3 Matthias Fechner freebsd_committer 2020-07-03 13:23:25 UTC
Thanks a lot, so the work-around works for you and what I understood from the linked issue is that this will be addressed with version 13.2.
Thanks a lot!