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

Run Specimin on all methods in a project in CI #323

Closed
wants to merge 0 commits into from

Conversation

NiharikaJamble
Copy link
Collaborator

@NiharikaJamble NiharikaJamble commented Jul 16, 2024

This change will execute ASHE to check Specimin's accuracy (defined as ability to produce compilable output) on any push or pull requests made to main branch

@kelloggm kelloggm self-requested a review July 16, 2024 14:22
Copy link
Collaborator

@kelloggm kelloggm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking through the logs of the CI run, this doesn't appear to be quite working as intended:

  • the resulting accuracy is 0%, which is not what we expect
  • the cause might be that the logs indicate that Specimin is failing to run with some kind of problem related to the auto-formatter Spotless. Why is that happening?
  • the logic uses a deprecated mechanism for storing results set-update. The logs have instructions for how to use the new, preferred mechanism ("environment files"), which you should look into.

@@ -71,7 +71,7 @@ jobs:
uses: actions/setup-java@v4
with:
distribution: 'corretto'
java-version: '17'
java-version: '21'
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the reason for changing the Java version used for the regular CI runs? I don't think the Java version here should have any impact on the new CI job that you've added.

Also, why is the Java version important? Does something fail if we use Java 17? If so, that should be fixed: Specimin should run under Java 17+.

@@ -0,0 +1,66 @@
name: specimin-evaluation_CI_with_Gradle
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are there two near-copies of this file? Only one of them seems to be running (there is only one new CI job); which is it?

echo "Contents of Specimin_Eval_Project_List.csv:"
cat Specimin_Eval_Project_List.csv

- name: Display CSV File Contents
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are there two steps to display the contents of this CSV file?

- name: List Files for Debugging
run: ls -R

- name: Clone Project B
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is "Project B"?


- name: Clone Project B
run: |
git clone https://github.com/NiharikaJamble/ASHE_Automated-Software-Hardening-for-Entrypoints ASHE
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Specimin's CI should, if possible, only reference other projects that are under the njit-jerse organization. Is it necessary to use your fork, or could you use this fork instead?

@kelloggm
Copy link
Collaborator

@NiharikaJamble is this ready to review again? If so, please either post a comment that says so or use the GitHub UI to "request another review".

@NiharikaJamble
Copy link
Collaborator Author

NiharikaJamble commented Jul 17, 2024 via email

@NiharikaJamble
Copy link
Collaborator Author

NiharikaJamble commented Jul 17, 2024 via email

@kelloggm
Copy link
Collaborator

Apologies for the incorrect error.Below is the error I wanted to mention for point 2 in previous mail

I see - it looks like ASHE is compiling itself with Java 21, so its binaries don't work with Java 17. That's a good reason.

the latest working log I had shows 90.07%, Can i get the log for which you encountered this issue?

I'm referring to the log of the run of the CI job on this PR. In particular, I think I was looking at this one: https://github.com/njit-jerse/specimin/actions/runs/9952758388/job/27513834573

@kelloggm kelloggm changed the title CI for Specimin Run Specimin on all methods in a project in CI Jul 18, 2024
@kelloggm
Copy link
Collaborator

@NiharikaJamble CI is not running in this PR because there are conflicts with the main branch that you need to resolve. Once the conflicts are resolved CI should run again.

@NiharikaJamble
Copy link
Collaborator Author

NiharikaJamble commented Jul 24, 2024 via email

@kelloggm
Copy link
Collaborator

I did check on that. The error indicates that origin/main is not a branch
present. However that is not the case since we do have a main branch

I don't know what you mean by this. There is clearly a conflict in .github/workflows/gradle.yml that you need to resolve; as soon as you push a merge commit that does so, CI will run automatically in this PR.

@kelloggm
Copy link
Collaborator

Screen Shot 2024-07-24 at 4 16 09 PM

@NiharikaJamble
Copy link
Collaborator Author

NiharikaJamble commented Jul 25, 2024 via email

@kelloggm
Copy link
Collaborator

As per our discussion yesterday I have raised another PR. Can you please review the same?

In the future, please request a review directly on the PR that needs to be reviewed, either by tagging me in a comment or by using the "request a review" feature in the GitHub UI.

Along with this I have noticed by pulling the newly added code the accuracy has dropped to 88.08 % from 90.07 %.

We've been making changes to Specimin, so it's possible that we've introduced a regression. Please don't worry about the exact value at this time.

@kelloggm
Copy link
Collaborator

I would like to check my run in the PR but seems like I cannot do it without your review.( some with write access needs to approve it)

I'm not sure where you're seeing this. Looking at your PR #330, it looks like CI is failing on your added job because there is some missing file: https://github.com/njit-jerse/specimin/actions/runs/10084952318/job/27884789451. You should have sufficient permissions to trigger CI (as seen by the fact that CI does run on #330). I'd prefer not to review a PR until CI passes.

@NiharikaJamble
Copy link
Collaborator Author

NiharikaJamble commented Jul 25, 2024 via email

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

Successfully merging this pull request may close these issues.

2 participants