Skip to content

Conversation

@FabrizioSandri
Copy link
Owner

@FabrizioSandri FabrizioSandri commented Jun 29, 2022

First prototype

In this pull request I will create a first prototype of the RcppDeepState GitHub Action.

Considerations

The blog article titled "RcppDeepState's GitHub Action considerations" contains various aspects that I had to take into account when writing this GitHub Action. I made the decision to create a Docker-based GitHub Action. The more flexible aspect of a docker-based action played a role in this choice; perhaps in the future, this Action could be rewritten as a composite action rather than a docker one.

@FabrizioSandri
Copy link
Owner Author

In the last few commits I created a basic structure for the GitHub Action that runs an Ubuntu container.
When entrypoint.sh is run, this container will install several dependencies as well as devtools and RcppDeepState.
As previously noted in Issue #8 in order to get the best performance, the optimization settings are furthermore disabled in the commit bb0a85a.

@FabrizioSandri
Copy link
Owner Author

With the most recent commits, I developed a script called src/analyze package.R that executes the RcppDeepState analysis steps for the package located in the workspace location. This means that in order for the package to be tested in the workspace of the Docker machine, the Checkout Action must be executed before this GitHub Action. The result is printed on the standard output once the analysis is complete.

@FabrizioSandri
Copy link
Owner Author

@tdhock with the end of this week I've created a first working prototype of the RcppDeepState Action. However, this prototype requires several adjustments, including to inputs and outputs.

To test this action I made a simple workflow that checks-out the RcppDeepState repository containing the testSAN package and then runs RcppDeepState on it.

The execution of the workflow, triggered by the commit 32d35d3, shows the results of the RcppDeepState's analysis over the testSAN package. The analysis's resulting logtable is printed at the end of the step named Analyze the package with RcppDeepState.

@tdhock
Copy link
Collaborator

tdhock commented Jul 6, 2022

Hi I see the RcppDeepState output on the github action run. This is great progress! What's next?

@FabrizioSandri
Copy link
Owner Author

FabrizioSandri commented Jul 6, 2022

These are the tasks I have planned for as my next steps for the RcppDeepState-action:

  • implement exit codes for the Action so that the workflow will fail if an error is discovered;
  • add the following parameters as inputs for the action:
    • seed: input parameter that will be used as an input seed for deterministic fuzz testing;
    • time_limit: used to control the time which the fuzzing phase will be run;
    • max_inputs: used to provide a maximum number of inputs to analyze;
  • improve the output of RcppDeepState, so that the developer that runs this action will be able to quickly find and understand the motivation behind bugs;

In the future, I'll also think about if I can express this Action as a composite action. This is merely an idea at this time, though.
If I intend to make this change, I'll probably add a step actions/upload-artifact to share the analysis findings with other jobs. In this way developers that use this Action will be able to download the artifact files to see the analysis results.


On the RcppDeepState side I will finish making some changes to the logging system, as outlined in the pull request FabrizioSandri/RcppDeepState/pull/9. Additionally I plan to create a new RcppDeepState function that sets up a workflow inside of a repository. In this way it will be easy for developers to initialize RcppDeepState-action.

@tdhock
Copy link
Collaborator

tdhock commented Jul 7, 2022

sounds great full speed ahead, tell me if you need to discuss via google meet some time.

@FabrizioSandri
Copy link
Owner Author

Yes, before the end of this week I will send you an email to plan the meeting.

@FabrizioSandri FabrizioSandri merged commit d35d6d2 into main Jul 7, 2022
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.

3 participants