Skip to content

Firefly-2026: url api: added SIA, clean up of hipsPanel#1973

Open
robyww wants to merge 1 commit into
devfrom
FIREFLY-2026-urlapi
Open

Firefly-2026: url api: added SIA, clean up of hipsPanel#1973
robyww wants to merge 1 commit into
devfrom
FIREFLY-2026-urlapi

Conversation

@robyww

@robyww robyww commented Jun 23, 2026

Copy link
Copy Markdown
Contributor

Firefly-2026: url api: added SIA, clean up of hipsPanel

  • Updated todo item in StandaloneFireflyLanding.jsx DEFAULT_CHIPS
  • also a little refactor of PositionParser, there was overlap with CoordSys.js

Testing

- also a little refactor of PositionParser, there was overlap with CoordSys.js
@robyww robyww requested a review from jaladh-singhal June 23, 2026 22:17
@robyww robyww self-assigned this Jun 23, 2026
@robyww robyww added this to the 2026.2 milestone Jun 23, 2026

@jaladh-singhal jaladh-singhal left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing this @robyww. The landing page examples of SIA and HiPS are consistent now and ?api=sia is working correctly.

But I'm finding ?api=hipsPanel confusing and I think we can improve its design.

// TODO: api=hipsPanel doesn't allowing selecting a HiPS server without executing the search, need to make "uri" not execute
label: '🌐 SDSS HiPS view of M81 →',
uri: '?api=hipsPanel&showPanel=true&ra=148.88822&dec=69.06529&sr=40m&uri=ivo://CDS/P/SDSS9/color',
url: '?api=hipsPanel&showPanel=true&ra=148.88822&dec=69.06529&sr=4d&uri=ivo://CDS/P/SDSS9/color',

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
url: '?api=hipsPanel&showPanel=true&ra=148.88822&dec=69.06529&sr=4d&uri=ivo://CDS/P/SDSS9/color',
url: '?api=hipsPanel&showPanel=true&ra=148.88822&dec=69.06529&sr=2d&uri=ivo://CDS/P/SDSS9/color',

Can you zoom more? otherwise I see incomplete patches of HiPS at 4deg FOV and scientist wanted to focus on M81 only.

Comment on lines 119 to +125
showPanel: {desc:'show HiPS panel'},
[ReservedParams.POSITION.name]: ['coordinates to center HiPS',...ReservedParams.POSITION.desc],
[ReservedParams.SR.name]: ['Radius of the field of view of the HiPS',...ReservedParams.SR.desc],
hipsListName: {desc:'a HiPS list server name'},
hipsListUrl: {desc:'a HiPS list server url'},
uri: {desc:'if included, the HiPS panel will not initially show: the HiPS will load'},
uri: {desc:'not using the showPanel parameter, the HiPS will load, this is the same as cmd=hips'},
execute: 'use with showPanel, true or false - if true execute the HiPS load'

@jaladh-singhal jaladh-singhal Jun 25, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As API user, I found this pretty confusing since execute=false overlaps with showPanel. I gave it more thought... we can remove showPanel, and fold it into the execute pattern

?api=hipsPanel Behaviour Current params Proposed params
Open panel showPanel=true N/A
Open panel with HiPS list pre-added showPanel=true + hipsListUrl hipsListUrl alone
Open panel with uri pre-selected showPanel=true + uri uri alone
Load HiPS directly uri alone or showPanel=true + uri + execute=true uri + execute=true

Since the rest of the URL API already uses execute=false → open panel, execute=true → submit, hipsPanel can follow the same pattern. showPanel can be dropped entirely - the command is already called hipsPanel, so opening the panel is the default.

About the "N/A" in above table, it's consistent with tap, sia, etc. which also require at least one param since a bare panel can always be opened via ?api=menu&tab=.

Besides, this will need changes in:

  • validateHiPSPanel to enforce that hipsListUrl or uri must be present (since bare ?api=hipsPanel correctly falls through to the API command help page).
  • "add the toolbar option" branch to run when execute=false (i.e. whenever the panel is shown) since it currently only runs inside the showPanel=true block.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

HiPS panel was added for rubin, it has three uses. add a new hips service (hipsListUrl), showing the panel, or searching. It was added for rubin so they could bring firefly up with a extra hips configurations for experimenting. These configuration can show up in other places beside the HiPS panel.

This is different than most search panels.

i agree that we needed to add execute and set the uri correctly. However, I don't agree we should remove showPanel. Having showPanel is not an accident it is necessary to completely implement all the use cases. It could be refactored but I don't thing there is a better way that how it is. Besides, I don't want to break the backward compatibility.

@jaladh-singhal jaladh-singhal Jun 25, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To preserve the backward compatibility, we can safely remove execute param since showPanel=falsy is equivalent to execute=true.

Then the param descriptions (from User's POV) become:

  • showPanel: {desc:'show HiPS panel'}, -> showPanel: {desc: 'Show HiPS search panel. If undefined or false, loads the HiPS (executes the HiPS search'},
  • uri: {desc:'not using the showPanel parameter, the HiPS will load, this is the same as cmd=hips'} -> uri: {desc:'URI of the HiPS to load, same as in cmd=hips. If showPanel is true, it selects the HiPS from the HiPS list else it loads the HiPS.'},
  • execute: 'use with showPanel, true or false - if true execute the HiPS load' -> delete

Then you will just need couple of lines of changes in code to remove the execute branch (L267-L268). And else if you added in L271 is already ensuring showPanel=false + uri executes the HiPS search.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants