-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
viewport URL includes z-plane #372
base: master
Are you sure you want to change the base?
Conversation
Works as expected. Ready to merge fmpov. |
I guess there's a decision to make about whether to store the actual Z index (0-based) or the UI displayed Z index (1-based). |
Changing the UI is a breaking change and it needs to be considered carefully: not only in iviewer, but in the doc, video etc. |
The feature now works as expected and |
NB: Although the Z and T were never set in the URL before, it's possible that users were constructing their own URLs with Z and T. In which case, the usage of 0-based indexing here instead of 1-based indexing would be a breaking change. |
The possible problem is that the old viewer (that is still turned on by default) uses 1-based index |
OK, so either we stick with |
Trying to look into where these conventions might have been documented (or not), I realized that the webgateway render API also uses 0-based indexing e.g. the following calls work https://idr.openmicroscopy.org/webgateway/render_image/12922202/0/0/ but the following calls will return a 404 https://idr.openmicroscopy.org/webgateway/render_image/12922202/45/0/ Moving forward, unifying on 0-based indexes feels like the most consistent approach across the OMERO.web URLs. For the old viewer, there is definitely a breaking impact. Is this the only place that uses 1-based indexes for Z/T? Is there a way to enfore some compatibility e.g. via key/value pairs or options? |
It's hot, so I may not be thinking very clearly but some points:
|
I am for deprecating the old viewer. One of the problems is that the old viewer code is used in the right-hand panel in the main view. So you can explore the image without opening a viewer. |
What does "deprecating the old viewer" mean for users? Remove it (no viewer)? |
So, should I update the old viewer to use |
that could break many people who have bookmarked the link with |
It could. But do we want the possibility of bookmarks to prevent us from making any changes to our API? An alternative is we use upper case keys for the recent 0-based indices e.g. Django uses a more explicit naming to distinguish in templates:
But then we'd be expected to support 0-based and 1-based indices everywhere. Probably better to make a single breaking change? |
What I am arguing is not any change to the API but the path to get there. W |
Ok, so if we are going to announce a breaking change etc, do we also want to make the change in the UI (iviewer and old viewer) too, as I suggested above? EDIT: There's also OMERO.figure and iviewer if we want to be consistent everywhere. |
Just reviewing this PR again since the bug-fix that user requested is still not released. Perhaps the solution is as Josh suggested: Use |
Does |
Or, to indicate how this maps to the model, you could do |
It would be good to get this fix merged (PR open 2 years now). I would prefer to adopt For old bookmarks of the webgateway viewer, we can handle Plan:
OK @jburel ? |
Fixes #355
To test:
Get Link to Viewport
. Copy the link (notice it includesz=...
--exclude