Skip to content

Hold the image addresses and old links partners use, by test - #366

Merged
adamjohnwright merged 1 commit into
mainfrom
partner-links
Sep 29, 2026
Merged

adamjohnwright merged 1 commit into
mainfrom
partner-links

Conversation

@adamjohnwright

Copy link
Copy Markdown
Contributor

Story 4 of specs/009-embeddable-diagram. Other sites already use these addresses, and they won't change their links for us:

  • AllianceGenome's gene pages show reaction figures from the exporter by <img src>.
  • PubChem hosts snapshots of the diagram exporter's images, and links to the Pathway Browser as /PathwayBrowser/#/{stId}.

e2e/partner-links.spec.ts checks these against real ids from the local backend: reaction R-HSA-69891 and pathway R-HSA-2206280.

  • The exporter images: /ContentService/exporter/reaction/{id}.svg and .png, and /ContentService/exporter/diagram/{id}.svg, .png and .jpg, are each that image type. They are checked by their first bytes, not their status, because an image address answering 200 with HTML is exactly the failure this is for.
  • PubChem's link form: /PathwayBrowser/#/{stId} opens that pathway on its stable address. legacy-links.spec.ts covered #{stId} and #{dbId}, not this form.

All six fail against wrong ids: the exporters answer 400, and the link opens no pathway.

The exporters go through the ContentService proxy to Java, not the render service, so they replay in CI with no skips. The pathway was chosen small so that its images record in about 450 KB; the recordings add 1.2 MB in total.

🤖 Generated with Claude Code

Story 4 of specs/009-embeddable-diagram. AllianceGenome's gene pages show
reaction figures from the exporter by <img src>; PubChem hosts snapshots of
the diagram exporter's images and links to the Pathway Browser as
/PathwayBrowser/#/{stId}. Neither will change its links for us.

e2e/partner-links.spec.ts checks, against real ids from the local backend:
- /ContentService/exporter/reaction/{id}.svg and .png, and
  /ContentService/exporter/diagram/{id}.svg, .png and .jpg, are each that
  image type -- by their first bytes, not their status, since an image
  address answering 200 with HTML is the failure this is for;
- /PathwayBrowser/#/{stId}, the form PubChem writes (legacy-links covered
  #{stId} and #{dbId}, not this one), opens that pathway on its stable
  address.

All six fail against wrong ids: the exporters answer 400, and the link
opens no pathway. The exporters go through the ContentService proxy to
Java, not the render service, so they replay in CI with no skips; the
pathway is a small one, so its images record in ~450 KB.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@adamjohnwright
adamjohnwright merged commit 8d612bc into main Sep 29, 2026
6 checks passed
@adamjohnwright
adamjohnwright deleted the partner-links branch September 29, 2026 16:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant