Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 28 additions & 2 deletions .github/workflows/python-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,22 @@ jobs:
echo "No test output captured."; exit 0
fi
summary=$(grep -Eo '[0-9]+ skipped' pytest_output.log | tail -1 || true)
# conftest.py writes skipped_tests_report.md whenever anything
# skipped: every skipped test grouped by reason, and — when the
# circuit breaker tripped — which test hit the backend first, the
# URL of the call that failed or timed out and how, and the
# health-probe verdicts. Embed it wherever the skip is reported
# so the reader can debug or decide to ignore.
digest=""
if [ -f skipped_tests_report.md ]; then
digest=$(grep -m1 -oE 'call: \[[^]]+\]|FAILED[^|]*' skipped_tests_report.md | head -1 || true)
{
echo ""
cat skipped_tests_report.md
} >> "$GITHUB_STEP_SUMMARY"
fi
if [ -n "$summary" ]; then
echo "::warning title=Tests skipped — VFB backend unreachable::${summary}. These are NOT test failures and not a problem with this branch: the VFB backend (Neo4j / SOLR / Owlery) did not answer, so those queries went unverified this run. Treat a green check with skips as an incomplete run — re-run once the backend is healthy before relying on it. See the job log for the list."
echo "::warning title=Tests skipped — VFB backend unreachable::${summary}. ${digest:+First failure: ${digest}. }These are NOT test failures and not a problem with this branch: the VFB backend (Neo4j / SOLR / Owlery) did not answer, so those queries went unverified this run. Treat a green check with skips as an incomplete run — re-run once the backend is healthy before relying on it. Full detail (every skipped test with its reason; failing URLs and probe verdicts for backend failures): the job summary and the PR comment."
else
echo "No tests skipped."
fi
Expand All @@ -118,6 +132,16 @@ jobs:
core.info('No pytest_output.log to read: ' + e.message);
}

// conftest.py's skip report: every skipped test grouped by
// reason, plus — for backend failures — the failing calls (as
// clickable links) and the probe verdicts.
let outage = '';
try {
outage = fs.readFileSync('skipped_tests_report.md', 'utf8').trim();
} catch (e) {
core.info('No skipped_tests_report.md (nothing skipped).');
}

const { owner, repo } = context.repo;
const issue_number = context.issue.number;

Expand Down Expand Up @@ -151,7 +175,8 @@ jobs:
`(Neo4j / SOLR / Owlery) did not answer, so those queries went ` +
`unverified. This is not a branch failure — but the run is ` +
`incomplete.\n\n${rerun}` +
(summary ? '\n\n```\n' + summary + '\n```' : ''))
(summary ? '\n\n```\n' + summary + '\n```' : '') +
(outage ? '\n\n' + outage : ''))
: 'Every backend-dependent test reached the VFB backend and ran.',
},
});
Expand All @@ -172,6 +197,7 @@ jobs:
'',
'> ' + rerun,
summary ? '\n```\n' + summary + '\n```' : '',
outage ? '\n' + outage : '',
'',
'<sub>Posted automatically. This comment is removed once a run completes with zero skips.</sub>',
].join('\n');
Expand Down
Loading
Loading