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

Fix vps and makeself - they now pass CI + syntax_analysis fix #47

Merged
merged 23 commits into from
Jan 6, 2025

Conversation

Geoka1
Copy link
Contributor

@Geoka1 Geoka1 commented Dec 27, 2024

No description provided.

Copy link
Contributor

@LLazarek LLazarek left a comment

Choose a reason for hiding this comment

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

Tagging @vagos to look over this as well and make sure I'm not asking for unusual things :)

Copy link
Contributor

Choose a reason for hiding this comment

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

  1. I don't think this script should go through the makefile indirection -- just execute the script that the makefile runs directly. Also, be sure to run it with the environment variable hook for the benchmarks -- refer to e.g. unix50's run.sh.

  2. All this setup for shunit2 should be done in deps.sh, not here, unless I'm mistaken.

Copy link
Contributor

Choose a reason for hiding this comment

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

This script shouldn't do the same thing as run.sh -- it shouldn't run the benchmark. Instead, it should inspect the outputs produced by run.sh to determine if it ran correctly. See unix50's verify.sh for example

for test in ./*test;
do
echo "::group::$test"
bash "./$test" || { echo "*** ERROR: Test '$test' failed!"; exit 1; }
Copy link
Contributor

Choose a reason for hiding this comment

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

We may want to modify this so that it uses $BENCHMARK_SHELL instead of bash?

Copy link
Contributor

Choose a reason for hiding this comment

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

Unless I'm mistaken, I don't think we want these output files (this, .hash, .out, and release/) committed?

vps-audit/run.sh Outdated

# run the audit script and capture real-time output
echo "Starting VPS audit..."
"${main_script}" 2>&1 | tee "${log_file}"
Copy link
Contributor

Choose a reason for hiding this comment

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

Also need to use $BENCHMARK_SHELL here

Copy link
Contributor

Choose a reason for hiding this comment

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

Could we do better than this by just filtering out the parts of the log that we expect to change (like current memory usage, or time) and then hashing the remaining content?

RESULT_MARKERS=("[PASS]" "[WARN]" "[FAIL]")
RESULTS_COUNT=$(grep -Eo "$(IFS=\|; echo "${RESULT_MARKERS[*]}")" "$REPORT_FILE" | wc -l)

[[ "$RESULTS_COUNT" -gt 0 ]] || fail "No result markers ([PASS], [WARN], [FAIL]) found in the report."
Copy link
Contributor

Choose a reason for hiding this comment

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

Otherwise I think we should do better than this: specify the exact sequence of result markers we expect, perhaps the associated messages

Copy link
Contributor

Choose a reason for hiding this comment

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

Let's drop this from this PR since we already have #44

@Geoka1
Copy link
Contributor Author

Geoka1 commented Jan 6, 2025

@vagos I believe this is good to merge now. Thank you!

@vagos vagos merged commit 9af4060 into binpash:main Jan 6, 2025
9 of 16 checks passed
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