FHIR Chat · Mismatch between the URLs and those generated in Pseudo JSON · IG creation

Stream: IG creation

Topic: Mismatch between the URLs and those generated in Pseudo JSON


view this post on Zulip Andrew Patterson (May 23 2018 at 05:44):

I am finding the pseudo JSON structures that are generated for my profiles have URLs that don't match those I get from Jekyll..

My real links are StructureDefinition-AAAAAA.html, but the pseudo JSON is linking to StructureDefinition/AAAAAA.html

If I try to drop the real profile pages into a nested folder structure then other things break (like all the image links). Is there a setting controlling this?

mismatch.JPG

view this post on Zulip Andrew Patterson (May 23 2018 at 05:48):

I get the same in the snapshot display too.. mismatch2.JPG

view this post on Zulip Andrew Patterson (May 23 2018 at 05:50):

If it was generating links to the canonical URL for the profile then that would be fine.. i.e. if it was making a reference to http://genovic.org/StructureDefinition/GenoVicSpecimen then that would be fine - because I already have things in the canonical namespace to bounce pages to their publish location.

But the URL they are generating is to the real published webserver (on github pages) - but just with a slash rather than a dash..

view this post on Zulip Grahame Grieve (May 23 2018 at 06:38):

this is about the settings in your ig.json file - can you send it to me?

view this post on Zulip Andrew Patterson (May 23 2018 at 06:42):

yes, just found a copy

view this post on Zulip Andrew Patterson (May 23 2018 at 06:43):

  "source": "implementationguide-GenoVic.xml",
  "version": "3.0.1",
  "license": "not-open-source",
  "dependencyList": [],
  "spreadsheets": [],
  "npm-name": "mgha.genovic",
  "sct-edition": "http://snomed.info/sct/32506021000036107",
  "special-urls": [
  ],
  "extraTemplates": [
    "mappings"
  ],
  "tool": "jekyll",
  "canonicalBase": "http://genovic.org.au/fhir",
  "paths": {
    "temp": "temp",
    "resources": [
      "resources",
      "example-csharp-generate-somatic",
      "example-java-generate-singleton",
      "example-python-generate-trio",
      "examples",
      "resources-extensions"
    ],
    "pages": "pages",
    "txCache": "txCache",
    "output": "output",
    "qa": "qa",
    "specification": "http://hl7.org/fhir/STU3"
  },
  "logging": ["init", "progress", "context", "html", "tx"],
  "defaults": {
  },
  "resources": {
  }
}

view this post on Zulip Grahame Grieve (May 23 2018 at 06:43):

yes well, you'll have to populate something in the resources : {} section

view this post on Zulip Andrew Patterson (May 23 2018 at 06:44):

All the resources come in via the IG.xml..

view this post on Zulip Andrew Patterson (May 23 2018 at 06:45):

(as in I managed to just have a single reference to each resource so I thought that was better)
But if I do need to put them again in resources in ig.json I can..

view this post on Zulip Grahame Grieve (May 23 2018 at 06:45):

yes but you have to tell the IG publisher where you've chosen to publish them. It doesn't know that, or tell you where to put them

view this post on Zulip Andrew Patterson (May 23 2018 at 06:46):

Ahh.. the resources section had all the stuff about templates and everything (which I don't need) - so I thought I could get away without them at all

view this post on Zulip Grahame Grieve (May 23 2018 at 06:46):

no. this is what will happen if you try

view this post on Zulip Andrew Patterson (May 23 2018 at 06:46):

Ok.. my bad.. thanks

view this post on Zulip Andrew Patterson (May 23 2018 at 06:47):

In good news - other than these couple of URLs - it all works without them there!

view this post on Zulip Grahame Grieve (May 23 2018 at 06:47):

the problem is that that piece has turned into a super complex monster trying to support all the different things people have done with the html organization. That's why we're introducing templates - to narrow that complexity to the few who really care

view this post on Zulip Andrew Patterson (May 23 2018 at 06:49):

Yeah I think my HTML is simplified - but I understand supporting them all makes it complex.. I've just got the initial phase where it turns all the resources into XHTML with no templating - and then the entire rest of the process is pure Jekyll..

view this post on Zulip Grahame Grieve (May 23 2018 at 06:51):

try adding this:

view this post on Zulip Grahame Grieve (May 23 2018 at 06:51):

"path-pattern" : "[type]-[id].html",

view this post on Zulip Grahame Grieve (May 23 2018 at 06:51):

to the root object, not in the resources section

view this post on Zulip Andrew Patterson (May 23 2018 at 06:58):

Brilliant.. that's fixed it completely.. thanks again

view this post on Zulip Grahame Grieve (May 23 2018 at 06:59):

great

view this post on Zulip Oliver Egger (May 23 2018 at 09:05):

thx @Grahame Grieve for this path-pattern, that helped my long outstanding issue with my ig also! (no listing of resources required in ig.json coming from the implementationguide.xml)


Last updated: Apr 12 2022 at 19:14 UTC