[Padrino loader] configはrollback対象外とnested require_dependencies直す差分を取り組みます - #4
Open
phamvanhungmixi wants to merge 8 commits into
Open
[Padrino loader] configはrollback対象外とnested require_dependencies直す差分を取り組みます#4phamvanhungmixi wants to merge 8 commits into
phamvanhungmixi wants to merge 8 commits into
Conversation
phamvanhungmixi
force-pushed
the
template-pager
branch
from
November 21, 2018 08:51
fc8b47b to
24fb77d
Compare
phamvanhungmixi
commented
Nov 21, 2018
| files.delete(file) | ||
| loaded = true | ||
| rescue NameError, LoadError => error | ||
| raise if Reloader.exclude.any?{ |path| file.start_with?(path) } || options[:cyclic] == false |
Author
There was a problem hiding this comment.
def exclude
@_exclude ||= Set.new %w(test spec tmp features config public db).map{ |path| Padrino.root(path) }
end
これでconfig/apps.rb などはcycleロードから外す、appからlibに依存する場合libがロード失敗する場合、起動失敗になります。
Author
There was a problem hiding this comment.
つまり、config/apps.rbは一回しかロードしないです。
|
LGTM |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
問題
Fix bug for nested require_dependencies padrino/padrino-framework#2193
https://github.com/phamvanhung2e123/my_padrino_project
解決
configはrollback対象外にします。これで中途半端にならない、失敗したらunicorn再起動失敗だけです。詳細