Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/473.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Gitlab 推送到原点后,可以';t查看存储库页面_Gitlab - Fatal编程技术网

Gitlab 推送到原点后,可以';t查看存储库页面

Gitlab 推送到原点后,可以';t查看存储库页面,gitlab,Gitlab,如果我创建了一个新项目,我可以在我的列表中点击它,然后看到这个项目。但是,如果我在本地提交更改并将其推送到远程,那么在尝试查看项目页面时会出现错误,错误为500。生产日志显示以下错误: ActionView::Template::Error (undefined method `sha' for nil:NilClass): 39: = link_to project_compare_index_path(@project, from: @repository.root_ref, to: @r

如果我创建了一个新项目,我可以在我的列表中点击它,然后看到这个项目。但是,如果我在本地提交更改并将其推送到远程,那么在尝试查看项目页面时会出现错误,错误为500。生产日志显示以下错误:

ActionView::Template::Error (undefined method `sha' for nil:NilClass):

39: = link_to project_compare_index_path(@project, from: @repository.root_ref, to: @ref || @repository.root_ref), class: 'btn btn-block' do
40: Compare code
41:
42: - if @repository.readme
43: - readme = @repository.readme
44: = link_to project_blob_path(@project, tree_join(@repository.root_ref, readme.name)), class: 'btn btn-block' do
45: = readme.name
app/models/repository.rb:177:in `tree'
app/models/repository.rb:161:in `block in readme'
app/models/repository.rb:160:in `readme'
app/views/projects/show.html.haml:42:in `_app_views_projects_show_html_haml___610828608301993518_70108750838020'
app/controllers/projects_controller.rb:69:in `block (2 levels) in show'
app/controllers/projects_controller.rb:63:in `show'
Started GET "/david/striker" for 99.73.162.163 at 2014-07-14 01:22:24 -0400
Processing by ProjectsController#show as HTML
我想在控制台中看看这个,但这似乎不可能。不幸的是,我不知道postgres数据库的密码,所以我也无法查看控制台内部。在模板中,repository变量似乎为nil

有人有什么想法吗?

如中所述,检查您的Ruby版本:

在恢复到6.9.2时,我添加了同样的问题,这使我将ruby版本2.1.2p95恢复到我之前添加的版本:“ruby 2.1.0p0(2013-12-25修订版44422)”我用旧ruby版本再次尝试gitlab 7.0,前面描述的错误不再发生

因此,试着看看ruby 2.1.0是否有效(2013年12月),因为最近的ruby(如2014年5月的2.1.2)可能不起作用