OpenC3/cosmos

View on GitHub

Showing 1,379 of 1,379 total issues

Method initialize has 5 arguments (exceeds 4 allowed). Consider refactoring.
Open

    def initialize(name, endianness, type, description, filename)
Severity: Minor
Found in openc3/lib/openc3/tools/table_manager/table.rb - About 35 mins to fix

    Method get_packet_index has 5 arguments (exceeds 4 allowed). Consider refactoring.
    Open

        def get_packet_index(cmd_or_tlm, target_name, packet_name, entry_type, data)
    Severity: Minor
    Found in openc3/lib/openc3/logs/packet_log_writer.rb - About 35 mins to fix

      Method raise_buffer_error has 5 arguments (exceeds 4 allowed). Consider refactoring.
      Open

          def self.raise_buffer_error(read_write, buffer, data_type, given_bit_offset, given_bit_size)
      Severity: Minor
      Found in openc3/lib/openc3/accessors/binary_accessor.rb - About 35 mins to fix

        Method handle_received_time_extra_and_data has 5 arguments (exceeds 4 allowed). Consider refactoring.
        Open

            def handle_received_time_extra_and_data(entry, time_nsec_since_epoch, includes_received_time, includes_extra, cbor)
        Severity: Minor
        Found in openc3/lib/openc3/logs/packet_log_reader.rb - About 35 mins to fix

          Method _build_cmd_output_string has 5 arguments (exceeds 4 allowed). Consider refactoring.
          Open

              def _build_cmd_output_string(method_name, target_name, cmd_name, cmd_params, packet)
          Severity: Minor
          Found in openc3/lib/openc3/api/cmd_api.rb - About 35 mins to fix

            Method check_bounds_and_buffer_size has 5 arguments (exceeds 4 allowed). Consider refactoring.
            Open

                  def self.check_bounds_and_buffer_size(bit_offset, bit_size, buffer_length, endianness, data_type)
            Severity: Minor
            Found in openc3/lib/openc3/accessors/binary_accessor.rb - About 35 mins to fix

              Method initialize has 5 arguments (exceeds 4 allowed). Consider refactoring.
              Open

                  def initialize(hostname, port = 1883, ssl = false, write_topic = nil, read_topic = nil)
              Severity: Minor
              Found in openc3/lib/openc3/streams/mqtt_stream.rb - About 35 mins to fix

                Method initialize has 5 arguments (exceeds 4 allowed). Consider refactoring.
                Open

                    def initialize(processor_name, result_name, converted_type = nil, converted_bit_size = nil, converted_array_size = nil)
                Severity: Minor
                Found in openc3/lib/openc3/conversions/processor_conversion.rb - About 35 mins to fix

                  Method check_bit_offset_and_size has 5 arguments (exceeds 4 allowed). Consider refactoring.
                  Open

                        def self.check_bit_offset_and_size(read_or_write, given_bit_offset, given_bit_size, data_type, buffer)
                  Severity: Minor
                  Found in openc3/lib/openc3/accessors/binary_accessor.rb - About 35 mins to fix

                    Method write_topic has 5 arguments (exceeds 4 allowed). Consider refactoring.
                    Open

                        def write_topic(topic, msg_hash, id = '*', maxlen = nil, approximate = 'true')
                    Severity: Minor
                    Found in openc3/lib/openc3/utilities/store_autoload.rb - About 35 mins to fix

                      Method spawn has 5 arguments (exceeds 4 allowed). Consider refactoring.
                      Open

                          def spawn(cmd_array, process_type, detail, expires_at, **kw_args)
                      Severity: Minor
                      Found in openc3/lib/openc3/utilities/process_manager.rb - About 35 mins to fix

                        Method initialize has 5 arguments (exceeds 4 allowed). Consider refactoring.
                        Open

                            def initialize(cmd_array, process_type, detail, expires_at, **kw_args)
                        Severity: Minor
                        Found in openc3/lib/openc3/utilities/process_manager.rb - About 35 mins to fix

                          Method instrument_script_implementation has 5 arguments (exceeds 4 allowed). Consider refactoring.
                          Open

                            def self.instrument_script_implementation(ruby_lex_utils,
                                                                      comments_removed_text,
                                                                      _num_lines,
                                                                      filename,
                                                                      mark_private = false)
                          Severity: Minor
                          Found in openc3-cosmos-script-runner-api/app/models/running_script.rb - About 35 mins to fix

                            Method cycle_tlm_item has 5 arguments (exceeds 4 allowed). Consider refactoring.
                            Open

                                def cycle_tlm_item(packet, item_name, min, max, first_delta)
                            Severity: Minor
                            Found in openc3/lib/openc3/utilities/simulated_target.rb - About 35 mins to fix

                              Similar blocks of code found in 2 locations. Consider refactoring.
                              Open

                                  def self.notify(scope:, kind:, start:, stop: nil)
                                    json = {'type' => METADATA_TYPE, 'start' => start}
                                    json['stop'] = stop if stop
                                    notification = {
                                      'data' => JSON.generate(json),
                              Severity: Minor
                              Found in openc3/lib/openc3/models/metadata_model.rb and 1 other location - About 35 mins to fix
                              openc3/lib/openc3/models/note_model.rb on lines 36..44

                              Duplicated Code

                              Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                              Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                              When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                              Tuning

                              This issue has a mass of 36.

                              We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                              The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                              If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                              See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                              Refactorings

                              Further Reading

                              Similar blocks of code found in 2 locations. Consider refactoring.
                              Open

                                def contains_begin?(text)
                                  @lex.reinitialize
                                  @lex_io.string = text
                                  @lex.set_input(@lex_io, context: @context)
                                  tokens = ripper_lex_without_warning(text)
                              Severity: Minor
                              Found in openc3/lib/openc3/utilities/ruby_lex_utils.rb and 1 other location - About 35 mins to fix
                              openc3/lib/openc3/utilities/ruby_lex_utils.rb on lines 118..128

                              Duplicated Code

                              Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                              Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                              When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                              Tuning

                              This issue has a mass of 36.

                              We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                              The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                              If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                              See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                              Refactorings

                              Further Reading

                              Similar blocks of code found in 2 locations. Consider refactoring.
                              Open

                                  def self.notify(scope:, kind:, start:, stop: nil)
                                    json = {'type' => NOTE_TYPE, 'start' => start}
                                    json['stop'] = stop if stop
                                    notification = {
                                      'data' => JSON.generate(json),
                              Severity: Minor
                              Found in openc3/lib/openc3/models/note_model.rb and 1 other location - About 35 mins to fix
                              openc3/lib/openc3/models/metadata_model.rb on lines 36..44

                              Duplicated Code

                              Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                              Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                              When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                              Tuning

                              This issue has a mass of 36.

                              We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                              The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                              If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                              See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                              Refactorings

                              Further Reading

                              Similar blocks of code found in 2 locations. Consider refactoring.
                              Open

                                def contains_end?(text)
                                  @lex.reinitialize
                                  @lex_io.string = text
                                  @lex.set_input(@lex_io, context: @context)
                                  tokens = ripper_lex_without_warning(text)
                              Severity: Minor
                              Found in openc3/lib/openc3/utilities/ruby_lex_utils.rb and 1 other location - About 35 mins to fix
                              openc3/lib/openc3/utilities/ruby_lex_utils.rb on lines 103..113

                              Duplicated Code

                              Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                              Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                              When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                              Tuning

                              This issue has a mass of 36.

                              We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                              The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                              If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                              See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                              Refactorings

                              Further Reading

                              Similar blocks of code found in 2 locations. Consider refactoring.
                              Open

                                presets: [
                                  [
                                    'classic',
                                    /** @type {import('@docusaurus/preset-classic').Options} */
                                    ({
                              Severity: Minor
                              Found in docs.openc3.com/docusaurus.config.js and 1 other location - About 35 mins to fix
                              docs.openc3.com/docusaurus-plugin.config.js on lines 105..122

                              Duplicated Code

                              Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                              Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                              When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                              Tuning

                              This issue has a mass of 47.

                              We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                              The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                              If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                              See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                              Refactorings

                              Further Reading

                              Identical blocks of code found in 2 locations. Consider refactoring.
                              Open

                                    if (error.response?.config?.data) {
                                      body += `${error.response.config.data} `
                                    }
                              Severity: Minor
                              Found in openc3/templates/tool_svelte/src/services/axios.js and 1 other location - About 35 mins to fix
                              openc3-cosmos-init/plugins/packages/openc3-tool-common/src/services/axios.js on lines 67..69

                              Duplicated Code

                              Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                              Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                              When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                              Tuning

                              This issue has a mass of 47.

                              We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                              The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                              If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                              See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                              Refactorings

                              Further Reading

                              Severity
                              Category
                              Status
                              Source
                              Language