@skyvern/client 1.0.6 → 1.0.10
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/cjs/Client.js +2 -2
- package/dist/cjs/library/Skyvern.js +5 -4
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/Client.mjs +2 -2
- package/dist/esm/library/Skyvern.mjs +5 -4
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
package/dist/cjs/Client.js
CHANGED
|
@@ -56,8 +56,8 @@ class SkyvernClient {
|
|
|
56
56
|
"x-api-key": _options === null || _options === void 0 ? void 0 : _options.apiKey,
|
|
57
57
|
"X-Fern-Language": "JavaScript",
|
|
58
58
|
"X-Fern-SDK-Name": "@skyvern/client",
|
|
59
|
-
"X-Fern-SDK-Version": "1.0.
|
|
60
|
-
"User-Agent": "@skyvern/client/1.0.
|
|
59
|
+
"X-Fern-SDK-Version": "1.0.10",
|
|
60
|
+
"User-Agent": "@skyvern/client/1.0.10",
|
|
61
61
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
62
62
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
63
63
|
}, _options === null || _options === void 0 ? void 0 : _options.headers) });
|
|
@@ -231,12 +231,13 @@ class Skyvern extends Client_js_1.SkyvernClient {
|
|
|
231
231
|
this._ensureCloudEnvironment();
|
|
232
232
|
const browserSessions = yield this.getBrowserSessions();
|
|
233
233
|
const browserSession = browserSessions
|
|
234
|
-
.filter((s) => s.runnable_id == null)
|
|
234
|
+
.filter((s) => s.runnable_id == null && s.started_at != null && s.browser_address != null)
|
|
235
235
|
.sort((a, b) => {
|
|
236
|
-
const aTime =
|
|
237
|
-
const bTime =
|
|
236
|
+
const aTime = new Date(a.started_at).getTime();
|
|
237
|
+
const bTime = new Date(b.started_at).getTime();
|
|
238
238
|
return bTime - aTime;
|
|
239
|
-
})
|
|
239
|
+
})
|
|
240
|
+
.at(0);
|
|
240
241
|
if (!browserSession) {
|
|
241
242
|
logger_js_1.LOG.info("No existing cloud browser session found, launching a new session");
|
|
242
243
|
return this.launchCloudBrowser(options);
|
package/dist/cjs/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "1.0.
|
|
1
|
+
export declare const SDK_VERSION = "1.0.10";
|
package/dist/cjs/version.js
CHANGED
package/dist/esm/Client.mjs
CHANGED
|
@@ -20,8 +20,8 @@ export class SkyvernClient {
|
|
|
20
20
|
"x-api-key": _options === null || _options === void 0 ? void 0 : _options.apiKey,
|
|
21
21
|
"X-Fern-Language": "JavaScript",
|
|
22
22
|
"X-Fern-SDK-Name": "@skyvern/client",
|
|
23
|
-
"X-Fern-SDK-Version": "1.0.
|
|
24
|
-
"User-Agent": "@skyvern/client/1.0.
|
|
23
|
+
"X-Fern-SDK-Version": "1.0.10",
|
|
24
|
+
"User-Agent": "@skyvern/client/1.0.10",
|
|
25
25
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
26
26
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
27
27
|
}, _options === null || _options === void 0 ? void 0 : _options.headers) });
|
|
@@ -195,12 +195,13 @@ export class Skyvern extends SkyvernClient {
|
|
|
195
195
|
this._ensureCloudEnvironment();
|
|
196
196
|
const browserSessions = yield this.getBrowserSessions();
|
|
197
197
|
const browserSession = browserSessions
|
|
198
|
-
.filter((s) => s.runnable_id == null)
|
|
198
|
+
.filter((s) => s.runnable_id == null && s.started_at != null && s.browser_address != null)
|
|
199
199
|
.sort((a, b) => {
|
|
200
|
-
const aTime =
|
|
201
|
-
const bTime =
|
|
200
|
+
const aTime = new Date(a.started_at).getTime();
|
|
201
|
+
const bTime = new Date(b.started_at).getTime();
|
|
202
202
|
return bTime - aTime;
|
|
203
|
-
})
|
|
203
|
+
})
|
|
204
|
+
.at(0);
|
|
204
205
|
if (!browserSession) {
|
|
205
206
|
LOG.info("No existing cloud browser session found, launching a new session");
|
|
206
207
|
return this.launchCloudBrowser(options);
|
package/dist/esm/version.d.mts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "1.0.
|
|
1
|
+
export declare const SDK_VERSION = "1.0.10";
|
package/dist/esm/version.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const SDK_VERSION = "1.0.
|
|
1
|
+
export const SDK_VERSION = "1.0.10";
|