Skip to content

Enhance GHA: "Skills Activity" use Skills Issue directory #8316

@t-will-gillis

Description

@t-will-gillis

Overview

We need to reduce the number of unnecessary GitHub API calls that the "Member Activity Trigger" workflow makes when posting to a user's Skills Issue by providing a user directory.

Action Items

  • Locate the most recent skillsIssueNums.csv file on the Google Drive. Note that it lists each member's GitHub handle, Skills Issue number, Node Id (used with GraphQL), id used with (REST API) and other info.
  • Now review github-actions/activity-trigger/post-to-skills-issue.js. Note that the workflow uses a GraphQL querySkillsIssue() to search for a user's (i.e. eventActor) Skills Issue, and then REST API calls github.request('GET...) and (PATCH...) to search for the "Activity History" comment, and then update it with the new info.
  • Instead, we need the workflow to first search the previously mentioned file to retrieve the user's Skills Issue number and the id that will be used for patching, and if these are found- skip the other queries.
  • If not found, the workflow should perform the searches and save this information to the file.
    There are many ways this could be done, but however this is done the functions should follow the same architecture HfLA is already using. Some suggestions:
  • Save the Skills Issue directory to the github-actions/utils/_data folder, and convert the directory to a JSON.
  • Create a new module in utils that will lookup in the directory and return the information.
  • Might want to pull the previously mentioned searches out of post-to-skills-issue.js and into a module that also will update the directory when needed.

Resources/Instructions

Metadata

Metadata

Assignees

Type

No type

Projects

Status

In progress (actively working)

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions