autotelik/datashift

View on GitHub

Showing 255 of 255 total issues

Use each_value instead of each.
Open

          row.each do |_k, v|

This cop checks for uses of each_key and each_value Hash methods.

Note: If you have an array of two-element arrays, you can put parentheses around the block arguments to indicate that you're not working with a hash, and suppress RuboCop offenses.

Example:

# bad
hash.keys.each { |k| p k }
hash.values.each { |v| p v }
hash.each { |k, _v| p k }
hash.each { |_k, v| p v }

# good
hash.each_key { |k| p k }
hash.each_value { |v| p v }

TODO found
Open

        # TODO: - do we really need to pass in the doc context when parent nodes already has it ?

TODO found
Open

      # TODO: - read in from configration
Severity: Minor
Found in lib/datashift/doc_context.rb by fixme

TODO found
Open

      # TODO: - prepare_data_flow_schema here in middle of export, plus reaching through nodes to klass, does not smell right

TODO found
Open

      # TODO: - this is instance methods .. what about class methods ?

TODO found
Open

      # TODO: fix doc context so it can be created 'empty' i.e without AR klass, and always has empty headers

TODO found
Open

      # TODO: - make more robust - currently end on first empty column
Severity: Minor
Found in lib/datashift/excel_base.rb by fixme

TODO found
Open

    # TODO: - check out regexp to do this work better plus Inflections ??
Severity: Minor
Found in lib/datashift/binder.rb by fixme

TODO found
Open

          # TODO: - now we know this column is an enum set operator type to :enum to save this check in future
Severity: Minor
Found in lib/datashift/populators/populator.rb by fixme

TODO found
Open

      # TODO: - enable clients to register their own transformation methods and call them here
Severity: Minor
Found in lib/datashift/populators/populator.rb by fixme

TODO found
Open

          # TODO: - layout with heading is verbose for no benefit - defunct, simply node.source, node.presentation

TODO found
Open

    # TODO: - better ways ?? - see transcoding and String#encode
Severity: Minor
Found in lib/datashift/column_packer.rb by fixme

TODO found
Open

              # TODO: some way to define if this is a fatal error or not ?
Severity: Minor
Found in lib/datashift/populators/has_many.rb by fixme

TODO found
Open

      # TODO: - can we abstract out what a 'parsed file' is - headers plus value of each node
Severity: Minor
Found in lib/datashift/loaders/csv_loader.rb by fixme

TODO found
Open

        # TODO: make this more robust ? e.g what about when using active record but not in Rails app, Sinatra etc
Severity: Minor
Found in lib/tasks/thor_behaviour.rb by fixme

TODO found
Open

# TODO - add another ruby parse layer to strip these out completely
Severity: Minor
Found in lib/tasks/config/tidy_config.txt by fixme

TODO found
Open

          # TODO: what is c ?   a list or hash ?

TODO found
Open

            # (TODO - write spec to process .xls with a huge number of rows)
Severity: Minor
Found in lib/datashift/loaders/excel_loader.rb by fixme

TODO found
Open

              # TODO: - how does this get inserted - bind headers ?? ignore if no index
Severity: Minor
Found in lib/datashift/loaders/excel_loader.rb by fixme

TODO found
Open

    # TODO: - use delegators
Severity
Category
Status
Source
Language