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

[che-theia] Build hardcodes SHA to use when fetching theia from master branch; cannot override in crw-theia build #15368

Closed
nickboldt opened this issue Nov 29, 2019 · 4 comments
Labels
area/editor/theia Issues related to the che-theia IDE of Che kind/bug Outline of a bug - must adhere to the bug report template. severity/P2 Has a minor but important impact to the usage or development of the system. status/analyzing An issue has been proposed and it is currently being analyzed for effort and implementation approach
Milestone

Comments

@nickboldt
Copy link
Contributor

nickboldt commented Nov 29, 2019

Describe the bug

This snippet of code appears in the ubi8 build for che-theia:

# Clone theia and keep source code in home
RUN git clone --branch ${GIT_BRANCH_NAME} --single-branch https://github.com/${THEIA_GITHUB_REPO} ${HOME}/theia-source-code \
    && cd ${HOME}/theia-source-code && git checkout f255f5a8cb22010aacb8196c8a8f248e111e9945 \
    && cd ${HOME} && tar zcf ${HOME}/theia-source-code.tgz theia-source-code

(from https://github.com/eclipse/che-theia/tree/master/dockerfiles/theia/docker/ubi8/builder-clone-theia.dockerfile

But that commit is from Oct 18, and is not even the latest from the v0.12.0 tag (which includes commits up to Oct 31). So why are we hardcoded to use that one?

Che version

7.3.2 and 7.3.3

Expected behavior

This SHA ought to be a parameter we can pass into the build from Jenkins so I can build from any sha in the theia repo, for any given branch (not just master).

@nickboldt nickboldt added the kind/bug Outline of a bug - must adhere to the bug report template. label Nov 29, 2019
@che-bot che-bot added the status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. label Nov 29, 2019
@nickboldt nickboldt changed the title [che-theia] Build hardcodes SHA to use from master branch; cannot override [che-theia] Build hardcodes SHA to use when fetching theia from master branch; cannot override in crw-theia build Nov 29, 2019
@tolusha
Copy link
Contributor

tolusha commented Dec 2, 2019

/cc @evidolob

@evidolob
Copy link
Contributor

evidolob commented Dec 2, 2019

@nickboldt Why do you need to override SHA commit id?
If you want to use different Theia version (like v0.12.0 tag) than you need to use different che-theia version. If you want to upgrade Theia to v0.12.0 we need full test cycle, to make sure that there are no new bugs/regressions.

@ibuziuk ibuziuk added status/analyzing An issue has been proposed and it is currently being analyzed for effort and implementation approach severity/P1 Has a major impact to usage or development of the system. area/editor/theia Issues related to the che-theia IDE of Che team/ide2 severity/P2 Has a minor but important impact to the usage or development of the system. and removed status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. severity/P1 Has a major impact to usage or development of the system. labels Dec 2, 2019
@nickboldt
Copy link
Contributor Author

Because of this problem I can't use v0.15.0 using a sha from another branch, nor can I use v0.16.0 because it's not out yet.

Step 8/25 : RUN git clone --branch v0.15.0 --single-branch --depth 1 https://github.com/${THEIA_GITHUB_REPO} ${HOME}/theia-source-code     && cd ${HOME}/theia-source-code && git checkout 1eaecd5cbf93468a74988ddcd347402fcbf14cbe     && cd ${HOME} && tar zcf ${HOME}/theia-source-code.tgz theia-source-code
 ---> Running in bb940cece4bf
Cloning into '/home/theia-dev/theia-source-code'...
Note: checking out 'e88b7f3c265025a4d97ebb178d164f84bdb11fab'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

  git checkout -b <new-branch-name>

fatal: reference is not a tree: 1eaecd5cbf93468a74988ddcd347402fcbf14cbe
The command '/bin/sh -c git clone --branch v0.15.0 --single-branch --depth 1 https://github.com/${THEIA_GITHUB_REPO} ${HOME}/theia-source-code     && cd ${HOME}/theia-source-code && git checkout 1eaecd5cbf93468a74988ddcd347402fcbf14cbe     && cd ${HOME} && tar zcf ${HOME}/theia-source-code.tgz theia-source-code' returned a non-zero code: 128

So... I guess I'll check out code from master, then use the SHA that's hardcoded in che-theia for the 7.9.0 release.

@azatsarynnyy azatsarynnyy added this to the 7.13 milestone Aug 20, 2020
@azatsarynnyy
Copy link
Member

fixed by eclipse-che/che-theia#737

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/editor/theia Issues related to the che-theia IDE of Che kind/bug Outline of a bug - must adhere to the bug report template. severity/P2 Has a minor but important impact to the usage or development of the system. status/analyzing An issue has been proposed and it is currently being analyzed for effort and implementation approach
Projects
None yet
Development

No branches or pull requests

6 participants