openrave icon indicating copy to clipboard operation
openrave copied to clipboard

WIP: Save json with uri hint

Open snozawa opened this issue 1 year ago • 2 comments

Summary

  • Use uriHint by default.

Description

  • Without uriHint, referenceUri is contained into saved json file.
  • It seems the current jsonwriter.cpp only contains all the resolved bodies into one file, so referenceUri seems unnecessary.
  • In addition, if saved referenceUri is unnecessarily contained in the file,
    • When we load it by jsonreader.cpp, warning message is shown.
    • Other non-openrave model loader software cannot load it because referenced file does not exist.
  • I added noUriHint option just in case. It's unnecessary right now, but in future, once we support file saving preserving the reference files, it might be necessary.

snozawa avatar May 03 '24 12:05 snozawa

Changing default option like this could affect a lot... we should have ziyan and yoshiki comment on this.

rdiankov avatar May 03 '24 14:05 rdiankov

Changing default option like this could affect a lot... we should have ziyan and yoshiki comment on this.

thanks for your comment!

@yoshikikanemoto @ziyan

  • I guess, the current jsonwriter.cpp does not require referenceUri. I'm not fully sure about the negative effect if we remove referenceUri. But, I'm not also sure there is positive effect if we have referenceUri.
  • In my understanding, referenceUriHint is something like comment, and no behavioral effect for the saved json file. Is this correct?

Thanks!

p.s. It looks some tests are failing and needs to investigate.

snozawa avatar May 03 '24 15:05 snozawa