UTD-CRSS/app.exploreapollo.org

View on GitHub

Showing 270 of 270 total issues

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

              <Ticks
                axis="y"
                opacity={1.0}
                position="left"
                tickVisible={({ tick }) => tick.y >= 0}
Severity: Major
Found in src/components/LineDiagram/index.js and 2 other locations - About 5 hrs to fix
src/components/BarDiagram/index.js on lines 56..68
src/components/DashboardDiagram/index.js on lines 46..58

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 141.

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 3 locations. Consider refactoring.
Open

                <Ticks
                  axis="y"
                  opacity={1.0}
                  position="left"
                  tickVisible={({tick}) => tick.y>=0}
Severity: Major
Found in src/components/DashboardDiagram/index.js and 2 other locations - About 5 hrs to fix
src/components/BarDiagram/index.js on lines 56..68
src/components/LineDiagram/index.js on lines 60..77

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 141.

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

                  <ul className="featured-stories">
                    <li>
                      <FeaturedStoryLink
                        text="Apollo Launch"
                        to="/stories/story/1"
Severity: Major
Found in src/containers/Dashboard/index.js and 1 other location - About 5 hrs to fix
src/containers/Dashboard/index.js on lines 49..74

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 141.

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 3 locations. Consider refactoring.
Open

              <Ticks
                axis="y"
                opacity={1.0}
                position="left"
                tickVisible={({tick}) => tick.y>=0}
Severity: Major
Found in src/components/BarDiagram/index.js and 2 other locations - About 5 hrs to fix
src/components/DashboardDiagram/index.js on lines 46..58
src/components/LineDiagram/index.js on lines 60..77

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 141.

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

                <ul className="featured-stories">
                  <li>
                    <FeaturedStoryLink
                      text="Apollo Launch"
                      to="/stories/story/1"
Severity: Major
Found in src/containers/Dashboard/index.js and 1 other location - About 5 hrs to fix
src/containers/Dashboard/index.js on lines 117..142

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 141.

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

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

  render() {
    const { autoplay, onEnd } = this.state;
    if (this.state.loading) {
      return (
        <div className="text-center lead">
Severity: Major
Found in src/containers/DJ/index.js - About 5 hrs to fix

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

      render() {
        return (
          <div className="dashboard-container">
            <div
              className="container-fluid"
    Severity: Major
    Found in src/containers/Dashboard/index.js - About 5 hrs to fix

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

      export function PlayButton({ isPlaying, play, pause }) {
        const clickFunction = isPlaying ? pause : play;
        return (
          <div
            style={{ color: "#000" }}
      Severity: Major
      Found in src/components/MomentPlayer/index.js and 1 other location - About 4 hrs to fix
      src/components/AudioPlayer/index.js on lines 30..45

      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 133.

      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

      function PlayButton({ isPlaying, play, pause }) {
        const clickFunction = isPlaying ? pause : play;
        return (
          <div
            style={{ color: "#000" }}
      Severity: Major
      Found in src/components/AudioPlayer/index.js and 1 other location - About 4 hrs to fix
      src/components/MomentPlayer/index.js on lines 36..51

      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 133.

      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

      File index.js has 369 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      import "./index.scss";
      import React, { Component } from "react";
      
      export class InTheNewsComponent extends Component {
        render() {
      Severity: Minor
      Found in src/components/InTheNewsComponent/index.js - About 4 hrs to fix

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

                    <div className="col-sm-4 col-sm-offset-1">
                      <ul className="footer-links">
                        <li>
                          <a href="https://exploreapollo.org/">Project Homepage</a>
                        </li>
        Severity: Major
        Found in src/containers/App/index.js and 1 other location - About 4 hrs to fix
        src/containers/App/index.js on lines 151..163

        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 128.

        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

                    <div className="col-sm-4 col-sm-offset-2">
                      <ul className="footer-links">
                        <li>
                          <Link to="/">Home</Link>
                        </li>
        Severity: Major
        Found in src/containers/App/index.js and 1 other location - About 4 hrs to fix
        src/containers/App/index.js on lines 165..177

        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 128.

        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

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

          render() {
            const mission = this.props.match.params.mission;
            const {data, playNextOrPreviousActivate, playingChannels, nextBlockIndex, nextNuggetIndex, currentBlockIndex,
            currentNuggetIndex, tapeId, minBlock, maxBlock} = this.state;
            return (
        Severity: Major
        Found in src/containers/ChannelViewer/index.js - About 4 hrs to fix

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

            render() {
              return (
                <nav className="navbar navbar-brand navbar-expand-lg navbar-dark navbar-bg-dark">
                  <button
                    className="navbar-toggler"
          Severity: Major
          Found in src/containers/App/index.js - About 4 hrs to fix

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

                              <div style={{ marginTop: "2em" }}>
                                <button className="btn btn-lg">
                                  <a href="/apollo11"> Launch!</a>
                                </button>
                                <span style={{ padding: "0 1em" }}>or</span>
            Severity: Major
            Found in src/containers/Dashboard/index.js and 1 other location - About 4 hrs to fix
            src/containers/Dashboard/index.js on lines 76..84

            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 123.

            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

                            <div style={{ marginTop: "2em" }}>
                              <button className="btn btn-lg">
                                <a href="/apollo11"> Launch!</a>
                              </button>
                              <span style={{ padding: "0 1em" }}>or</span>
            Severity: Major
            Found in src/containers/Dashboard/index.js and 1 other location - About 4 hrs to fix
            src/containers/Dashboard/index.js on lines 144..152

            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 123.

            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

                            <Ticks
                              axis="x"
                              opacity={1.0}
                              position="bottom"
                              label={"Time"}
            Severity: Major
            Found in src/components/DashboardDiagram/index.js and 1 other location - About 4 hrs to fix
            src/components/BarDiagram/index.js on lines 42..55

            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 121.

            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

                          <Ticks
                            axis="x"
                            opacity={1.0}
                            position="bottom"
                            label={"Time"}
            Severity: Major
            Found in src/components/BarDiagram/index.js and 1 other location - About 4 hrs to fix
            src/components/DashboardDiagram/index.js on lines 59..72

            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 121.

            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

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

              render() {
                const { data, containerWidth } = this.props;
            
                //Don't render diagram without data
                if (
            Severity: Major
            Found in src/components/LineDiagram/index.js - About 4 hrs to fix

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

                return (dispatch) => {
                  dispatch(fetchMoments());
                  fetch(`${config.apiEntry}/api/moments/search?q=${transcriptSnippet}`)
                    .then((response) => {
                      return response.json();
              Severity: Major
              Found in src/actions/index.js and 1 other location - About 4 hrs to fix
              src/actions/index.js on lines 37..51

              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 117.

              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