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

[Worker/API] Add support for list of languages for a given repository #961

Closed
2 tasks done
Tracked by #741
JerrySentry opened this issue Jan 2, 2024 · 0 comments
Closed
2 tasks done
Tracked by #741
Assignees

Comments

@JerrySentry
Copy link

JerrySentry commented Jan 2, 2024

Update codecov DB to support list of languages for a repository instead of what we have currently which is only one primary language. Primary is defined based on the git provider; Github: most used bytes of code, Gitlab: always null, and Bitbucket: configured language in repo settings.

  1. Either add a new nullable column to repos, something like supported_languages text[] / languages text[]
  • Note: shouldn't need to migrate existing repos.language to new column because data will be updated and overwritten when the sync repo task is triggered when a user clicks the sync button in the UI or whenever the user logs in
  1. Update sync repo task to get list of programming languages for the given repo via its git service APIs then save to new column
    a. Github -> REST API endpoint
    b. Gitlab -> REST API endpoint
    c. Bitbucket -> API doesn't support this, just use the current implementation of having one primary language

  2. Expose list of supported languages list in API (GQL, REST API)

  3. (Cleanup) Investigate anything that currently uses repos.language and see if it makes sense to have it switch to multi language column. Though it might make sense to continue using the existing primary language column as is, in which case may want to rename column to primary_language (and all the refactoring in the code)

Tasks

  1. JerrySentry
  2. task
    adrian-codecov
@JerrySentry JerrySentry self-assigned this Jan 2, 2024
@JerrySentry JerrySentry changed the title [Worker] Add support for list of languages for a given repository [Worker/API] Add support for list of languages for a given repository Jan 2, 2024
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

No branches or pull requests

1 participant