airbnb/caravel

View on GitHub

Showing 2,441 of 6,157 total issues

File index.tsx has 280 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/**
 * Licensed to the Apache Software Foundation (ASF) under one
 * or more contributor license agreements.  See the NOTICE file
 * distributed with this work for additional information
 * regarding copyright ownership.  The ASF licenses this file
Severity: Minor
Found in superset-frontend/src/pages/CssTemplateList/index.tsx - About 2 hrs to fix

    Function render has 68 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

      render() {
        const { formatString, testValues } = this.state;
    
        return (
          <div className="container">

      Function makeApi has 68 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      export default function makeApi<
        Payload = SupersetPayload,
        Result = JsonObject,
        T extends ParseMethod = ParseMethod,
      >(

        File transformProps.ts has 279 lines of code (exceeds 250 allowed). Consider refactoring.
        Open

        /**
         * Licensed to the Apache Software Foundation (ASF) under one
         * or more contributor license agreements.  See the NOTICE file
         * distributed with this work for additional information
         * regarding copyright ownership.  The ASF licenses this file

          File controls.tsx has 279 lines of code (exceeds 250 allowed). Consider refactoring.
          Open

          /**
           * Licensed to the Apache Software Foundation (ASF) under one
           * or more contributor license agreements.  See the NOTICE file
           * distributed with this work for additional information
           * regarding copyright ownership.  The ASF licenses this file
          Severity: Minor
          Found in superset-frontend/plugins/plugin-chart-echarts/src/controls.tsx - About 2 hrs to fix

            File RefreshIntervalModal.tsx has 279 lines of code (exceeds 250 allowed). Consider refactoring.
            Open

            /**
             * Licensed to the Apache Software Foundation (ASF) under one
             * or more contributor license agreements.  See the NOTICE file
             * distributed with this work for additional information
             * regarding copyright ownership.  The ASF licenses this file
            Severity: Minor
            Found in superset-frontend/src/dashboard/components/RefreshIntervalModal.tsx - About 2 hrs to fix

              Function transformProps has 67 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

              export default function transformProps(chartProps) {
                const { width, height, formData, queriesData, datasource } = chartProps;
                const {
                  bottomMargin,
                  canvasImageRendering,

                Function useTables has 67 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                export function useTables(options: Params) {
                  const { dbId, catalog, schema, onSuccess, onError } = options || {};
                  const isMountedRef = useRef(false);
                  const { currentData: schemaOptions, isFetching } = useSchemas({
                    dbId,
                Severity: Major
                Found in superset-frontend/src/hooks/apiResources/tables.ts - About 2 hrs to fix

                  Function HeaderRenderers has 67 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                  export const HeaderRenderers: StoryFn<typeof Table> = () => {
                    const [orderDateFormatting, setOrderDateFormatting] = useState('formatted');
                    const [priceLocale, setPriceLocale] = useState(LocaleCode.en_US);
                    const shoppingColumns: ColumnsType<ShoppingData> = [
                      {
                  Severity: Major
                  Found in superset-frontend/src/components/Table/Table.stories.tsx - About 2 hrs to fix

                    File DatasourceEditor.test.jsx has 278 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    /**
                     * Licensed to the Apache Software Foundation (ASF) under one
                     * or more contributor license agreements.  See the NOTICE file
                     * distributed with this work for additional information
                     * regarding copyright ownership.  The ASF licenses this file
                    Severity: Minor
                    Found in superset-frontend/src/components/Datasource/DatasourceEditor.test.jsx - About 2 hrs to fix

                      File crossFilters.test.ts has 278 lines of code (exceeds 250 allowed). Consider refactoring.
                      Open

                      /**
                       * Licensed to the Apache Software Foundation (ASF) under one
                       * or more contributor license agreements.  See the NOTICE file
                       * distributed with this work for additional information
                       * regarding copyright ownership.  The ASF licenses this file
                      Severity: Minor
                      Found in superset-frontend/src/dashboard/util/crossFilters.test.ts - About 2 hrs to fix

                        File DatasetPanel.tsx has 278 lines of code (exceeds 250 allowed). Consider refactoring.
                        Open

                        /**
                         * Licensed to the Apache Software Foundation (ASF) under one
                         * or more contributor license agreements.  See the NOTICE file
                         * distributed with this work for additional information
                         * regarding copyright ownership.  The ASF licenses this file

                          Chart has 24 functions (exceeds 20 allowed). Consider refactoring.
                          Open

                          class Chart extends Component {
                            constructor(props) {
                              super(props);
                              this.state = {
                                width: props.width,
                          Severity: Minor
                          Found in superset-frontend/src/dashboard/components/gridComponents/Chart.jsx - About 2 hrs to fix

                            HiveEngineSpec has 24 functions (exceeds 20 allowed). Consider refactoring.
                            Open

                            class HiveEngineSpec(PrestoEngineSpec):
                                """Reuses PrestoEngineSpec functionality."""
                            
                                engine = "hive"
                                engine_name = "Apache Hive"
                            Severity: Minor
                            Found in superset/db_engine_specs/hive.py - About 2 hrs to fix

                              Consider simplifying this complex logical expression.
                              Open

                                  if (resource) {
                                    // Add notification settings
                                    const settings = (resource.recipients || []).map(setting => {
                                      const config =
                                        typeof setting.recipient_config_json === 'string'
                              Severity: Critical
                              Found in superset-frontend/src/features/alerts/AlertReportModal.tsx - About 2 hrs to fix

                                File DrillDetailPane.tsx has 277 lines of code (exceeds 250 allowed). Consider refactoring.
                                Open

                                /**
                                 * Licensed to the Apache Software Foundation (ASF) under one
                                 * or more contributor license agreements.  See the NOTICE file
                                 * distributed with this work for additional information
                                 * regarding copyright ownership.  The ASF licenses this file

                                  Function slicer has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                      slicer: paths => state => {
                                        const subset = {};
                                        paths.forEach(path => {
                                          if (isFeatureEnabled(FeatureFlag.SqllabBackendPersistence)) {
                                            const {

                                    Function renderValueCell has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                        const renderValueCell = (valueField, column, reversedEntries) => {
                                          const recent = reversedEntries[0][valueField];
                                          let v;
                                          let errorMsg;
                                          if (column.colType === 'time') {
                                    Severity: Major
                                    Found in superset-frontend/src/visualizations/TimeTable/TimeTable.jsx - About 2 hrs to fix

                                      Function formatter has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                            formatter: (params: any) => {
                                              const [xIndex, yIndex] = isHorizontal ? [1, 0] : [0, 1];
                                              const xValue: number = richTooltip
                                                ? params[0].value[xIndex]
                                                : params.value[xIndex];

                                        Function renderItem has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                          renderItem(record: any) {
                                            const { allowAddItem, allowDeletes, expandFieldset, tableColumns } =
                                              this.props;
                                            /* eslint-disable no-underscore-dangle */
                                            const isExpanded =
                                        Severity: Major
                                        Found in superset-frontend/src/components/Datasource/CollectionTable.tsx - About 2 hrs to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language