intracom-telecom-sdn/nstat

View on GitHub

Showing 110 of 544 total issues

File monitor.py has 971 lines of code (exceeds 250 allowed). Consider refactoring.
Open

# Copyright (c) 2016 Intracom S.A. Telecom Solutions. All rights reserved.
#
# This program and the accompanying materials are made available under the
# terms of the Eclipse Public License v1.0 which accompanies this distribution,
# and is available at http://www.eclipse.org/legal/epl-v10.html
Severity: Major
Found in stress_test/monitor.py - About 2 days to fix

    File controller.py has 866 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    # Copyright (c) 2016 Intracom S.A. Telecom Solutions. All rights reserved.
    #
    # This program and the accompanying materials are made available under the
    # terms of the Eclipse Public License v1.0 which accompanies this distribution,
    # and is available at http://www.eclipse.org/legal/epl-v10.html
    Severity: Major
    Found in stress_test/controller.py - About 2 days to fix

      File sbemu.py has 800 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      # Copyright (c) 2016 Intracom S.A. Telecom Solutions. All rights reserved.
      #
      # This program and the accompanying materials are made available under the
      # terms of the Eclipse Public License v1.0 which accompanies this distribution,
      # and is available at http://www.eclipse.org/legal/epl-v10.html
      Severity: Major
      Found in stress_test/sbemu.py - About 1 day to fix

        File test_run.py has 775 lines of code (exceeds 250 allowed). Consider refactoring.
        Open

        # Copyright (c) 2015 Intracom S.A. Telecom Solutions. All rights reserved.
        #
        # This program and the accompanying materials are made available under the
        # terms of the Eclipse Public License v1.0 which accompanies this distribution,
        # and is available at http://www.eclipse.org/legal/epl-v10.html
        Severity: Major
        Found in stress_test/test_run.py - About 1 day to fix

          File report_spec_templates.py has 674 lines of code (exceeds 250 allowed). Consider refactoring.
          Open

          # Copyright (c) 2015 Intracom S.A. Telecom Solutions. All rights reserved.
          #
          # This program and the accompanying materials are made available under the
          # terms of the Eclipse Public License v1.0 which accompanies this distribution,
          # and is available at http://www.eclipse.org/legal/epl-v10.html
          Severity: Major
          Found in stress_test/report_spec_templates.py - About 1 day to fix

            Function test_selector has a Cognitive Complexity of 37 (exceeds 5 allowed). Consider refactoring.
            Open

            def test_selector(self, args):
            """
            Selects which test to run depending on the information coming from
            the args object. nstat_test_type_run variable contains information
            test_type + sb_emulator_name, necessary to select which test to run.
            Severity: Minor
            Found in stress_test/test_type.py - About 5 hrs to fix

            File netutil.py has 346 lines of code (exceeds 250 allowed). Consider refactoring.
            Open

            # Copyright (c) 2015 Intracom S.A. Telecom Solutions. All rights reserved.
            #
            # This program and the accompanying materials are made available under the
            # terms of the Eclipse Public License v1.0 which accompanies this distribution,
            # and is available at http://www.eclipse.org/legal/epl-v10.html
            Severity: Minor
            Found in util/netutil.py - About 4 hrs to fix

              File test_html.py has 338 lines of code (exceeds 250 allowed). Consider refactoring.
              Open

              # Copyright (c) 2015 Intracom S.A. Telecom Solutions. All rights reserved.
              #
              # This program and the accompanying materials are made available under the
              # terms of the Eclipse Public License v1.0 which accompanies this distribution,
              # and is available at http://www.eclipse.org/legal/epl-v10.html
              Severity: Minor
              Found in util/unittests/test_html.py - About 4 hrs to fix

                Function multi_dict_to_html has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring.
                Open

                def multi_dict_to_html(data, table_title='', map_dictionary=None,
                row_ordering_key=None):
                """Generates html tables according to the input it gets from the input \
                arguments.
                 
                Severity: Minor
                Found in util/html.py - About 3 hrs to fix

                Function nb_active_scalability_multinet_run has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring.
                Open

                def nb_active_scalability_multinet_run(self,
                json_conf,
                json_output,
                output_dir):
                """ Runs the NorthBound scalability test with idle Multinet switches
                Severity: Minor
                Found in stress_test/test_run.py - About 3 hrs to fix

                File plot_json.py has 318 lines of code (exceeds 250 allowed). Consider refactoring.
                Open

                # Copyright (c) 2015 Intracom S.A. Telecom Solutions. All rights reserved.
                #
                # This program and the accompanying materials are made available under the
                # terms of the Eclipse Public License v1.0 which accompanies this distribution,
                # and is available at http://www.eclipse.org/legal/epl-v10.html
                Severity: Minor
                Found in util/plot_json.py - About 3 hrs to fix

                  File test_sysstats.py has 312 lines of code (exceeds 250 allowed). Consider refactoring.
                  Open

                  # Copyright (c) 2015 Intracom S.A. Telecom Solutions. All rights reserved.
                  #
                  # This program and the accompanying materials are made available under the
                  # terms of the Eclipse Public License v1.0 which accompanies this distribution,
                  # and is available at http://www.eclipse.org/legal/epl-v10.html
                  Severity: Minor
                  Found in util/unittests/test_sysstats.py - About 3 hrs to fix

                    File html_generation.py has 308 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    # Copyright (c) 2015 Intracom S.A. Telecom Solutions. All rights reserved.
                    #
                    # This program and the accompanying materials are made available under the
                    # terms of the Eclipse Public License v1.0 which accompanies this distribution,
                    # and is available at http://www.eclipse.org/legal/epl-v10.html
                    Severity: Minor
                    Found in stress_test/html_generation.py - About 3 hrs to fix

                      Function merge_dict_and_avg has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
                      Open

                      def merge_dict_and_avg(results_add, results_delete):
                      """
                      Takes two dictionaries results_add, results_delete and returns a merged \
                      dictionary. Special purpose method for the NSTAT NorthBound \
                      stress test.
                      Severity: Minor
                      Found in util/file_ops.py - About 3 hrs to fix

                      File oftraf.py has 282 lines of code (exceeds 250 allowed). Consider refactoring.
                      Open

                      # Copyright (c) 2016 Intracom S.A. Telecom Solutions. All rights reserved.
                      #
                      # This program and the accompanying materials are made available under the
                      # terms of the Eclipse Public License v1.0 which accompanies this distribution,
                      # and is available at http://www.eclipse.org/legal/epl-v10.html
                      Severity: Minor
                      Found in stress_test/oftraf.py - About 2 hrs to fix

                        File controller_exceptions.py has 277 lines of code (exceeds 250 allowed). Consider refactoring.
                        Open

                        # Copyright (c) 2016 Intracom S.A. Telecom Solutions. All rights reserved.
                        #
                        # This program and the accompanying materials are made available under the
                        # terms of the Eclipse Public License v1.0 which accompanies this distribution,
                        # and is available at http://www.eclipse.org/legal/epl-v10.html
                        Severity: Minor
                        Found in stress_test/controller_exceptions.py - About 2 hrs to fix

                          File plot_utils.py has 274 lines of code (exceeds 250 allowed). Consider refactoring.
                          Open

                          # Copyright (c) 2015 Intracom S.A. Telecom Solutions. All rights reserved.
                          #
                          # This program and the accompanying materials are made available under the
                          # terms of the Eclipse Public License v1.0 which accompanies this distribution,
                          # and is available at http://www.eclipse.org/legal/epl-v10.html
                          Severity: Minor
                          Found in util/plot_utils.py - About 2 hrs to fix

                            Function monitor_thread_active has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring.
                            Open

                            def monitor_thread_active(self):
                            """
                            This monitor function is used from south bound active mtcbench \
                            tests to put into gevent queue the results during test running
                            """
                            Severity: Minor
                            Found in stress_test/monitor.py - About 2 hrs to fix

                            Function ssh_run_command has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring.
                            Open

                            def ssh_run_command(ssh_client, command_to_run, prefix='', lines_queue=None,
                            print_flag=True, block_flag=True, getpty_flag=False):
                            """
                            Runs the specified command on a remote machine
                             
                             
                            Severity: Minor
                            Found in util/netutil.py - About 2 hrs to fix

                            Function generate_plots has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring.
                            Open

                            def generate_plots(self):
                            """
                            NSTAT post test actions
                             
                            :param args: Object containing user specified parameters \
                            Severity: Minor
                            Found in stress_test/report_gen.py - About 2 hrs to fix
                            Severity
                            Category
                            Status
                            Source
                            Language