Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

should fix the bug: Message: NoMethodError: undefined method `sub' for #<TeracyDev::Location::GitWarn #617

Open
hoatle opened this issue May 7, 2020 · 3 comments

Comments

@hoatle
Copy link
Member

hoatle commented May 7, 2020

This is the error log:

$ vagrant up --provision
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/logging/mask_filter.rb:38:in
 `block in masked'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.6.0/set.rb:338:in `each_key'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.6.0/set.rb:338:in `each'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/logging/mask_filter.rb:36:in
 `masked'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/logging/mask_filter.rb:28:in
 `filtered'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/logging.rb:62:in `block (2 l
evels) in configure_logger_for'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/logging.rb:61:in `each'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/logging.rb:61:in `block in c
onfigure_logger_for'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.6.0/logger.rb:582:in `format_me
ssage'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.6.0/logger.rb:472:in `add'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.6.0/logger.rb:534:in `warn'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/location/git_synch.rb:21:in
`rescue in sync'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/location/git_synch.rb:17:in
`sync'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/location/manager.rb:19:in `b
lock in sync'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/location/manager.rb:18:in `e
ach'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/location/manager.rb:18:in `s
ync'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/loader.rb:127:in `sync_terac
y_dev_entry'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/loader.rb:49:in `sync'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev/loader.rb:32:in `start'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev.rb:37:in `<module:TeracyDev>
'
C:/tools/cygwin/home/be be/iorad-dev/lib/teracy-dev.rb:11:in `<top (required)>'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.6.0/rubygems/core_ext/kernel_re
quire.rb:54:in `require'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.6.0/rubygems/core_ext/kernel_re
quire.rb:54:in `require'
C:/tools/cygwin/home/be be/iorad-dev/Vagrantfile:21:in `<top (required)>'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/config/l
oader.rb:239:in `load'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/config/l
oader.rb:239:in `block in procs_for_path'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/config.r
b:53:in `block in capture_configures'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/config.r
b:48:in `synchronize'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/config.r
b:48:in `capture_configures'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/config/l
oader.rb:237:in `procs_for_path'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/config/l
oader.rb:223:in `procs_for_source'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/config/l
oader.rb:67:in `block in set'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/config/l
oader.rb:61:in `each'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/config/l
oader.rb:61:in `set'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/environm
ent.rb:487:in `config_loader'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/environm
ent.rb:792:in `vagrantfile'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/environm
ent.rb:973:in `process_configured_plugins'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/lib/vagrant/environm
ent.rb:178:in `initialize'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/bin/vagrant:168:in `
new'
C:/HashiCorp/Vagrant/embedded/gems/2.2.8/gems/vagrant-2.2.8/bin/vagrant:168:in `
<main>'
Vagrant failed to initialize at a very early stage:
There was an error loading a Vagrantfile. The file being loaded
and the error message are shown below. This is usually caused by
a syntax error.
Path: C:/tools/cygwin/home/be be/iorad-dev/Vagrantfile
Line number: 38
Message: NoMethodError: undefined method `sub' for #<TeracyDev::Location::GitWar
n:0x00000000062cc288>

We need to find the root cause to fix this. I expect a good clear log message should be displayed instead of the error above.

@hoatle hoatle added this to the v0.6.0-b1-dev milestone May 7, 2020
@hoatle hoatle added this to Backlog in public-dev via automation May 7, 2020
@hoatle hoatle moved this from Backlog to Sprint-Current in public-dev May 7, 2020
@hoatle
Copy link
Member Author

hoatle commented May 7, 2020

this bug is reported by @phuonglm, it's better to include the debug log here for easier tracing.

@hoatle hoatle changed the title should fix the bug: Message: NoMethodError: undefined method `sub' for #<TeracyDev::Location::GitWar n should fix the bug: Message: NoMethodError: undefined method `sub' for #<TeracyDev::Location::GitWarn May 7, 2020
@phuonglm
Copy link
Contributor

phuonglm commented May 7, 2020

this error seem fixed ( I can't confirm the source of the exception ) when comment out this line. https://github.com/teracyhq/dev/blob/develop/lib/teracy-dev/location/git_synch.rb#L64 , since the dev not available any more so we must find the way to reproduce ourselft

@hoatle
Copy link
Member Author

hoatle commented May 7, 2020

looks like not critical anymore, so I'll move this issue out of the current sprint, we need to steps to reproduce the problem (better if tests are added), find the root cause and fix it.

@hoatle hoatle moved this from Sprint-Current to Backlog in public-dev May 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
public-dev
  
Backlog
Development

No branches or pull requests

4 participants