Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix: fix script timings spam in the workspace UI#17590

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
BrunoQuaresma merged 1 commit intomainfrombq/fix-timings-spam
Apr 28, 2025
Merged
Changes fromall commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletionssite/src/pages/WorkspacePage/WorkspaceReadyPage.tsx
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -166,13 +166,15 @@ export const WorkspaceReadyPage: FC<WorkspaceReadyPageProps> = ({
// Sometimes, the timings can be fetched before the agent script timings are
// done or saved in the database so we need to conditionally refetch the
// timings. To refetch the timings, I found the best way was to compare the
// expected amount of script timingswith the current amount of script
// timings returned in the response.
// expected amount of script timingsthat run on start, with the current
//amount of scripttimings returned in the response.
refetchInterval: (data) => {
const expectedScriptTimingsCount = workspace.latest_build.resources
.flatMap((r) => r.agents)
.flatMap((a) => a?.scripts ?? []).length;
.flatMap((a) => a?.scripts ?? [])
.filter((script) => script.run_on_start).length;
const currentScriptTimingsCount = data?.agent_script_timings?.length ?? 0;

return expectedScriptTimingsCount === currentScriptTimingsCount
? false
: 1_000;
Expand Down
Loading

[8]ページ先頭

©2009-2025 Movatter.jp