Building a binding for an "older" version (3.0.x) is unsupported (artifact missing)

I am having issues compiling a binding for 3.0.2 (current release version).

What I have done:

  • git clone the repo openhab-addons
  • checked out 3.0.x branch
  • run command mvn clean install -Dohc.version=3.0.2 -U -pl :org.openhab.binding.neato

The error is

[ERROR] Failed to execute goal on project org.openhab.binding.neato: Could not resolve dependencies for project org.openhab.addons.bundles:org.openhab.binding.neato:jar:3.0.3-SNAPSHOT: Could not find artifact net.wimpi:jamod:jar:1.2.4.OH in openhab-release (https://openhab.jfrog.io/openhab/libs-release) -> [Help 1]

What seems to be the problem (officer)
The jamod version is defined on the openhab-core (modbus). For branch 3.0.x the artifact net.wimpi:jamod:jar is set to version 1.2.4.OH.
The version defined in Index of libs-release/net/wimpi/jamod is as of writing 1.3.2.OH and 1.3.3.OH.

What I have tried

  • building main branch without ohc.version (works to build, but does not load in OH3.0.2)
  • building main branch with ohc.version=3.0.2 (fails for missing dependency)
  • building 3.0.x branch without ohc.version (fails for missing dependency)
  • building 3.0.x branch with ohc.version=3.0.2 (fails for missing dependency)
  • cleaning out ~/.m2/repository/org/openhab

Summary
I need to understand if there is a missing dependency net.wimpi.jamod 1.2.4.OH which should be available in openhab.jfrog, or if I need to have some different setup in order to build a binding for latest release version.
Thanks

jfrog shut down on May 1 and is not available any longer…

Thank you for your answer @Bruce_Osborne.
Does this mean that I will just have to wait for an update to the openhab-core to come in for the 3.0.x branch, or can it be overridden locally somehow?

I believe @Kai has tried to make the OH3.0.x artifacts available on artifactory. If you are using the latest from the 3.0.x branch of the repo, please open an issue on GitHub.

1 Like

If you don‘t need that dependency, you can add exclusions to the core-index and the dependency section in bundles. I can show you later.

2 Likes

in bom/openhab-core-index/pom.xml:

  <dependencies>
    <dependency>
      <groupId>org.openhab.core.bom</groupId>
      <artifactId>org.openhab.core.bom.openhab-core</artifactId>
      <version>${ohc.version}</version>
      <type>pom</type>
      <scope>compile</scope>
      <optional>true</optional>
      <exclusions>
        <exclusion>
          <groupId>net.wimpi</groupId>
          <artifactId>jamod</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
  </dependencies>

in bundles/pom.xml

    <dependency>
      <groupId>org.openhab.core.bom</groupId>
      <artifactId>org.openhab.core.bom.openhab-core</artifactId>
      <type>pom</type>
      <scope>provided</scope>
      <exclusions>
        <exclusion>
          <groupId>commons-net</groupId>
          <artifactId>commons-net</artifactId>
        </exclusion>
        <exclusion>
          <groupId>net.wimpi</groupId>
          <artifactId>jamod</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
2 Likes

Nice! That did it, @J-N-K!
Many blessing upon you and your smart home!

2021-05-09 22:15:14.062 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'neato:vacuumcleaner:roborto' changed from UNINITIALIZED (HANDLER_MISSING_ERROR) to INITIALIZING
2021-05-09 22:15:14.076 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'neato:vacuumcleaner:roborto' changed from INITIALIZING to UNKNOWN
2021-05-09 22:15:14.977 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'neato:vacuumcleaner:roborto' changed from UNKNOWN to ONLINE
1 Like