FHIR Chat · Stack Overflow Error in IG Publisher · IG creation

Stream: IG creation

Topic: Stack Overflow Error in IG Publisher


view this post on Zulip Noemi Deppenwiese (Apr 23 2020 at 13:09):

Running the IG Publisher (1.0.81-SNAPSHOT) on my IG (which used to build fine...) I get the error:

Exception in thread "main" java.lang.StackOverflowError
        at java.util.ArrayList.contains(Unknown Source)
        at org.hl7.fhir.igtools.publisher.Publisher.logDebugMessage(Publisher.java:6846)
        at org.hl7.fhir.igtools.publisher.Publisher.generateSnapshot(Publisher.java:4090)
        at org.hl7.fhir.igtools.publisher.Publisher.fetchSnapshotted(Publisher.java:4190)
        at org.hl7.fhir.igtools.publisher.Publisher.generateSnapshot(Publisher.java:4093)
        at org.hl7.fhir.igtools.publisher.Publisher.fetchSnapshotted(Publisher.java:4190)
        at org.hl7.fhir.igtools.publisher.Publisher.generateSnapshot(Publisher.java:4093)

and so on...
It displays no errors before this one, so I don't really where to look for the cause. Has anyone else also encountered this error?

view this post on Zulip Lloyd McKenzie (Apr 23 2020 at 14:42):

@Grahame Grieve

view this post on Zulip Grahame Grieve (Apr 23 2020 at 21:01):

I certainly don't understand that

view this post on Zulip Grahame Grieve (Apr 23 2020 at 21:17):

I'll have to reproduce this - @Noemi Deppenwiese how do I do that?

view this post on Zulip Noemi Deppenwiese (Apr 24 2020 at 07:45):

The issue seems to be caused by one profile that does not (yet) define any constraints and is just a placeholder. SUSHI generated this as differential for it

"derivation": "constraint",
  "differential": {
    "element": [
      {
        "id": "Encounter",
        "path": "Encounter"
      }
    ]
  }

which seems to cause the publisher loop.

view this post on Zulip Noemi Deppenwiese (Apr 24 2020 at 12:42):

OK... The issue might have been caused by me having a profile declaring itself as its parent... :sweat_smile: and not noticing because the parent file was there, only overwritten by SUSHI with this new profile which had the same ID as a result of a copy-paste-error :sweat_smile: So, not a publisher issue after all. Still, it would be nice to get a "impossible parent profile" error...

view this post on Zulip Chris Moesel (Apr 24 2020 at 13:21):

I thought that SUSHI issued an error if it detected a circular reference in the parent hierarchy. Did you not get a SUSHI error when you declared a profile with itself as a parent, @Etienne Cantineau?

view this post on Zulip Noemi Deppenwiese (Apr 24 2020 at 13:26):

Well, SUSHI did not detect the error because I had one Parent-Profile with the id and one child profile with different "Profile" Value, referencing its parent with the parents "Profile" value but had the same id. So, the parent profile was created but had the same url/filename (because of the id) and was the overwritten with the child profile, so it resulted in a circular reference.... I hope I could explain the issue :)

view this post on Zulip Grahame Grieve (Apr 24 2020 at 21:39):

I'll add it to my todo list. I thought I had already guarded against that


Last updated: Apr 12 2022 at 19:14 UTC