Started GET "/mygroup/myproject/tree/master/MyDirectory" for 127.0.0.1 at 2014-10-22 22:42:42 +0200
Processing by Projects::TreeController#show as HTML
Parameters: {"project_id"=>"mygroup/myproject", "id"=>"master/MyDirectory"}
Completed 500 Internal Server Error in 373ms ActionView::Template::Error (undefined method `[]' for nil:NilClass):
1: - tree, commit = submodule_links(submodule_item)
2: %tr{ class: "tree-item" }
3: %td.tree-item-file-name
4: %i.fa.fa-archive
app/models/repository.rb:162:in `method_missing'
app/models/repository.rb:228:in `submodule_url_for'
app/helpers/submodule_helper.rb:6:in `submodule_links'
app/views/projects/tree/_submodule_item.html.haml:1:in `_app_views_projects_tree__submodule_item_html_haml__1960578592168380494_48290660'
app/helpers/tree_helper.rb:19:in `render_tree'
app/views/projects/tree/_tree.html.haml:42:in `_app_views_projects_tree__tree_html_haml__985986129427416040_29680420'
app/views/projects/tree/show.html.haml:9:in `_app_views_projects_tree_show_html_haml___3955057514203210948_31577660'
app/controllers/projects/tree_controller.rb:13:in `show' 这个问题让我聪明的领导给解决了
这个问题想开了,不难解决。就是.gitmodules文件中submodule项目,有一个已经不用了,删除了路径,但是在submodule中还存在,删除了,这个问题就解决了
我也参考了https://gitlab.com/gitlab-org/gitlab-ce/issues/714
由这个引发的思考和反思(为什么我一天没有反思,领导一个多小时就解决了):
1,注意前后对比,之前的版本是正常的,这个版本是不正常的,我没有做到前后对比,虽然从网上得到的结果是.gitmodules的问题,但是我没有确认一定是这个文件的问题
2,没有细心的对比不同,文件中,只有其中的一个文件没有,没有发现这个点。
3,对gitlab不了解,原来没有用过这个服务,对这个服务的应用和使用了解的不清楚。我只是从gitlab文件里边直接更改.gitmodules,但是当问题解决了的时候,我git clone 发现,.gitmodules文件没有修改过。而重新提交的文件就可以。
4,从服务源代码定位问题方向(当时我也看了,但是一看看不懂,就放弃了),总结起来还是对日志出现的报错,研究不深。
总结:
1,以后遇到问题要注意bug前后对比,找出差异
2,细心查找不同,注意观察
3,对出现问题的服务,多加了解、熟悉、使用

gitlab ActionView::Template::Error (undefined method `[]' for nil:NilClass): 500错误的更多相关文章

  1. FATAL: ActionView::Template::Error (application.css isn't precompiled):

    iwangzheng.com tty:[0] jobs:[0] cwd:[/opt/logs/m]13:02 [root@a02.cmsapi$ tail thin\ server\ \(0.0.0. ...

  2. CentOS 7安装Gitlab时报错:undefined method `downcase' for nil:NilClass

    说明:其实这事怪我,我把系统的某些配置改了. 首先分析这个错误出现的位置在这个文件: /opt/gitlab/embedded/cookbooks/cache/cookbooks/package/li ...

  3. C++ template error: undefined reference to XXX

    一般来说,写C++程序时推荐“类的声明和实现分离”,也就是说一个类的声明放在example.h文件中,而这个类的实现放在example.cpp文件中,这样方便管理,条理清晰. 但是如果类的声明用到了模 ...

  4. Use “error_messages” in Rails 3.2? (raises “undefined method” error)

    I am getting the following error in my Rails 3.2 functional tests: ActionView::Template::Error: unde ...

  5. "undefined method `root' for nil:NilClass" error when using "pod install" 解决办法

    如果pod undate 的时候报错"undefined method `root' for nil:NilClass" error when using "pod in ...

  6. 安装redis cluster时:undefined method `invoke_with_build_args' for nil:NilClass

    gem install -l redis-3.3.3.gem ERROR: Loading command: install (LoadError) cannot load such file -- ...

  7. undefined method `environment' for nil:NilClass when importing Bootstrap into rails

    今天做项目时往Gemfile里加了各gem, 然后bundle update了一下, 然后悲剧了,出现了undefined method `environment' for nil:NilClass ...

  8. ERROR - Undefined placeholders found in template:

    今天发现了一个BUG,在引用其他的包的的时候报错: ERROR - Undefined placeholders found in template: - Template: META-INF/aut ...

  9. CI框架 Fatal error: Call to undefined method CI_DB::CI_DB() in D:\xinqing\web\CodeIgniter\database\drivers\odbc\odbc_driver.php on line 53

    Fatal error: Call to undefined method CI_DB::CI_DB() in D:\xinqing\web\CodeIgniter\database\drivers\ ...

随机推荐

  1. 由.Net类库提供的农历计算(C#农历)-获取当前日期的农历日期

    ; i <= chineseDate.GetMonthsInYear(DateTime.Now.Year); i++)            {                Console.W ...

  2. tomcat运行问题解决方法

    早上过来遇到一个非常奇怪的问题,运行一个新的项目,运行环境都没问题,可是在调试的时候,总是出错. 错误代码: log4j:WARN No appenders could be found for lo ...

  3. 常用的windowd属性和对象

    window.location.href=""          指向一个定向的url并提交数据过去 window.location.reload()         强制刷新当前 ...

  4. 理解C++中函数的返回

    连续几年的C++程序设计课教学中,学生中总有人要求为他们单独解释函数的返回(return)究竟是什么意思.各种书中都会详讲返回值的问题,而学生们掌握的难点却是在返回至何处执行.本文试图通过对一般函数及 ...

  5. Maven管理项目架包

    最近一直在用Maven管理项目的架包,从而发现了几个不错的官方或者非官方的网站. http://mvnrepository.com/artifact/com.ning  这个是我刚刚用来找HTTP开发 ...

  6. 在SCVMM2012R2中删除失去联系的VM GateWay

    当VM Gateway失去联系,无法使用,直接删除GW,或者在VM Network中删除GW连接,均会出现如下错误提示: 错误(21426)对配置提供程序 4ee559f1-f479-480c-945 ...

  7. 标准I/O库之格式化I/O

    本篇博文内容摘自<UNIX环境高级编程>(第二版),仅作个人学习记录所用.关于本书可参考:http://www.apuebook.com/. 一.格式化输出 执行格式化输出处理的是4个pr ...

  8. 标准I/O库之标准I/O的效率

    程序清单5-1 用getc和putc将标准输入复制到标准输出 #include "apue.h" int main( void ) { int c; while(( c = get ...

  9. INSERT DELAYED 句法

    INSERT 语句的 DELAYED 选项是一个 MySQL 特有的选项,如果你的客户端不能等待 INSERT 的完成,这将会是很有用的.This is a common problem when y ...

  10. beaglebone-black 在Angstrom系统中的网络配置方法

    Beaglebone Linux 101: Assigning a Static IP Address with Connman Posted on February 6, 2012 by dwatt ...