Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

My Submissions - New code scan popup #6694

Open
jmgasper opened this issue Oct 21, 2022 · 0 comments
Open

My Submissions - New code scan popup #6694

jmgasper opened this issue Oct 21, 2022 · 0 comments

Comments

@jmgasper
Copy link
Collaborator

jmgasper commented Oct 21, 2022

New functionality

On the My Submissions page, we are going to add a new column called Code Scan. For each submission will be a link that says View Results

This View Results link will open up a new modal dialog that displays the SonarQube scan results.

SonarQube scan

For each submission, there will be an additional review of type SonarQube Scan

You can get the typeID by calling (just use the first one returned, if there are duplicates)

GET https://api.topcoder-dev.com/v5/reviewTypes?name=SonarQube Scan

And you can get the reviews by calling:

GET https://api.topcoder-dev.com/v5/reviews?submissionId=9f89f287-465b-4b64-950a-2ede266d08ef

An example output with both AV scan and SonarQube scan results:

ExampleOutput.json.zip

Loading the reviews

Since the My Submissions page needs to load quickly, we will load the reviews for each submission ID asynchronously. Please just show a small loading spinner in place of View Results while the reviews are loaded.

Modal display of the code review

For now, the modal window should display each bug, code_smell, vulnerability, and security hotspot in a different section, in this order:

  • Vulnerability
  • Security Hot Spot
  • Bug
  • Code Smell

If there are no items for a given section, we will just say "No items found" in the UI

Item display

For each item under each section, we want to display:

  • Severity
  • File and line number (taking off the submission ID from the component value to get the file name)
  • Message

UI

For the UI, please follow the Topcoder design language / CSS used in the community app. We don't have designs for this yet, but it should look reasonably good and fit in with the rest of the community app.

Testing

For testing, you can submit any code you want to a test dev code challenge. An example being:

A minute or two after submitting, you should get a SonarQube Scan result for the submission ID.

Future challenge

A future challenge will actually fill this in the UI with more details, including the code from the submission itself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant