Giter Club home page Giter Club logo

Comments (3)

stefanreifenberg avatar stefanreifenberg commented on June 14, 2024

Code Deletion
The codebase for this application is very large, and although the majority of it is required for the application to run, there is a substantial amount that can be deleted without affecting the application, either because it is never called or it simply does nothing to change the environment. The GitHub repository has a good level of version control, so if any of the deleted code is required in the future, it can be searched and re-added. By removing the points mentioned below, the code will become a lot clearer and easier for users to read and diagnose any issues that may exist.

  • You have written a lot of comments, and whilst this is better than no comments, comments should generally be used for explaining why a certain piece of logic is used rather than what the code is doing. With clear function and variable names, someone new to the code will be able to understand what is going on without needing comments, whereas they will only get the why from well written comments.
  • Comments that are questions should be written as GitHub issues, that way they get more visibility.
  • Some of the comments can also be quite misleading. For example, in the BiomarkerBoard, there is a comment of ## top 100 referencing the top 10 * NFEATURES rows. Looking at the rest of the expression, this actually comes out to 600.
  • I see there a lot of informational/debugging message() statements. All of these should be using the dbg() function so that you can turn them off, to allow you to see a clearer console sometimes to notice actual issues
  • There are many messages that are not informative and should be removed to not clog up the log files
  • Any line which is simply printing a variable (with or without print()) can be removed. This is useful when running a line-by-line debugging, but it does nothing when a function is run.
  • Variables that are created and never used can also be removed. Some of them might have been in use before code got commented out or deleted, but it just adds extra code to be maintained that isn't required.
  • There are also variables that are defined, and then redefined on the next line. This is usually when a shiny input is being used. If you want to test a reactive expression, create a function that runs the business logic, and create tests to check it works as expected. Then use that function for the input and you can delete the original assignment.
  • I have found there are several functions that are either labelled as old/moved/notworking or never used in the application (or build process). These should be removed.
  • On a similar note, there is a fair amount of commented out code.
  • Any if condition that contains 0 or FALSE should be removed entirely, and any if(1) or if(TRUE) should be replaced with just the code inside, without having an if statement

from omicsplayground.

github-actions avatar github-actions commented on June 14, 2024

This issue is stale because it has been open for 60 days with no activity. It will close in 14 days.

from omicsplayground.

github-actions avatar github-actions commented on June 14, 2024

This issue was closed because it has been inactive for 14 days since being marked as stale.

from omicsplayground.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.