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

chore: update node builder version #2094

Closed
wants to merge 4 commits into from

Conversation

matejvasek
Copy link
Contributor

No description provided.

@knative-prow knative-prow bot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Nov 28, 2023
Copy link

codecov bot commented Nov 28, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 56.44%. Comparing base (b97d841) to head (659b807).
Report is 25 commits behind head on main.

❗ Current head 659b807 differs from pull request most recent head 78964ac. Consider uploading reports for the commit 78964ac to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2094      +/-   ##
==========================================
- Coverage   64.21%   56.44%   -7.77%     
==========================================
  Files         108      108              
  Lines       13918    13919       +1     
==========================================
- Hits         8937     7857    -1080     
- Misses       4108     5279    +1171     
+ Partials      873      783      -90     
Flag Coverage Δ
e2e-test ?
e2e-test-oncluster 30.50% <ø> (-0.01%) ⬇️
e2e-test-runtime-go 25.54% <ø> (?)
e2e-test-runtime-python 26.57% <ø> (?)
e2e-test-runtime-quarkus 26.68% <ø> (?)
e2e-test-runtime-rust 25.57% <ø> (?)
e2e-test-runtime-springboot 25.63% <ø> (?)
integration-tests ?
unit-tests-macos-latest 48.85% <ø> (+<0.01%) ⬆️
unit-tests-ubuntu-latest 49.59% <ø> (+<0.01%) ⬆️
unit-tests-windows-latest 48.89% <ø> (+0.03%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@gauron99
Copy link
Contributor

/lgtm

@knative-prow knative-prow bot added the lgtm Indicates that a PR is ready to be merged. label Nov 29, 2023
@jrangelramos
Copy link
Contributor

/lgtm

@matejvasek
Copy link
Contributor Author

/retest

@knative-prow knative-prow bot removed the lgtm Indicates that a PR is ready to be merged. label Jan 15, 2024
@matejvasek
Copy link
Contributor Author

PTAL @lkingland @gauron99

@lkingland
Copy link
Member

lkingland commented Jan 16, 2024

/lgtm
/approve
/hold for flaky tests

@knative-prow knative-prow bot added lgtm Indicates that a PR is ready to be merged. and removed lgtm Indicates that a PR is ready to be merged. labels Jan 16, 2024
Copy link

knative-prow bot commented Jan 16, 2024

New changes are detected. LGTM label has been removed.

Copy link

knative-prow bot commented Jan 16, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: lkingland, matejvasek

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [lkingland,matejvasek]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@matejvasek matejvasek force-pushed the update-node-to-18 branch 2 times, most recently from 8d07825 to 0928cc0 Compare January 16, 2024 18:08
@matejvasek
Copy link
Contributor Author

matejvasek commented Jan 17, 2024

Hmm these are not just flakes. Image build on newer image does not handle signals properly. We must inquiry why.

@matejvasek
Copy link
Contributor Author

There is a bug in npm that is in nodejs-18 image. It does not propagate signals to child processes.

@matejvasek
Copy link
Contributor Author

Node team is looking into this.

@knative-prow-robot knative-prow-robot added needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Jan 22, 2024
matejvasek and others added 3 commits March 12, 2024 10:05
Signed-off-by: Matej Vasek <mvasek@redhat.com>
Signed-off-by: Matej Vasek <mvasek@redhat.com>
@knative-prow knative-prow bot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Mar 12, 2024
@dsimansk
Copy link
Contributor

Rebased to rerun the CI on current version.

@@ -139,7 +139,7 @@ func (b *Builder) Build(ctx context.Context, f fn.Function, platforms []fn.Platf
// Build Config
cfg := &api.Config{}
cfg.Quiet = !b.verbose
cfg.Tag = f.Build.Image
cfg.Tag = f.Image
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it changing the output of si2 build right?

Copy link
Member

Choose a reason for hiding this comment

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

The build config's cfg.Tag should be set to f.Image if it is defined (this indicates a request to build exactly this image using, for example --image= flag via the CLI. If that is not defined, it should use f.Build.Image (the last built image) if it exists, which is essentially rebuilding. It seems like there might be a little missing logic here to choose one or the other? Am I seeing this correctly @gauron99 ?

Copy link
Contributor

Choose a reason for hiding this comment

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

Thanks for the explanation!
So I'd say it's a change unrelated to image version update then. Probably easier to address in an isolated issue/PR? Unless it was trying to solve something else during testing with NodeJS 18 image @matejvasek?

Copy link
Contributor

@gauron99 gauron99 Mar 12, 2024

Choose a reason for hiding this comment

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

client builder should have set the f.Build.Image to whatever the final resolved image is supposed to be (using forced image via f.Image or resolved via registry name etc.) like this , so Im pretty sure the f.Build.Image is correct here. It should be unrelated to node completely

@dsimansk
Copy link
Contributor

There's a error in E2E tests even in unrelated runtimes, e.g. python. That seems like a genuine missing namespace value:

    cmd.go:128: exit status 1
    knative.go:35: services.serving.knative.dev "http-function-python-s2i" not found
    cmd.go:83: /home/runner/work/func/func/func delete --path /tmp/TestFunctionHttpTemplatepython_s2i_test187929058/001/http-function-python-s2i
    cmd.go:127: Error: namespace required

@@ -319,7 +319,7 @@ func (b *Builder) Build(ctx context.Context, f fn.Function, platforms []fn.Platf
}()

opts := types.ImageBuildOptions{
Tags: []string{f.Build.Image},
Tags: []string{f.Image},
Copy link
Member

Choose a reason for hiding this comment

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

Same comment here, I presumed we'd have a check early in the function which uses f.Image if defined, defaulting to f.Build.Image, with an error if neither are defined.

@gauron99
Copy link
Contributor

gauron99 commented Mar 12, 2024

There's a error in E2E tests even in unrelated runtimes, e.g. python. That seems like a genuine missing namespace value:

    knative.go:35: services.serving.knative.dev "http-function-python-s2i" not found
    cmd.go:83: /home/runner/work/func/func/func delete --path /tmp/TestFunctionHttpTemplatepython_s2i_test187929058/001/http-function-python-s2i
    cmd.go:127: Error: namespace required

I think there is an error during deploy actually, previous to this error there is Error: Error response from daemon: No such image: localhost:50000/user/cloudevents-function-python-s2i:latest during the pushing phase looks like, therefore the function is not deployed and namespace not defined during removal (nothing no remove anyways)

probably just related to the f.Build.Image change higher up since it looks like its affecting the s2i builds only

@matejvasek
Copy link
Contributor Author

How that image thingy even got here? I don't know what's right but IMO it belongs to separate PR.

@dsimansk
Copy link
Contributor

How that image thingy even got here? I don't know what's right but IMO it belongs to separate PR.

Might be my not very well done rebase then?

@lkingland
Copy link
Member

How that image thingy even got here? I don't know what's right but IMO it belongs to separate PR.

Might be my not very well done rebase then?

It's very possible this is just a change which sneaked through a rebase, yes, since those lines were recently updated by @gauron99 to refer to f.Build.Image. I think those two changes could be removed, and that might clear up the E2E.

@matejvasek matejvasek closed this Mar 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants