0

I'm tasked migrating a java application using H3 api version 3.6.0 to 4.1.1, and I've been dropped into this application and don't know how the api works. There is a call to the method edgeLength that worked in version 3, but I cannot get any parameters to work with it.

h3.edgeLength(9, LengthUnit.km)

The error thrown is

Directed edge argument was not valid
com.uber.h3core.exceptions.H3Exception: Directed edge argument was not valid
    at com.uber.h3core.NativeMethods.edgeLengthKm(Native Method)
    at com.uber.h3core.H3Core.edgeLength(H3Core.java:889)
    ...

I paused at the point of invocation and tried numbers from 0 to 15, then up to 100, tried using the version that takes a hex address, things like that, but always the same exception.

This call worked when the api version was 3.6.0, but not at 4.1.1. I can't step into the api in the debugger because the implementation is native, so I'm at a loss.

Any ideas would be appreciated.

Scott
  • 458
  • 4
  • 10
  • I just changed the call to be getHexagonEdgeLengthAvg and the test case that failed previously now passes. Not sure if this change is right or not. – Scott Aug 24 '23 at 13:59

0 Answers0