Repository navigation
fix(measure): read explicit nodes concurrently and let the bridge fall back when Figma cannot load them - #114
Draft
devfive-relay-c70423[bot] wants to merge 1 commit into
Conversation
…l back when Figma cannot load them Figma answers reads of nodes it has not loaded (file out of view) with 'Unable to establish connection to Figma' after 10s each. measure_nodes.js read IDs one by one and relabelled that error read-failed, so two unloaded nodes exceeded the 15s measure limit and the bridge never re-read through the direct path. - measure_nodes.js: read IDs with Promise.all; tag connection failures figma-unreachable with a bounded error text - measurement.rs: pass through only fixed reason labels, hint for figma-unreachable, timeout aligned with READ_TIME_LIMIT, timeout error carries inView/pluginBuild/nextAction - regenerate plugin scripts bundle, PLUGIN_SCRIPTS_HASH and plugin dist
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
devup_figma_measuretimed out on instance-descendant IDs (e.g.I89:6466;89:6479) when the Figma file was out of view.Unable to establish connection to Figmaafter ~10s each.measure_nodes.jsread IDs one by one, so two such nodes took ~20s and exceeded the 15s measure limit.read-failed, so the bridge never recognised it and never re-read through the direct (OAuth) path.Changes
measure_nodes.js: read IDs concurrently withPromise.all; tag connection failuresreason: "figma-unreachable"with error text capped at 240 chars.measurement.rs:not-found,not-scene-node,read-failed,figma-unreachable); anything else becomesnode-read-unavailable.figma-unreachablegets a remediation hint.READ_TIME_LIMITso a direct-path re-read can finish.inView,pluginBuild,limitSecondsandnextAction.PLUGIN_SCRIPTS_HASHandplugin/dist.Verification
cargo test -p devup-mcp --lib measurement(4 passed, including newunavailable_reasons_keep_only_fixed_labels),cargo test -p devup-mcp-figma --lib plugin_scripts,cargo test -p devup-mcp --test bridge_first(18 passed)cargo clippy -p devup-mcp -p devup-mcp-figma --all-targets -- -D warnings,cargo fmt --all -- --checkinView: true): all 7measuredthrough the bridge in one read.inView: false): all 7measured, served bysource.kind: "direct"after the bridge fallback. Before this change the same call timed out.Not verified
3b37389, before plugin script identity), soscriptsHashcould not be confirmed to be the new one at runtime.Submitted via Devfive hub. Employee: ; device:
3099154426bffbeef8b62999b80bb038