Building Sen2Coral-box from source - Build script directs to old Nexus repository

I have previously built the snap-desktop and snap-engine from source as per these instructions, and am now building the sen2coral-box from source.

As I understand, the installation accesses a repository to complete the build. On April 10th, the link to this repository changed (see blogpost). As far I can tell, the Sen2Coral build script does not point to this new URL. This results in the following error. The URL in this error is the URL to the old nexus repository, hence the failed validity check.

Failed to execute goal on project sen2coral-algorithms: Could not resolve dependencies for project org.esa.sen2coral:sen2coral-algorithms:nbm:1.0.0: Failed to collect dependencies at org.esa.snap:ceres-core:jar:9.0.0-SNAPSHOT: Failed to read artifact descriptor for org.esa.snap:ceres-core:jar:9.0.0-SNAPSHOT: The following artifacts could not be resolved: org.esa.snap:ceres-core:pom:9.0.0-SNAPSHOT (absent): Could not transfer artifact org.esa.snap:ceres-core:pom:9.0.0-SNAPSHOT from/to snap-repo-public (https://snap-build-server.tilaa.cloud/nexus/repository/snap-maven-public/): sun.security.validator.ValidatorException: PKIX path validation failed: java.security.cert.CertPathValidatorException: validity check failed:

Is there any guidance on how to update the build script with the URL to the new repository? Any other information would be really appreciated. Thanks

You need to update the URL to the repositories in the pom.xml.

https://snap-build-server.tilaa.cloud/nexus/repository/snap-maven-public/
needs to be replaced by https://nexus.snap-ci.ovh/repository/snap-maven-public/ in the repositories section.

Also, the versions of SNAP and s2tbx need to be updated in the properties section. The used SNAPSHOT versions are not available anymore. Unfortunately, they have used SNAPSHOT version in a release. You can even try to update to higher 9.0.x versions. But this can lead to errors

In this pom.xml I made the updates.
pom.xml (18.7 KB)

Maybe there are other updates necessary. I haven’t tried to build sen2coral.


EOMasters_icon_60 Marco from EOMasters - Mastering Earth Observation - Support at Kofi_cup_40x30

Hi Marco,

Thanks for this. This definitely helped, but lead to a different error. After a bit more digging, I went into your updated pom file and also updated the snap and s2tlbx installers from

<properties>
    <snap.version>9.0.0</snap.version>
    <s2tbx.version>9.0.0</s2tbx.version>

to

<properties>
    <snap.version>9.0.8</snap.version>
    <s2tbx.version>9.0.2</s2tbx.version>

A successful build of sen2coral was then completed with:

$ mvn clean install -DskipTests=true

Thanks again for your help

1 Like