bitfab-cli 0.2.19 → 0.2.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +4 -5
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -7935,7 +7935,8 @@ async function openStudioTo(path14, opts) {
|
|
|
7935
7935
|
if (opts.forceNew) {
|
|
7936
7936
|
clearActiveStudioSession();
|
|
7937
7937
|
}
|
|
7938
|
-
const
|
|
7938
|
+
const active = opts.forceNew ? null : readActiveStudioSession();
|
|
7939
|
+
const existing = opts.sessionId != null && (active?.sessionId !== opts.sessionId || active?.serviceUrl !== opts.serviceUrl) ? null : active;
|
|
7939
7940
|
if (existing) {
|
|
7940
7941
|
const client = {
|
|
7941
7942
|
serviceUrl: existing.serviceUrl,
|
|
@@ -7952,10 +7953,8 @@ async function openStudioTo(path14, opts) {
|
|
|
7952
7953
|
...poller2
|
|
7953
7954
|
};
|
|
7954
7955
|
}
|
|
7955
|
-
if (ack.reason === "session-ended" || ack.reason === "push-failed") {
|
|
7956
|
-
|
|
7957
|
-
clearActiveStudioSession();
|
|
7958
|
-
}
|
|
7956
|
+
if (ack.reason === "session-ended" || ack.reason === "push-failed" || opts.sessionId != null && ack.reason === "timeout") {
|
|
7957
|
+
clearActiveStudioSession();
|
|
7959
7958
|
} else {
|
|
7960
7959
|
throw new StudioNavigationError(ack.reason ?? "unknown", ack.blockedReason, existing.sessionId);
|
|
7961
7960
|
}
|