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

Add a workshop validation route #229

Merged
merged 4 commits into from
Feb 12, 2018

Conversation

jaredkhan
Copy link
Contributor

@jaredkhan jaredkhan commented Feb 10, 2018

Fixes #222

Adds a route /workshops/validate/:workshopId
That parses the workshop repo at github.com/hackersatcambridge/workshop-<workshopId> and prints results for quick validation of workshop repos.

Screenshots (for frontend changes only):
Some results:
screen shot 2018-02-10 at 15 33 37
screen shot 2018-02-10 at 15 34 18
screen shot 2018-02-10 at 15 34 43

There is an issue with this in the dev environment. Trying to validate a workshop where the repo doesn't exist will cause an indefinite request and subsequent reloads of the server in the dev environment will fail due to this request still holding the port open (as far as I can tell). This is due to the Git command requesting a username which can't be given so hangs.

@jaredkhan jaredkhan requested a review from moosichu February 10, 2018 15:38
static var workshopVerifyHandler: RouterHandler = { request, response, next in
if let workshopId = request.parameters["workshopId"] {
let workshopURL = "https://github.com/hackersatcambridge/workshop-\(workshopId)"
// Pull the repo to /test/id repo
Copy link
Contributor

Choose a reason for hiding this comment

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

Naughty irrelevent

@moosichu
Copy link
Contributor

Created #232 for situations where a completely incorrect git repo is accidentally provided.

@moosichu moosichu merged commit 4a43c00 into hackersatcambridge:master Feb 12, 2018
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