Skip to content

Conversation

@aibaars
Copy link
Contributor

@aibaars aibaars commented Mar 8, 2022

This pull request adds a CI check based on the new codeql generate library-doc-coverage command. It is very similar to the internal test we have, except that it is much faster (30s vs 10m), and adds check annotations to the files. In addition the test output is available to external contributors.

Below some links for an example run:

@adityasharad @alexet

@aibaars aibaars force-pushed the qldoc-test branch 4 times, most recently from bf3a8b3 to 8147c05 Compare March 8, 2022 10:33
@github-actions github-actions bot added the Ruby label Mar 8, 2022
@aibaars aibaars force-pushed the qldoc-test branch 2 times, most recently from e1ea69c to df4696d Compare March 8, 2022 10:43
@aibaars aibaars force-pushed the qldoc-test branch 2 times, most recently from b3e3166 to 6aacc75 Compare March 8, 2022 11:10
@aibaars aibaars marked this pull request as ready for review March 8, 2022 11:20
adityasharad
adityasharad previously approved these changes Mar 11, 2022
Copy link
Collaborator

@adityasharad adityasharad left a comment

Choose a reason for hiding this comment

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

Looks sensible! Minor suggestion only.
For now I understand we are only describing undocumented elements. We should discuss further first if we ever plan to render the HTML output of this command.

for pack_dir in ${changed_lib_packs}; do
lang="${pack_dir%/ql/lib}"
gh codeql generate library-doc-coverage --output="${{ runner.temp }}/${lang}-baseline.txt" --dir="${pack_dir}"
awk -F, '{gsub(/"/,""); if ($4==0 && $6=="public") print "\""$3"\"" }' "${{ runner.temp }}/${lang}-current.txt" | sort -u > "${{ runner.temp }}/current-undocumented.txt"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Minor: You can use ${RUNNER_TEMP} instead of ${{ runner.temp }}, which makes the interpolation a bit less confusing IMO.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ok, done. could you re-approve?

@aibaars aibaars merged commit 3311fed into github:main Mar 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants