Skip to content

Conversation

arthurscchan
Copy link
Contributor

The original frontend analyser extracted the functions called by each test file and dumped the entire function profile dictionary. However, many functions were found to be redundantly or incorrectly captured, and most fields in the function profile were unused, resulting in bloated JSON output. This PR revamps the logic for test cross-reference extraction by limiting it to only the essential line numbers of function call locations, along with the initialisation and parameter definition lines for arguments used in those calls within the test or example files. This significantly reduces the size of the JSON output and provides more relevant information for web applications and OFG to process, without needing to dump the full function profile or include entire test files in the results.

Signed-off-by: Arthur Chan <arthur.chan@adalogics.com>
Signed-off-by: Arthur Chan <arthur.chan@adalogics.com>
Signed-off-by: Arthur Chan <arthur.chan@adalogics.com>
Signed-off-by: Arthur Chan <arthur.chan@adalogics.com>
Signed-off-by: Arthur Chan <arthur.chan@adalogics.com>
@arthurscchan arthurscchan force-pushed the fix-frontend-analyser-test-xref-logic branch from a00ef18 to 87f1cd9 Compare June 20, 2025 23:15
@arthurscchan arthurscchan marked this pull request as ready for review June 20, 2025 23:22
@DavidKorczynski DavidKorczynski merged commit 55b8cf4 into ossf:main Jun 23, 2025
11 checks passed
@arthurscchan arthurscchan deleted the fix-frontend-analyser-test-xref-logic branch July 2, 2025 10:07
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