質問編集履歴
1
解決策として提唱されているフォルダ名の変更を試しましたが、エラーは依然として健在。
title
CHANGED
File without changes
|
body
CHANGED
@@ -32,4 +32,109 @@
|
|
32
32
|
|
33
33
|
app/controllers/application_controller.rb:1:in `<top (required)>'
|
34
34
|
app/controllers/clickcount_controller.rb:1:in `<top (required)>'
|
35
|
-
```
|
35
|
+
```
|
36
|
+
|
37
|
+
## 追記
|
38
|
+
|
39
|
+
|
40
|
+
|
41
|
+
解決策を探しまして、
|
42
|
+
|
43
|
+
- [Rails: AbstractController::Helpers::MissingHelperError - Missing helper file application\_helper.rb\_helper.rb - Stack Overflow](https://stackoverflow.com/questions/27884908/rails-abstractcontrollerhelpersmissinghelpererror-missing-helper-file-app)
|
44
|
+
- [RSpecを実行するとMissing helper fileと表示される - Qiita](https://qiita.com/kiyodori/items/f41408f3da626fbb0bbe)
|
45
|
+
- [schema - Strange error in rails - missing helper - Stack Overflow](https://stackoverflow.com/questions/27871726/strange-error-in-rails-missing-helper)
|
46
|
+
- [Rails アプリを動かそうとしたら「Missing helper file」というエラーが発生する件 - Corredor](http://neos21.hatenablog.com/entry/2017/03/23/010854)
|
47
|
+
|
48
|
+
いろいろ調べた結果、
|
49
|
+
|
50
|
+
結局、
|
51
|
+
|
52
|
+
> 解消法としては、Rails アプリのディレクトリ名を一旦違う名前に変更し、元の名前に戻してやると、なぜか解消する。
|
53
|
+
|
54
|
+
らしいのですが、
|
55
|
+
|
56
|
+
なんとかリネームして再検証しましたが、
|
57
|
+
```
|
58
|
+
PS C:\pg\rails> Rename-Item tool tooltmp
|
59
|
+
PS C:\pg\rails> Rename-Item .\tooltmp\ tool
|
60
|
+
```
|
61
|
+
|
62
|
+
同じくエラーでした。
|
63
|
+
|
64
|
+
> 単なるリネームで解消しない場合は、例えば「xxx」にディレクトリ名を変更したら、新たに「RailsPractice」ディレクトリを作り、中身をソックリそちらに移動させたりする。結局は同じディレクトリ名で、ファイルや設定は何も変更していないのだが、これで解消する。
|
65
|
+
|
66
|
+
```
|
67
|
+
PS C:\pg\rails> Rename-Item tool tooltmp
|
68
|
+
PS C:\pg\rails> mkdir tool
|
69
|
+
|
70
|
+
|
71
|
+
ディレクトリ: C:\pg\rails
|
72
|
+
|
73
|
+
|
74
|
+
Mode LastWriteTime Length Name
|
75
|
+
---- ------------- ------ ----
|
76
|
+
d----- 2018/07/09 11:56 tool
|
77
|
+
|
78
|
+
|
79
|
+
PS C:\pg\rails> mv .\tooltmp* tool/
|
80
|
+
PS C:\pg\rails> ls tool
|
81
|
+
|
82
|
+
|
83
|
+
ディレクトリ: C:\pg\rails\tool
|
84
|
+
|
85
|
+
|
86
|
+
Mode LastWriteTime Length Name
|
87
|
+
---- ------------- ------ ----
|
88
|
+
d----- 2018/07/07 17:04 app
|
89
|
+
d----- 2018/07/07 17:04 bin
|
90
|
+
d----- 2018/07/07 17:04 config
|
91
|
+
d----- 2018/07/07 17:07 db
|
92
|
+
d----- 2018/07/07 17:04 lib
|
93
|
+
d----- 2018/07/07 17:06 log
|
94
|
+
d----- 2018/07/07 17:04 public
|
95
|
+
d----- 2018/07/07 17:04 storage
|
96
|
+
d----- 2018/07/07 17:04 test
|
97
|
+
d----- 2018/07/07 17:07 tmp
|
98
|
+
d----- 2018/07/07 17:04 vendor
|
99
|
+
-a---- 2018/07/07 17:04 679 .gitignore
|
100
|
+
-a---- 2018/07/07 17:04 5 .ruby-version
|
101
|
+
-a---- 2018/07/07 17:04 130 config.ru
|
102
|
+
-a---- 2018/07/07 17:04 1957 Gemfile
|
103
|
+
-a---- 2018/07/07 17:04 5086 Gemfile.lock
|
104
|
+
-a---- 2018/07/07 17:04 62 package.json
|
105
|
+
-a---- 2018/07/07 17:04 227 Rakefile
|
106
|
+
-a---- 2018/07/07 17:04 374 README.md
|
107
|
+
|
108
|
+
|
109
|
+
PS C:\pg\rails> ls .\tooltmp\
|
110
|
+
PS C:\pg\rails>
|
111
|
+
```
|
112
|
+
|
113
|
+
説明通りにやったのですが、
|
114
|
+
|
115
|
+
```
|
116
|
+
PS C:\pg\rails\tool> cd ..
|
117
|
+
PS C:\pg\rails> cd tool
|
118
|
+
PS C:\pg\rails\tool> rails s
|
119
|
+
=> Booting Puma
|
120
|
+
=> Rails 5.2.0 application starting in development
|
121
|
+
=> Run `rails server -h` for more startup options
|
122
|
+
*** SIGUSR2 not implemented, signal based restart unavailable!
|
123
|
+
*** SIGUSR1 not implemented, signal based restart unavailable!
|
124
|
+
*** SIGHUP not implemented, signal based logs reopening unavailable!
|
125
|
+
Puma starting in single mode...
|
126
|
+
* Version 3.11.4 (ruby 2.4.2-p198), codename: Love Song
|
127
|
+
* Min threads: 5, max threads: 5
|
128
|
+
* Environment: development
|
129
|
+
* Listening on tcp://0.0.0.0:3000
|
130
|
+
Use Ctrl-C to stop
|
131
|
+
Started GET "/" for 127.0.0.1 at 2018-07-09 11:58:11 +0900
|
132
|
+
|
133
|
+
AbstractController::Helpers::MissingHelperError (Missing helper file helpers/c:/pg/rails/tool/app/helpers/application_helper.rb_helper.rb):
|
134
|
+
```
|
135
|
+
|
136
|
+
やはり同様のエラー。
|
137
|
+
|
138
|
+
万策尽きた感……
|
139
|
+
|
140
|
+
どうしたら良いでしょうか…。
|