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

Extend Project class to contain the owner #75

Open
jvcoutinho opened this issue Nov 20, 2019 · 0 comments
Open

Extend Project class to contain the owner #75

jvcoutinho opened this issue Nov 20, 2019 · 0 comments
Labels
enhancement New feature or request

Comments

@jvcoutinho
Copy link
Collaborator

Problem
To get the owner of a project given as a link to the input, we must to pass the access key and request a GET to the GitHub API. I think this is unnecessary effort.

private static String getOwnerName() {
String githubToken = MiningFramework.arguments.getAccessKey()
GithubHelper githubHelper = new GithubHelper(githubToken)
return githubHelper.getUser()['login']
}

Cause
The Project class doesn't have the owner field.

Suggestion
Parse the owner at Project's object creation (input parsing). For URLs, it's already there. For local file paths, you can use some Git tricks to retrieve the URLs.

@jvcoutinho jvcoutinho added the enhancement New feature or request label Nov 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant