Git Product home page Git Product logo

Comments (8)

sschuberth avatar sschuberth commented on August 21, 2024

Interestingly, it works for me when building the image locally via docker build -t ort ., that image does contain scancode at /opt/python/shims/scancode.

Maybe we're just tagging the wrong image instead of something being wrong with the build?

from ort.

sschuberth avatar sschuberth commented on August 21, 2024

The only possibly relevant change between 22.2.0...22.3.0 seems to be ae16d01, but I currently do not see how it could be related.

from ort.

heliocastro avatar heliocastro commented on August 21, 2024

Should be, reverting it make image works again. I will try to analyze it afternoon

from ort.

heliocastro avatar heliocastro commented on August 21, 2024

I think we have a bigger structural problem. Looking here, https://github.com/oss-review-toolkit/ort/actions/runs/9098861442/job/25010063746#step:11:155, is clear that our build on Github is pulling only the caches, disregarding the changes on the Dockerfile.
On my previous approach i added an invalidate switch to the older context process.
We need to make it similar to the new docker otherwise this problem will occurs when some changes happens that affects docker and we will not notice at all.
And this explains why local builds work.

from ort.

sschuberth avatar sschuberth commented on August 21, 2024

is clear that our build on Github is pulling only the caches, disregarding the changes on the Dockerfile.

But why is that a problem? Just pulling / populating the cache should be no issue, because if the Dockerfile was modified, the cache entries should simply not be used, but relevant parts would be built from scratch. AT least that's how it should be.

from ort.

sschuberth avatar sschuberth commented on August 21, 2024

Not sure what the issue was, but it's gone with release 22.5.0. I.e., running

docker run --entrypoint /opt/python/shims/scancode -it ghcr.io/oss-review-toolkit/ort:22.5.0

gives

Usage: scancode [OPTIONS] <OUTPUT FORMAT OPTION(s)> <input>...
Try the 'scancode --help' option for help on options and arguments.

Error: Invalid value: At least one input path is required.

as expected.

from ort.

heliocastro avatar heliocastro commented on August 21, 2024

Actually there is an explanation.

If you look few commits before, @fviernau update some of python dependencies, which invalidated the cache for the "pythonbuild" layer.

Before, only the "python" layer was copied from cache, as "pythonbuild" layer was never regenerated.

"python" layer was cached before the ARG change, so when processed by the runtime layer is always a hit and miss.
After the change in some of dependencies, "pythonbuild" layer was built, "python" layer need to update itself, and then the image was fixed.

The only question remaining is why the cache missed scancode after the transition, need to keep an eye for future builds.

from ort.

sschuberth avatar sschuberth commented on August 21, 2024

But the funny thing was that IIRC Python was present in the image, but just ScanCode was not...

from ort.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.