-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
GH-3397: Implemented the HTTP-based authentication for Git in Electron. #3426
Conversation
For reviewers: it is in an early preview state.
What it does not yet support:
If you want to try out:
|
8d74813
to
9eb02aa
Compare
@marcdumais-work, this PR contains a few resources that are based on VS Code. Can you please assist me what to do to start the CQ process? Thank you! |
Hi @kittaakos, I am learning how to do this ATM, so let's try together. If you would add me in cc to the CQ/IP record, once created, I can more easily follow. ref: https://www.eclipse.org/legal/EclipseLegalProcessPoster.pdf
I think we then need to attach the copied code (from original vscode project) to the IP record, that I think is automatically created when submitting the CQ. A zip file where only the copied file, in their original context, are preserved. e.g. keep the directory structure and copied files. Maybe also e.g. the original LICENSE file. |
Hi @kittaakos Nice, thanks. A couple of comments:
I added a quick comment on the CQ about the project type and to point towards our previous vscode CQ. |
@marcdumais-work, thanks for the feedback.
👍 Is it required? I must have missed it.
The files are not just borrowed but modified too. I do not know if this matters.
Me neither. Do I need to collect all files (from this PR) and attach it as a ZIP archive? Let's wait for the feedback for the CQ. What do you think?
I do not understand it. |
Interesting. However I think in that case the reason for needing a CQ was that the patch size was over the 1000 lines threshold and from a non-committer / non-committer-company. The copied code came from an Eclipse Foundation project, so it was already known to be license-compatible. So maybe not the same case exactly.
+1. We can learn and then adjust for later CQs |
} | ||
|
||
async clone(remoteUrl: string, options: Git.Options.Clone): Promise<Repository> { | ||
const { localUri, branch } = options; | ||
const exec = await this.execProvider.exec(); | ||
await clone(remoteUrl, this.getFsPath(localUri), { branch }, { exec }); | ||
const [exec, env] = await Promise.all([this.execProvider.exec(), this.gitEnv.promise]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor: we could also have a single initialized: Deferred
to await on, and in the init
we could set both properties.
but this is fine as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works nicely! Thanks!
🎉
On Windows, I still have the following issue:
Runninng |
I have managed to get this running (again) on OS X with and without the clusters, and on Windows without the clusters. There is a caveat, it seems, named pipe servers cannot be started from a cluster worker on Windows.
I need to find a solution for that. |
It works with the patch. I have replaced the named pipes with a pure HTTP server. I need to squash the commits. |
From email discussions with Sharon, I now understand better. For this case, it's the original vscode files that need to be attached to the CQ. Given that you are a committer on the project, the main concern for the Foundation is to confirm license compatibility of the files we are effectively forking. Even if it's know a project has a compatible license, a given file can legitimately contain license info that's different from the project it's in. Should we miss a case like that for a file we copy, it could have significant consequences. Hence the CQ for this case in interested in the upstream version of the files.
For the CQ, no. It does of course matters that we properly maintain files that we have forked. What that means may vary depending on each file's original license. But it seems generally assumed that committers and the project can take care of that aspect, without automatic preemptive oversight. @kittaakos I have sent you an email that covers a bit more. Please ask if there's anything. |
Thank you for the help, @marcdumais-work! I will update the PR. |
112fd02
to
67fabac
Compare
@marcdumais-work, I have updated the PR to use the original MIT copyright from |
Thanks @kittaakos . Reminder: please click the |
Thanks! 👍 |
@marcdumais-work, did I get this correctly, we have the green lights with the CQ, right? Thanks! |
The CQ registered for this PR is now "license-certified": http://dev.eclipse.org/ipzilla/show_bug.cgi?id=18131. Check-in can proceed when otherwise ready - thanks for your patience @kittaakos |
If a Git operation (fetch, pull, merge, ...) requires authentication, the Theia backend will ask the frontend for the username and password. User credentials are neither stored nor reused. In electron, if a Git operation fails due to authentication, we report it back to the user. This PR does not change the behavior of the browser-based application. Closes: #3397 Signed-off-by: Akos Kitta <kittaakos@typefox.io>
I have verified it once more on Windows, I am merging this PR. |
Closes: #3397
Signed-off-by: Akos Kitta kittaakos@typefox.io
Resources for CQ:
askpass-empty.sh
askpass-main.ts
askpass.sh
askpass.ts