Skip to content

fix(hub): logs are not streamed when opening newly created actor #2015

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

Conversation

jog1t
Copy link
Contributor

@jog1t jog1t commented Feb 11, 2025

Closes FRONT-620

Changes

Copy link

cloudflare-workers-and-pages bot commented Feb 11, 2025

Deploying rivet-hub with  Cloudflare Pages  Cloudflare Pages

Latest commit: 0640508
Status: ✅  Deploy successful!
Preview URL: https://90b8bddb.rivet-hub-7jb.pages.dev
Branch Preview URL: https://graphite-base-2016.rivet-hub-7jb.pages.dev

View logs

Copy link
Contributor Author

jog1t commented Feb 11, 2025

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more


How to use the Graphite Merge Queue

Add the label merge-queue to this PR to add it to the merge queue.

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@jog1t jog1t marked this pull request as ready for review February 11, 2025 21:43
Copy link

linear bot commented Feb 11, 2025

Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

This PR modifies the watch query mechanism in the Hub application, focusing on log streaming functionality for newly created actors.

  • Added redundant await query.promise in /frontend/apps/hub/src/queries/watch.ts that could cause infinite loops by repeatedly awaiting the same promise
  • Potential race condition in watch loop where query state isn't properly updated between iterations
  • Missing mechanism to refresh/update the promise reference between watch loop iterations
  • Watch query state checking logic may prevent proper streaming initialization for new actors

The changes introduce potential performance and reliability issues in the actor log streaming implementation that should be addressed before merging.

1 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings | Greptile

Copy link

cloudflare-workers-and-pages bot commented Feb 11, 2025

Deploying rivet with  Cloudflare Pages  Cloudflare Pages

Latest commit: 0640508
Status: ✅  Deploy successful!
Preview URL: https://43968e04.rivet.pages.dev
Branch Preview URL: https://graphite-base-2016.rivet.pages.dev

View logs

@jog1t jog1t force-pushed the 02-11-fix_hub_logs_are_not_streamed_when_opening_newly_created_actor branch from f9b1104 to 0640508 Compare February 17, 2025 17:35
@jog1t jog1t force-pushed the 02-11-fix_hub_prevent_long_lines_to_break_the_layout branch from 82134dc to 63ec0e4 Compare February 17, 2025 17:35
@jog1t jog1t changed the base branch from 02-11-fix_hub_prevent_long_lines_to_break_the_layout to graphite-base/2015 February 17, 2025 17:36
Copy link
Contributor

graphite-app bot commented Feb 17, 2025

Merge activity

  • Feb 17, 3:59 PM EST: A user added this pull request to the Graphite merge queue.
  • Feb 17, 3:59 PM EST: CI is running for this PR on a draft PR: #2038
  • Feb 17, 4:00 PM EST: A user merged this pull request with the Graphite merge queue via draft PR: #2038.

graphite-app bot pushed a commit that referenced this pull request Feb 17, 2025
<!-- Please make sure there is an issue that this PR is correlated to. -->
Closes FRONT-620

## Changes

<!-- If there are frontend changes, please include screenshots. -->
@graphite-app graphite-app bot closed this Feb 17, 2025
@graphite-app graphite-app bot deleted the 02-11-fix_hub_logs_are_not_streamed_when_opening_newly_created_actor branch February 17, 2025 21:00
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.

1 participant