You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've added the schema loader in #197, but I found an error with GitLab's db/schema.rb.
I'll send a pull request as soon as possible, probably tonight.
Expected behavior
No errors during parsing db/schema.rb.
Actual behavior
An error occurred (at least).
Steps to reproduce the problem
$ git clone https://github.com/gitlabhq/gitlabhq
$ cd gitlabhq/
$ ruby -rparser/ruby26 -rrubocop-rails -e 'RuboCop::Rails::SchemaLoader.load 2.6'
/home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/parser-2.7.0.2/lib/parser/lexer.rb:10972: warning: assigned but unused variable - testEof
/home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:134:in `build_columns': undefined method `values'for s(:str, "lower((extern_uid)::text), provider"):RuboCop::AST::StrNode (NoMethodError)Did you mean? value from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:125:in `initialize' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:75:in `new'
from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:75:in `block in build_indices' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:85:in `block in each_content' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:84:in `each' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:84:in `each_content'
from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:71:in `each' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:71:in `map' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:71:in `build_indices' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:52:in `initialize'
from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:27:in `new' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:27:in `block in build!' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:37:in `block in each_table' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:34:in `each'
from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:34:in `each_table' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:26:in `build!' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader/schema.rb:12:in `initialize' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader.rb:34:in `new'
from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader.rb:34:in `load!' from /home/pocke/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/rubocop-rails-2.4.2/lib/rubocop/rails/schema_loader.rb:18:in `load' from -e:1:in `<main>'
I've added the schema loader in #197, but I found an error with GitLab's db/schema.rb.
I'll send a pull request as soon as possible, probably tonight.
Expected behavior
No errors during parsing db/schema.rb.
Actual behavior
An error occurred (at least).
Steps to reproduce the problem
The cause is the following line:
https://github.com/gitlabhq/gitlabhq/blob/dc560bd238764df34382017e23f2667ade0c7a2d/db/schema.rb#L2017
RuboCop version
master branch.
The text was updated successfully, but these errors were encountered: