@iflyrpa/playwright 4.0.9-beta.2 → 4.0.9-beta.4

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.d.ts CHANGED
@@ -142,6 +142,13 @@ export declare class RpaTask extends Task {
142
142
  private updateTask;
143
143
  constructor(params: TaskParams);
144
144
  private registerActions;
145
+ /**
146
+ * 获取当前运行的脚本包(@iflyrpa/actions)版本号
147
+ *
148
+ * 返回内存中实际生效的版本,热更新后会自动切换到新版本。
149
+ * 适用于在脚本执行过程中记录或上报实际使用的脚本版本。
150
+ */
151
+ getActionVersion(): string;
145
152
  /**
146
153
  * 脚本包版本状态快照(同步,不发起网络请求)
147
154
  *
@@ -170,6 +177,23 @@ export declare class RpaTask extends Task {
170
177
  */
171
178
  waitForActionUpdate(): Promise<ActionVersionInfo>;
172
179
  private update;
180
+ /**
181
+ * 【测试专用】验证脚本是否真的在内存中更新了
182
+ *
183
+ * 通过调用 actions 实例的版本标识方法,验证热更新后内存中的代码是否真的被替换。
184
+ * 如果版本标识变化,说明热更新成功;如果标识不变,说明仍在使用旧版本。
185
+ *
186
+ * @returns 当前内存中 Action 实例的版本标识
187
+ */
188
+ verifyActionMemoryUpdate(): {
189
+ version: string;
190
+ shareVersion: string;
191
+ marker: string;
192
+ timestamp: string;
193
+ } | {
194
+ error: string;
195
+ currentVersion: string;
196
+ };
173
197
  }
174
198
 
175
199
  declare class SentryInstance {
package/dist/index.js CHANGED
@@ -1,3 +1,5 @@
1
+
2
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="92f20852-4bf4-5fbf-bdb2-412040c14232")}catch(e){}}();
1
3
  import * as __WEBPACK_EXTERNAL_MODULE_punycode__ from "punycode";
2
4
  import * as __WEBPACK_EXTERNAL_MODULE_stream__ from "stream";
3
5
  import * as __WEBPACK_EXTERNAL_MODULE_http__ from "http";
@@ -2550,7 +2552,7 @@ function __webpack_require__(moduleId) {
2550
2552
  });
2551
2553
  };
2552
2554
  })();
2553
- var package_namespaceObject = JSON.parse('{"i8":"4.0.9-beta.2"}');
2555
+ var package_namespaceObject = JSON.parse('{"i8":"4.0.9-beta.4"}');
2554
2556
  function _define_property(obj, key, value) {
2555
2557
  if (key in obj) Object.defineProperty(obj, key, {
2556
2558
  value: value,
@@ -5662,7 +5664,7 @@ class Task {
5662
5664
  this.electronPackage = this.installElectron();
5663
5665
  }
5664
5666
  }
5665
- var version_history_namespaceObject = JSON.parse('{"name":"@iflyrpa/playwright","currentVersion":"4.0.9-beta.2","lastUpdate":"2026-08-13","maxVersions":10,"versions":[{"version":"4.0.9-beta.2","releaseDate":"2026-08-13","releaseNote":["1.增加版本更新记录","2.优化错误提示"],"updateLevel":1,"updateStrategy":"建议更新","changeType":"patch"},{"version":"4.0.9-beta.1","releaseDate":"2024-08-10","releaseNote":["改进多个 action 的用户错误提示信息"],"updateLevel":1,"updateStrategy":"建议更新","changeType":"patch"}]}');
5667
+ var version_history_namespaceObject = JSON.parse('{"name":"@iflyrpa/playwright","currentVersion":"4.0.9-beta.4","lastUpdate":"2026-08-14","maxVersions":10,"versions":[{"version":"4.0.9-beta.4","releaseDate":"2026-08-14","releaseNote":["1. 版本更新优化"],"updateLevel":0,"updateStrategy":"可选更新","changeType":"patch"},{"version":"4.0.9-beta.3","releaseDate":"2026-08-14","releaseNote":["1. 测试更新","2. 重要修复,需要更新"],"updateLevel":2,"updateStrategy":"强制更新并重启","changeType":"patch"},{"version":"4.0.9-beta.2","releaseDate":"2026-08-13","releaseNote":["1.增加版本更新记录","2.优化错误提示"],"updateLevel":1,"updateStrategy":"建议更新","changeType":"patch"}]}');
5666
5668
  function getVersionHistory() {
5667
5669
  return version_history_namespaceObject;
5668
5670
  }
@@ -5697,6 +5699,9 @@ class RpaTask extends Task {
5697
5699
  this.currentActionVersion = rpaAction.version;
5698
5700
  this.setActionVersion(rpaAction.version);
5699
5701
  }
5702
+ getActionVersion() {
5703
+ return this.currentActionVersion;
5704
+ }
5700
5705
  getActionVersionInfo() {
5701
5706
  return {
5702
5707
  current: this.currentActionVersion,
@@ -5753,6 +5758,14 @@ class RpaTask extends Task {
5753
5758
  }
5754
5759
  return this.getActionVersionInfo();
5755
5760
  }
5761
+ verifyActionMemoryUpdate() {
5762
+ var _this_actions;
5763
+ if (!(null === (_this_actions = this.actions) || void 0 === _this_actions ? void 0 : _this_actions.getActionVersionMarker)) return {
5764
+ error: "getActionVersionMarker 方法不存在,可能是旧版本的 @iflyrpa/actions",
5765
+ currentVersion: this.currentActionVersion
5766
+ };
5767
+ return this.actions.getActionVersionMarker();
5768
+ }
5756
5769
  constructor(params){
5757
5770
  super(params), src_define_property(this, "actions", void 0), src_define_property(this, "actionName", "@iflyrpa/actions"), src_define_property(this, "bundledActionVersion", __WEBPACK_EXTERNAL_MODULE__iflyrpa_actions_bd801d6f__.version), src_define_property(this, "currentActionVersion", __WEBPACK_EXTERNAL_MODULE__iflyrpa_actions_bd801d6f__.version), src_define_property(this, "latestActionVersion", null), src_define_property(this, "appliedUpdate", false), src_define_property(this, "updateChannel", "latest"), src_define_property(this, "updateError", void 0), src_define_property(this, "updateTask", null);
5758
5771
  this.registerActions(__WEBPACK_EXTERNAL_MODULE__iflyrpa_actions_bd801d6f__);
@@ -5762,4 +5775,5 @@ class RpaTask extends Task {
5762
5775
  const src_version = package_namespaceObject.i8;
5763
5776
  export { RpaTask, compareVersion, getLatestVersionRecord, getMaxUpdateLevel, getVersionHistory, getVersionRecord, getVersionRecordsSince, src_version as version };
5764
5777
 
5765
- //# sourceMappingURL=index.js.map
5778
+ //# sourceMappingURL=index.js.map
5779
+ //# debugId=92f20852-4bf4-5fbf-bdb2-412040c14232