enso-org / enso

Enso Analytics is a self-service data prep and analysis platform designed for data teams.
https://ensoanalytics.com
Apache License 2.0
7.37k stars 323 forks source link

Race-condition when updating idmap and attaching a visualization #10897

Closed hubertp closed 2 months ago

hubertp commented 2 months ago

Consider a scenario

  1. GUI sends an edit file request, with IdMap containing the id of an expression, say X
  2. GUI sends attach visualization request for X

If visualization request is handled before compilation is triggered, no visualization update will be sent from backend.

hubertp commented 2 months ago

Test demonstrating the problem in https://github.com/enso-org/enso/pull/10898.

sbt> runtime-integration-tests/testOnly *RuntimeVisualizationsTest -- -z "emit visualization update for the target of a method call (subexpression)"

sometimes it works and sometimes it doesn't, demonstrating the said race-condition.

enso-bot[bot] commented 2 months ago

Dmitry Bushev reports a new STANDUP for today (2024-08-30):

Progress: [10897] Implemented the fix for the case when there are pending program executions after the EditFileCmd is processed. After reproducing the issue on 10898 branch, found that the actual issue is caused by the fact that UpsertVisualizationJob relies on the fact that the program should be compiled at the moment. Working on the fix It should be finished by 2024-09-06.

Next Day: Next day I will be working on the #10897 task. Continue working on the task

enso-bot[bot] commented 2 months ago

Dmitry Bushev reports a new STANDUP for yesterday (2024-09-02):

Progress: [10897] Implemented the execution hooks. Updated visualization logic to clear caches from the hook. Verified that the change fixes the issue on the branch with the reproducer It should be finished by 2024-09-06.

Next Day: Next day I will be working on the #10897 task. Continue working on the task