Skip to content

Conversation

@bmartel
Copy link
Contributor

@bmartel bmartel commented Sep 13, 2024

PR fulfills these requirements

  • Commit message(s) and PR title follows the format [fix|feat|ci|chore|doc]: TICKET-ID: Short description of change made ex. fix: DEV-XXXX: Removed inconsistent code usage causing intermittent errors
  • Tests for the changes have been added/updated (for bug fixes/features)
  • Docs have been added/updated (for bug fixes/features)
  • Best efforts were made to ensure docs/code are concise and coherent (checked for spelling/grammatical errors, commented out code, debug logs etc.)
  • Self-reviewed and ran all changes on a local instance (for bug fixes/features)

Change has impacts in these area(s)

(check all that apply)

  • Product design
  • Backend (Database)
  • Frontend

Describe the reason for change

When changing values in the Labelling Config via the live editor, the correct lifecycle methods were not firing on update and there would be a missed step to clear out shared stores on the current instance. It would then proceed to try and create another AnnotationStore again, and end up with a case where the shared store had a reference in the module scoped Stores and StoreIds Map(s), but the local instance of the mobx model did not, and would try to re-register the exact copy once again which was failing. Once failed, this error would propagate across navigations to the next time a task would attempt to be loaded and would fail to load a task with a Taxonomy tag, only clearing up on a refresh of the browser.

Which logical domain(s) does this change affect?

Config Preview, Taxonomy


🚀 This description was created by Ellipsis for commit 0ae42ce

fix: OPTIC-1087: Correct Label Studio lifecycle in Config Preview

Summary:

Fixes lifecycle handling of Label Studio in Preview.jsx to prevent errors in the live editor.

Key points:

  • Fix: Correct lifecycle handling of Label Studio in Preview.jsx.
  • Behavior: Moved cleanup logic to a separate useEffect with an empty dependency array.
  • Prevents Errors: Ensures proper destruction of Label Studio instance on component unmount.
  • Frontend Impact: Affects live editor functionality in Config Preview.
  • Issue: Prevents errors related to shared stores and task loading.

Generated with ❤️ by ellipsis.dev

@github-actions github-actions bot added the fix label Sep 13, 2024
@netlify
Copy link

netlify bot commented Sep 13, 2024

Deploy Preview for label-studio-docs-new-theme canceled.

Name Link
🔨 Latest commit 59cc4cf
🔍 Latest deploy log https://app.netlify.com/sites/label-studio-docs-new-theme/deploys/66e49f73994b0a00082f746c

@netlify
Copy link

netlify bot commented Sep 13, 2024

Deploy Preview for heartex-docs canceled.

Name Link
🔨 Latest commit 59cc4cf
🔍 Latest deploy log https://app.netlify.com/sites/heartex-docs/deploys/66e49f7382fa390008facb4a

Copy link

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

3 days left in your free trial, upgrade for $20/seat/month or contact us.

@bmartel
Copy link
Contributor Author

bmartel commented Sep 13, 2024

@ellipsis-dev review this

Copy link

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

❌ Changes requested. Reviewed everything up to 0ae42ce in 28 seconds

More details
  • Looked at 78 lines of code in 1 files
  • Skipped 0 files when reviewing.
  • Skipped posting 0 drafted comments based on config settings.

Workflow ID: wflow_aHA3Ow9TwsZcmzC6


Want Ellipsis to fix these issues? Tag @ellipsis-dev in a comment. You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

3 days left in your free trial, upgrade for $20/seat/month or contact us.

@bmartel bmartel merged commit d3f251b into develop Sep 18, 2024
33 checks passed
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.

4 participants