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 editor docker image build fails #20716

Closed
vinokurig opened this issue Nov 2, 2021 · 16 comments · Fixed by che-incubator/che-workspace-telemetry-client#76 or eclipse-che/che-theia#1246
Assignees
Labels
area/telemetry Issues related to Che telemetry feature kind/bug Outline of a bug - must adhere to the bug report template. severity/blocker Causes system to crash and be non-recoverable or prevents Che developers from working on Che code.
Milestone

Comments

@vinokurig
Copy link
Contributor

Describe the bug

The docker build command for the che-theia editor fails with an error:

#21 16.43 [3/5] Fetching packages...
#21 58.89 error Command failed.
#21 58.89 Exit code: 128
#21 58.89 Command: git
#21 58.89 Arguments: ls-remote --tags --heads git://github.com/stoplightio/moxios
#21 58.89 Directory: /home/theia-dev/theia-source-code
#21 58.89 Output:
#21 58.89 fatal: remote error: 
#21 58.89   The unauthenticated git protocol on port 9418 is no longer supported.
#21 58.89 Please see https://github.blog/2021-09-01-improving-git-protocol-security-github/ for more information.
#21 58.89 info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
------
executor failed running [/bin/sh -c if [ -z $GITHUB_TOKEN ]; then unset GITHUB_TOKEN; fi &&     yarn ${YARN_FLAGS}]: exit code: 128

Che version

next (development version)

Steps to reproduce

Run ./build.sh --build-args:GITHUB_TOKEN=${GITHUB_TOKEN},THEIA_VERSION=master,THEIA_COMMIT_SHA=a73a746bfdefc115edb506f2351b5f4e3f267077 --tag:next --branch:master --git-ref:refs\\/heads\\/master --skip-tests --dockerfile:Dockerfile.alpine form the root of the che-theia project.

Expected behavior

The docker build command should finish successfully.

Runtime

minikube

Screenshots

No response

Installation method

chectl/next

Environment

macOS

Eclipse Che Logs

No response

Additional context

No response

@vinokurig vinokurig added kind/bug Outline of a bug - must adhere to the bug report template. severity/blocker Causes system to crash and be non-recoverable or prevents Che developers from working on Che code. area/editor/theia Issues related to the che-theia IDE of Che labels Nov 2, 2021
@RomanNikitenko
Copy link
Member

I faced with the problem as well...

@benoitf
Copy link
Contributor

benoitf commented Nov 2, 2021

BTW why are we using a fork of moxios lib ?

@RomanNikitenko
Copy link
Member

RomanNikitenko commented Nov 2, 2021

BTW why are we using a fork of moxios lib ?

It looks like it was added a long time ago by @davidfestal as a dependency for che-workspace-telemetry-client

@azatsarynnyy
Copy link
Member

looks like must be fixed on che-workspace-telemetry-client side
https://github.com/che-incubator/che-workspace-telemetry-client/blob/6c2261e7b19d95dcbc77f4fff82b7ab059dcc8bf/javascript/src/typescript/package.json#L24
@ibuziuk could someone from your team look at it?
Most likely, it can be replaced by https://www.npmjs.com/package/moxios

@azatsarynnyy
Copy link
Member

git:// protocol is not supported anymore for unauthenticated GitHub requests
https://github.blog/2021-09-01-improving-git-protocol-security-github/#no-more-unauthenticated-git

@azatsarynnyy
Copy link
Member

@vinokurig @RomanNikitenko you can test Che-Theia build, as the corresponding fix is applied che-incubator/che-workspace-telemetry-client#76

latest @eclipse-che/workspace-telemetry-client is published to https://www.npmjs.com/package/@eclipse-che/workspace-telemetry-client

@vinokurig
Copy link
Contributor Author

vinokurig commented Nov 3, 2021

Another error appears:

 => ERROR [builder 15/16] RUN if [ -z ghp_***********l ]; then unset GITHUB_TOKEN; fi &&     cd plugins && ./foreach_yarn                                                                                    49.1s
------
 > importing cache manifest from eclipse/che-theia:next:
------
------
 > [builder 15/16] RUN if [ -z ghp_*********** ]; then unset GITHUB_TOKEN; fi &&     cd plugins && ./foreach_yarn:
#23 0.417 
#23 0.417 ✍️  Process plugin containers-plugin
#23 0.419 
#23 0.419 ✍️  Running `yarn` on /home/theia-dev/theia-source-code/plugins/containers-plugin
#23 0.670 yarn install v1.22.5
#23 1.040 [1/5] Validating package.json...
#23 1.094 [2/5] Resolving packages...
#23 15.65 [3/5] Fetching packages...
#23 30.85 warning url-loader@1.1.2: Invalid bin field for "url-loader".
#23 39.68 error Incorrect hash when fetching from the cache for "moxios". Cache has undefined and remote has "9d702c8eafee4b02917d6bc400ae15f1e835cf51". Run `yarn cache clean` to fix the problem
#23 39.68 info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
------
executor failed running [/bin/sh -c if [ -z $GITHUB_TOKEN ]; then unset GITHUB_TOKEN; fi &&     cd plugins && ./foreach_yarn]: exit code: 1

@azatsarynnyy azatsarynnyy added the area/editor/theia Issues related to the che-theia IDE of Che label Nov 3, 2021
@ibuziuk
Copy link
Member

ibuziuk commented Nov 3, 2021

error Incorrect hash when fetching from the cache for "moxios". Cache has undefined and remote has "9d702c8eafee4b02917d6bc400ae15f1e835cf51". Run yarn cache clean to fix the problem

could you make sure that the dependency is referenced the following way from theia https://github.com/che-incubator/che-workspace-telemetry-client/pull/76/files#diff-0fb426fdabbd0bfb746e90dfdbc5c602082807853c4f91560e6460fbf6c56385R3744 ?

@vinokurig
Copy link
Contributor Author

could you make sure that the dependency is referenced the following way from theia https://github.com/che-incubator/che-workspace-telemetry-client/pull/76/files#diff-0fb426fdabbd0bfb746e90dfdbc5c602082807853c4f91560e6460fbf6c56385R3744 ?

I applied these changes for my local che-theia but it didn't help

@azatsarynnyy
Copy link
Member

@vinokurig do you see the same error or another one?

@vinokurig
Copy link
Contributor Author

@azatsarynnyy

@vinokurig do you see the same error or another one?

The same error as #20716 (comment)

benoitf added a commit to benoitf/che-theia that referenced this issue Nov 3, 2021
should fix eclipse-che/che#20716

Change-Id: Ie76e95009e3721411ae8abd4eae6863c41c1b4c8
Signed-off-by: Florent Benoit <fbenoit@redhat.com>
benoitf added a commit to benoitf/che-theia that referenced this issue Nov 3, 2021
should fix eclipse-che/che#20716

Change-Id: I9b0c709dc83b0603a6ef08af4f752f6f0918d166
Signed-off-by: Florent Benoit <fbenoit@redhat.com>
@azatsarynnyy
Copy link
Member

@azatsarynnyy
Copy link
Member

now, it fails with

Error: [compile] src/node/k8s-telemetry-service-impl.ts(11,48): error TS7016: Could not find a declaration file for module '@eclipse-che/workspace-telemetry-client'. '/home/theia-dev/theia-source-code/node_modules/@eclipse-che/workspace-telemetry-client/dist/server.js' implicitly has an 'any' type.

@benoitf
Copy link
Contributor

benoitf commented Nov 3, 2021

yes investigating...

benoitf added a commit to benoitf/che-theia that referenced this issue Nov 3, 2021
should fix eclipse-che/che#20716

Change-Id: I9b0c709dc83b0603a6ef08af4f752f6f0918d166
Signed-off-by: Florent Benoit <fbenoit@redhat.com>
benoitf added a commit to benoitf/che-theia that referenced this issue Nov 3, 2021
should fix eclipse-che/che#20716

Change-Id: I9b0c709dc83b0603a6ef08af4f752f6f0918d166
Signed-off-by: Florent Benoit <fbenoit@redhat.com>
@benoitf
Copy link
Contributor

benoitf commented Nov 3, 2021

should be fixed now 👍

https://github.com/eclipse-che/che-theia/runs/4091580747?check_suite_focus=true

@azatsarynnyy azatsarynnyy assigned benoitf and ibuziuk and unassigned azatsarynnyy Nov 3, 2021
@azatsarynnyy azatsarynnyy removed sprint/current team/editors area/editor/theia Issues related to the che-theia IDE of Che labels Nov 3, 2021
@azatsarynnyy azatsarynnyy added this to the 7.39 milestone Nov 3, 2021
benoitf added a commit to eclipse-che/che-theia that referenced this issue Nov 3, 2021
should fix eclipse-che/che#20716

Change-Id: I9b0c709dc83b0603a6ef08af4f752f6f0918d166
Signed-off-by: Florent Benoit <fbenoit@redhat.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/telemetry Issues related to Che telemetry feature kind/bug Outline of a bug - must adhere to the bug report template. severity/blocker Causes system to crash and be non-recoverable or prevents Che developers from working on Che code.
Projects
None yet
5 participants