Skip to content

Conversation

philippotto
Copy link
Member

Based on 25.06.0 + 41d8490.

philippotto and others added 6 commits May 26, 2025 14:36
* hide toolkit switcher in read-only and fix+refactor tool setting/cycling

* switch to the default toolkit if the current annotation was opened in read-only mode

* add padding to the segment id in the list if a segment name exists

* fix import

* update changelog

* also hide toolkit switcher in arbitrary modes

* also switch to default toolkit if oblique or flight mode is activated

* lint
…8656)

* create new tree map when re-assigning tree ids instead of adding to old map

* add tests for addTreesAndGroupsAction

* update changelog

* fix typo

* also assert ids
Compiler didn’t catch that we passed the bool to the wrong argument.

- Create volume task type
- Create task with this task type
- In dashboard, get this task, annotate some, finish
- In task list view, click view on this task
- Should work (CompoundTask in URI)

- fixes https://scm.slack.com/archives/C02H5T8Q08P/p1748888339790129

------
- [x] Updated
[changelog](../blob/master/CHANGELOG.unreleased.md#unreleased)
- [x] Considered [common edge
cases](../blob/master/.github/common_edge_cases.md)
@philippotto philippotto self-assigned this Jun 3, 2025
@philippotto philippotto requested a review from fm3 June 3, 2025 08:48
Copy link
Contributor

coderabbitai bot commented Jun 3, 2025

📝 Walkthrough

Walkthrough

This update revises changelog and migration documentation to reflect the 25.06.0 and 25.06.1 releases. It adds detailed entries for new features, improvements, bug fixes, and database migrations, while updating unreleased documentation to use the latest release as the comparison base and removing resolved or outdated entries.

Changes

Files Change Summary
CHANGELOG.released.md Added release notes for versions 25.06.0 and 25.06.1, detailing features, fixes, and improvements.
CHANGELOG.unreleased.md Updated comparison base to 25.06.1; removed resolved fixed entries; retained relevant unreleased changes.
MIGRATIONS.released.md Added entries for 25.06.0 (with three new evolutions) and 25.06.1 (no evolutions); maintained formatting.
MIGRATIONS.unreleased.md Updated comparison link to 25.06.1; removed extra blank line; listed current unreleased SQL evolution.

Possibly related PRs

  • Release 25.06.0 #8654: Updates changelog and migration guides for releases 25.06.0 and 25.06.1, covering the same features, fixes, and database evolutions as this PR.

Suggested reviewers

  • fm3

Poem

A changelog grows, a story told,
Of features new and bugfix gold.
Migrations march in tidy rows,
As version numbers upward go.
🐇 With every hop, the docs align—
Release notes crisp, migrations fine!
Onward to the next design!


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between cdfa6cf and 6868049.

📒 Files selected for processing (2)
  • CHANGELOG.unreleased.md (1 hunks)
  • MIGRATIONS.unreleased.md (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • MIGRATIONS.unreleased.md
  • CHANGELOG.unreleased.md
⏰ Context from checks skipped due to timeout of 90000ms (3)
  • GitHub Check: build-smoketest-push
  • GitHub Check: backend-tests
  • GitHub Check: frontend-tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🧹 Nitpick comments (4)
MIGRATIONS.released.md (1)

9-23: Release documentation looks correct, but fix markdown style issues.

The release entries for versions 25.06.1 and 25.06.0 follow the proper format and include appropriate migration information.

However, there are markdown style violations flagged by static analysis:

-### Postgres Evolutions:
+### Postgres Evolutions

Apply this change to both lines 12 and 18 to remove trailing punctuation from headings, which violates markdown style guidelines (MD026).

🧰 Tools
🪛 markdownlint-cli2 (0.17.2)

12-12: Trailing punctuation in heading
Punctuation: ':'

(MD026, no-trailing-punctuation)


18-18: Trailing punctuation in heading
Punctuation: ':'

(MD026, no-trailing-punctuation)

CHANGELOG.released.md (3)

20-22: American English spelling for “focusing”.
Change “focussing” to “focusing” to match the document’s style.

Apply this diff:

- - Instead of pasting a dataset position from the clipboard to the position input box, you can simply paste it without focussing the position input first.
+ - Instead of pasting a dataset position from the clipboard to the position input box, you can simply paste it without focusing the position input first.

24-29: Streamline ‘Added’ section bullet prefixes.
Since the section heading already denotes new features, consider removing the redundant “Added” keyword at the start of each bullet for brevity.


45-59: Unify phrasing in Fixed section bullets.
Some bullets start directly with descriptions while others include “Fixed that…”. To leverage the “Fixed” heading and improve readability, remove “Fixed that” prefixes across these bullets.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 41d8490 and dc22602.

📒 Files selected for processing (16)
  • CHANGELOG.released.md (1 hunks)
  • CHANGELOG.unreleased.md (1 hunks)
  • MIGRATIONS.released.md (1 hunks)
  • MIGRATIONS.unreleased.md (1 hunks)
  • frontend/javascripts/test/fixtures/hybridtracing_object.ts (2 hunks)
  • frontend/javascripts/test/reducers/skeletontracing_reducer.spec.ts (2 hunks)
  • frontend/javascripts/viewer/model/accessors/disabled_tool_accessor.ts (1 hunks)
  • frontend/javascripts/viewer/model/actions/settings_actions.ts (1 hunks)
  • frontend/javascripts/viewer/model/reducers/reducer_helpers.ts (5 hunks)
  • frontend/javascripts/viewer/model/reducers/skeletontracing_reducer_helpers.ts (2 hunks)
  • frontend/javascripts/viewer/model/reducers/ui_reducer.ts (1 hunks)
  • frontend/javascripts/viewer/model/sagas/settings_saga.ts (3 hunks)
  • frontend/javascripts/viewer/view/action_bar_view.tsx (2 hunks)
  • frontend/javascripts/viewer/view/right-border-tabs/segments_tab/segment_list_item.tsx (2 hunks)
  • webknossos-tracingstore/app/com/scalableminds/webknossos/tracingstore/controllers/TSAnnotationController.scala (1 hunks)
  • webknossos-tracingstore/app/com/scalableminds/webknossos/tracingstore/tracings/volume/VolumeTracingService.scala (1 hunks)
🧰 Additional context used
🧬 Code Graph Analysis (8)
frontend/javascripts/test/fixtures/hybridtracing_object.ts (1)
frontend/javascripts/viewer/model/types/tree_types.ts (1)
  • Tree (61-75)
frontend/javascripts/viewer/model/reducers/ui_reducer.ts (1)
frontend/javascripts/viewer/model/reducers/reducer_helpers.ts (1)
  • setToolReducer (188-201)
frontend/javascripts/viewer/view/right-border-tabs/segments_tab/segment_list_item.tsx (1)
frontend/javascripts/components/fast_tooltip.tsx (1)
  • FastTooltip (54-123)
frontend/javascripts/test/reducers/skeletontracing_reducer.spec.ts (2)
frontend/javascripts/test/fixtures/hybridtracing_object.ts (2)
  • initialState (88-101)
  • initialTreeOne (33-47)
frontend/javascripts/viewer/model/types/tree_types.ts (1)
  • MutableTreeMap (93-93)
frontend/javascripts/viewer/view/action_bar_view.tsx (1)
frontend/javascripts/libs/react_hooks.ts (1)
  • useWkSelector (292-294)
frontend/javascripts/viewer/model/reducers/skeletontracing_reducer_helpers.ts (1)
frontend/javascripts/viewer/model/types/tree_types.ts (1)
  • MutableTreeMap (93-93)
frontend/javascripts/viewer/model/sagas/settings_saga.ts (1)
frontend/javascripts/viewer/model/actions/settings_actions.ts (2)
  • updateUserSettingAction (55-63)
  • SetViewModeAction (19-19)
frontend/javascripts/viewer/model/reducers/reducer_helpers.ts (2)
frontend/javascripts/viewer/store.ts (1)
  • WebknossosState (559-579)
frontend/javascripts/viewer/model/accessors/disabled_tool_accessor.ts (2)
  • DisabledInfo (25-28)
  • getDisabledInfoForTools (379-381)
🪛 markdownlint-cli2 (0.17.2)
MIGRATIONS.released.md

12-12: Trailing punctuation in heading
Punctuation: ':'

(MD026, no-trailing-punctuation)


18-18: Trailing punctuation in heading
Punctuation: ':'

(MD026, no-trailing-punctuation)

🔇 Additional comments (30)
webknossos-tracingstore/app/com/scalableminds/webknossos/tracingstore/tracings/volume/VolumeTracingService.scala (1)

851-852: Excellent improvement to code clarity!

Adding explicit parameter names to the VolumeSegmentIndexBuffer constructor makes the code more self-documenting and reduces the risk of parameter confusion, especially with multiple boolean parameters. This enhances readability without altering the underlying logic.

webknossos-tracingstore/app/com/scalableminds/webknossos/tracingstore/controllers/TSAnnotationController.scala (1)

189-189: Good addition of error handling!

Adding the specific error message "mergeVolumeData.failed" provides better debugging information when volume data merging operations fail. This enhances the robustness of the error handling in the Fox monadic context.

frontend/javascripts/test/fixtures/hybridtracing_object.ts (2)

33-33: Good fix for typo and export visibility!

Correcting the spelling from initalTreeOne to initialTreeOne and making it exportable improves code quality and enables reuse of this test fixture in other test files.


70-70: Consistent use of corrected variable name.

The reference has been properly updated to use the corrected initialTreeOne name, maintaining consistency with the fixed export.

MIGRATIONS.unreleased.md (1)

9-9: Proper documentation update for release version.

Updating the commit comparison link to track changes from 25.06.1 correctly aligns the unreleased migrations documentation with the new release baseline.

CHANGELOG.unreleased.md (1)

11-11: LGTM! Changelog comparison base correctly updated for release.

The comparison base has been appropriately updated from 25.05.1 to 25.06.1, which aligns with the release workflow.

frontend/javascripts/viewer/model/actions/settings_actions.ts (1)

19-19: LGTM! Type export improves accessibility and consistency.

Exporting SetViewModeAction enhances type sharing across the viewer model and supports better type safety in action handling.

frontend/javascripts/viewer/model/accessors/disabled_tool_accessor.ts (1)

25-28: LGTM! Type export supports better code organization.

Making DisabledInfo explicitly exported enables its use in other modules and supports the broader refactoring for improved type sharing across the viewer model.

frontend/javascripts/viewer/model/reducers/ui_reducer.ts (1)

69-71: LGTM! Good simplification of tool setting logic.

The removal of redundant conditional checks for allowUpdate and read-only tools is appropriate since setToolReducer already handles tool availability validation through isToolAvailable. This centralizes the logic and makes the reducer cleaner.

frontend/javascripts/viewer/model/reducers/skeletontracing_reducer_helpers.ts (2)

598-599: Excellent improvement preventing input mutation.

Creating a new MutableTreeMap instead of mutating the original trees map during iteration is a great practice. This prevents potential issues with concurrent modification and makes the function behavior more predictable.


634-638: Proper completion of the immutable pattern.

The function now correctly returns the new newTrees map instead of the potentially mutated input, maintaining immutability principles throughout the function.

frontend/javascripts/viewer/view/action_bar_view.tsx (2)

196-199: Good addition of granular state selectors.

The new isReadOnly and isOrthoMode selectors provide the necessary state information for implementing more precise toolkit visibility logic.


208-208: Enhanced toolkit visibility logic looks correct.

The updated condition !isViewMode && !isReadOnly && isOrthoMode properly restricts the <ToolkitView /> to scenarios where:

  • User is not in view mode
  • User has update permissions
  • View mode is orthogonal

This aligns well with the centralized tool availability improvements mentioned in the AI summary.

frontend/javascripts/viewer/view/right-border-tabs/segments_tab/segment_list_item.tsx (2)

376-384: Nice component extraction for better code organization.

The new SegmentIdAddendum component properly encapsulates the segment ID rendering logic with consistent tooltip and styling. This makes the code more modular and reusable.


641-642: Rendering logic correctly preserved.

The conditional rendering {segment.name != null ? <SegmentIdAddendum id={segment.id} /> : null} maintains the same behavior as before - only showing the segment ID when the segment has a name. The updated comment clearly explains this logic.

frontend/javascripts/test/reducers/skeletontracing_reducer.spec.ts (4)

12-12: LGTM: Import of test fixture.

The import of initialTreeOne from the test fixtures is appropriate for the new test cases.


18-24: LGTM: Additional type imports for new test functionality.

The imports of MutableTreeMap and other tree-related types are necessary for the new test cases that test the addTreesAndGroupsAction behavior.


1795-1818: Well-structured test for tree addition without ID relabeling.

This test properly verifies that when adding a tree to an empty skeleton (after deleting existing trees), the original tree ID is preserved. The test correctly:

  • Sets up the initial state by deleting existing trees
  • Uses a callback to capture the assigned tree IDs
  • Verifies that the original ID (4) is preserved
  • Checks the final state expectations

1820-1839: Excellent test for tree ID relabeling behavior.

This test effectively validates the ID relabeling logic when adding a tree with a very large ID (8,000,000) to a non-empty skeleton. The test properly:

  • Uses a callback to capture the relabeled tree ID
  • Verifies that the large ID is replaced with the next available ID (3)
  • Confirms the tree exists with the new ID and not with the original large ID
  • Validates the tree count increases correctly
frontend/javascripts/viewer/model/sagas/settings_saga.ts (4)

5-11: LGTM: Necessary imports for new saga functionality.

The additional imports (all, call, put, takeEvery, ControlModeEnum, SetViewModeAction, updateUserSettingAction) are all used appropriately in the new ensureValidToolkit function.


18-19: LGTM: Additional imports for toolkit and readiness management.

The imports of Toolkit and ensureWkReady are properly used in the new saga functionality.


118-137: Well-implemented toolkit validation saga.

The ensureValidToolkit function properly handles the business logic for enforcing the default toolkit setting. The implementation correctly:

  • Waits for system readiness before proceeding
  • Checks both view mode and read-only status conditions
  • Sets the toolkit to ALL_TOOLS when appropriate
  • Listens for view mode changes and reacts to non-orthogonal modes
  • Uses proper saga effects (call, put, select, takeEvery)

The logic aligns well with the UI changes mentioned in the AI summary where the toolkit view is conditionally rendered.


154-154: Proper integration of new saga into root watcher.

The ensureValidToolkit saga is correctly added to the all array in the root watcher, ensuring it runs alongside other existing watchers.

frontend/javascripts/viewer/model/reducers/reducer_helpers.ts (4)

10-10: LGTM: Necessary type imports for new helper function.

The imports of AnnotationTool, AnnotationToolId, and DisabledInfo are properly used in the new isToolAvailable function signature and implementation.

Also applies to: 15-15


133-146: Excellent consolidation of tool availability logic.

The isToolAvailable helper function effectively centralizes the logic for determining tool availability. The implementation correctly:

  • Takes the necessary parameters: state, disabled tool info, and tool
  • Checks if the tool is disabled first
  • Handles read-only mode by checking against READ_ONLY_TOOLS
  • Returns appropriate boolean values
  • Has a clear, well-documented purpose

This consolidation improves maintainability by removing duplicated logic from multiple functions.


161-161: LGTM: Consistent usage of new helper function.

The replacement of previous direct checks with the new isToolAvailable helper function in both getNextTool and getPreviousTool functions improves code consistency and maintainability.

Also applies to: 181-181


193-194: Improved tool validation in setToolReducer.

The usage of isToolAvailable in setToolReducer replaces what appears to have been more complex logic, simplifying the function while maintaining the same validation behavior.

CHANGELOG.released.md (3)

10-12: Changelog header formatting is consistent.
Version header and commit link follow the established pattern and date format.


16-17: Version 25.06.0 header is correctly formatted.
The commit comparison range aligns with the intended previous release (25.05.1…25.06.0).


60-62: Removed section looks correct.
The entry clearly describes the deprecated feature and its replacement.

- Added the possibility for super users to retry manually cancelled jobs from the jobs list. [#8629](https://github.com/scalableminds/webknossos/pull/8629)

### Changed
- Remove `data.maybe` dependency and replaced with regular Typescript types. [#8563](https://github.com/scalableminds/webknossos/pull/8563)
Copy link
Contributor

Choose a reason for hiding this comment

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

🛠️ Refactor suggestion

Fix inconsistent verb tense in Changed section.
The first bullet mixes present (“Remove”) and past (“replaced”) tense. It should be uniform.

Apply this diff:

- Remove `data.maybe` dependency and replaced with regular Typescript types. [#8563]
+ Removed `data.maybe` dependency and replaced it with regular TypeScript types. [#8563]

Committable suggestion skipped: line range outside the PR's diff.

🤖 Prompt for AI Agents
In CHANGELOG.released.md at line 31, the bullet point uses inconsistent verb
tenses "Remove" and "replaced." Change "Remove" to "Removed" to match the past
tense used in "replaced," making the verb tense uniform throughout the sentence.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
CHANGELOG.released.md (1)

31-31: Correct TypeScript casing
The word “Typescript” should follow the official “TypeScript” capitalization in both bullets:

- Removed `data.maybe` dependency and replaced with regular Typescript types. [#8563]
+ Removed `data.maybe` dependency and replaced with regular TypeScript types. [#8563]

- Updated to Typescript from version `5.5` to `5.8`. [#8613]
+ Updated to TypeScript from version `5.5` to `5.8`. [#8613]

Also applies to: 39-39

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between dc22602 and cdfa6cf.

📒 Files selected for processing (1)
  • CHANGELOG.released.md (1 hunks)
🔇 Additional comments (2)
CHANGELOG.released.md (2)

10-15: Validate 25.06.1 release entry
The new 25.06.1 heading, date, commit link, and “Fixed” section align with project conventions and accurately reflect the patch fix.


16-29: Validate 25.06.0 release entry
The 25.06.0 “Highlights” and “Added” sections comprehensively document features and improvements. The links, formatting, and section structure match existing releases.

@philippotto philippotto merged commit cf115fd into master Jun 3, 2025
5 checks passed
@philippotto philippotto deleted the prepare-release-25.06.1 branch June 3, 2025 09:44
@coderabbitai coderabbitai bot mentioned this pull request Jun 17, 2025
2 tasks
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.

3 participants