wao 0.36.3 → 0.36.6
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/cjs/adaptor-base.js +17 -17
- package/cjs/ao.js +2 -2
- package/cjs/aoconnect-base.js +278 -195
- package/cjs/bar.js +16 -11
- package/cjs/bundler.js +36 -32
- package/cjs/hb.js +364 -337
- package/esm/adaptor-base.js +1 -3
- package/esm/ao.js +2 -2
- package/esm/aoconnect-base.js +31 -3
- package/esm/bar.js +4 -2
- package/esm/bundler.js +67 -65
- package/esm/hb.js +24 -13
- package/package.json +1 -1
package/cjs/aoconnect-base.js
CHANGED
|
@@ -10,7 +10,7 @@ var WarpArBundles = _interopRequireWildcard(require("warp-arbundles"));
|
|
|
10
10
|
var _crypto = _interopRequireDefault(require("crypto"));
|
|
11
11
|
var _base64url = _interopRequireDefault(require("base64url"));
|
|
12
12
|
var _utils = require("./utils.js");
|
|
13
|
-
var
|
|
13
|
+
var _ao2 = _interopRequireDefault(require("./ao.js"));
|
|
14
14
|
var _aoconnect = require("@permaweb/aoconnect");
|
|
15
15
|
var _weavedrive = _interopRequireDefault(require("./weavedrive.js"));
|
|
16
16
|
var _ramda = require("ramda");
|
|
@@ -674,7 +674,7 @@ var _default = exports["default"] = function _default() {
|
|
|
674
674
|
var _assign = /*#__PURE__*/function () {
|
|
675
675
|
var _ref9 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee5(opt) {
|
|
676
676
|
var _opt$tags2;
|
|
677
|
-
var p, _opt, hash, _yield$ar$dataitem2, id, owner, item, _opt$data2, _ref10, _opt$from, _res$Messages, _res$Spawns, _res$Assignments, data, _tags, from, t, msg, _env, _yield$mem$getTx3, _yield$mem$getWasm2, format, mod, wasm, wdrive, start, res, _msg, _iterator3, _step3, _loop, _iterator4, _step4, v, __tags, _iterator5, _step5, _v, _iterator6, _step6, v2;
|
|
677
|
+
var p, _opt, hash, _yield$ar$dataitem2, id, owner, item, _opt$data2, _ref10, _opt$from, _opt$message_item, _res$Messages, _res$Spawns, _res$Assignments, data, _tags, from, t, _owner, msg, _env, _yield$mem$getTx3, _yield$mem$getWasm2, format, mod, wasm, wdrive, start, res, _msg, _iterator3, _step3, _loop, _iterator4, _step4, v, __tags, _iterator5, _step5, _v, _iterator6, _step6, v2;
|
|
678
678
|
return _regeneratorRuntime().wrap(function _callee5$(_context6) {
|
|
679
679
|
while (1) switch (_context6.prev = _context6.next) {
|
|
680
680
|
case 0:
|
|
@@ -777,25 +777,27 @@ var _default = exports["default"] = function _default() {
|
|
|
777
777
|
case 52:
|
|
778
778
|
from = _context6.sent;
|
|
779
779
|
case 53:
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
780
|
+
// check: is owner=mu.addr right?
|
|
781
|
+
_owner = (_opt$message_item = opt.message_item) !== null && _opt$message_item !== void 0 && _opt$message_item.owner ? (0, _utils.toAddr)(opt.message_item.owner) : mu.addr;
|
|
782
|
+
_context6.next = 56;
|
|
783
|
+
return genMsg(opt.message, p, data, _tags, from, _owner);
|
|
784
|
+
case 56:
|
|
783
785
|
msg = _context6.sent;
|
|
784
|
-
_context6.next =
|
|
786
|
+
_context6.next = 59;
|
|
785
787
|
return genEnv({
|
|
786
788
|
pid: p.id,
|
|
787
789
|
owner: p.owner,
|
|
788
790
|
module: p.module
|
|
789
791
|
});
|
|
790
|
-
case
|
|
792
|
+
case 59:
|
|
791
793
|
_env = _context6.sent;
|
|
792
794
|
if (p.handle) {
|
|
793
|
-
_context6.next =
|
|
795
|
+
_context6.next = 92;
|
|
794
796
|
break;
|
|
795
797
|
}
|
|
796
|
-
_context6.next =
|
|
798
|
+
_context6.next = 63;
|
|
797
799
|
return mem.getWasm(p.module);
|
|
798
|
-
case
|
|
800
|
+
case 63:
|
|
799
801
|
_yield$mem$getWasm2 = _context6.sent;
|
|
800
802
|
format = _yield$mem$getWasm2.format;
|
|
801
803
|
mod = _yield$mem$getWasm2.mod;
|
|
@@ -805,31 +807,31 @@ var _default = exports["default"] = function _default() {
|
|
|
805
807
|
_context6.t13 = wasm;
|
|
806
808
|
_context6.t14 = format;
|
|
807
809
|
_context6.t15 = wdrive;
|
|
808
|
-
_context6.next =
|
|
810
|
+
_context6.next = 74;
|
|
809
811
|
return mem.getTx(p.id);
|
|
810
|
-
case
|
|
812
|
+
case 74:
|
|
811
813
|
_context6.t17 = _yield$mem$getTx3 = _context6.sent;
|
|
812
814
|
_context6.t16 = _context6.t17 === null;
|
|
813
815
|
if (_context6.t16) {
|
|
814
|
-
_context6.next =
|
|
816
|
+
_context6.next = 78;
|
|
815
817
|
break;
|
|
816
818
|
}
|
|
817
819
|
_context6.t16 = _yield$mem$getTx3 === void 0;
|
|
818
|
-
case
|
|
820
|
+
case 78:
|
|
819
821
|
if (!_context6.t16) {
|
|
820
|
-
_context6.next =
|
|
822
|
+
_context6.next = 82;
|
|
821
823
|
break;
|
|
822
824
|
}
|
|
823
825
|
_context6.t18 = void 0;
|
|
824
|
-
_context6.next =
|
|
826
|
+
_context6.next = 83;
|
|
825
827
|
break;
|
|
826
|
-
case 81:
|
|
827
|
-
_context6.t18 = _yield$mem$getTx3.item;
|
|
828
828
|
case 82:
|
|
829
|
+
_context6.t18 = _yield$mem$getTx3.item;
|
|
830
|
+
case 83:
|
|
829
831
|
_context6.t19 = _context6.t18;
|
|
830
|
-
_context6.next =
|
|
832
|
+
_context6.next = 86;
|
|
831
833
|
return mem.getTx(mod);
|
|
832
|
-
case
|
|
834
|
+
case 86:
|
|
833
835
|
_context6.t20 = _context6.sent;
|
|
834
836
|
_context6.t21 = {
|
|
835
837
|
format: _context6.t14,
|
|
@@ -837,38 +839,38 @@ var _default = exports["default"] = function _default() {
|
|
|
837
839
|
spawn: _context6.t19,
|
|
838
840
|
module: _context6.t20
|
|
839
841
|
};
|
|
840
|
-
_context6.next =
|
|
842
|
+
_context6.next = 90;
|
|
841
843
|
return (0, _context6.t12)(_context6.t13, _context6.t21);
|
|
842
|
-
case
|
|
844
|
+
case 90:
|
|
843
845
|
p.handle = _context6.sent;
|
|
844
846
|
mem.env[opt.process].handle = p.handle;
|
|
845
|
-
case
|
|
847
|
+
case 92:
|
|
846
848
|
if (p.compressed) {
|
|
847
849
|
start = Date.now();
|
|
848
850
|
p.memory = mem.decompress(p.memory, p.original_size);
|
|
849
851
|
p.compressed = false;
|
|
850
852
|
}
|
|
851
|
-
_context6.next =
|
|
853
|
+
_context6.next = 95;
|
|
852
854
|
return p.handle(p.memory, msg, _env);
|
|
853
|
-
case
|
|
855
|
+
case 95:
|
|
854
856
|
res = _context6.sent;
|
|
855
857
|
p.memory = res.Memory;
|
|
856
858
|
delete res.Memory;
|
|
857
859
|
p.results.push(opt.message);
|
|
858
|
-
_context6.next =
|
|
860
|
+
_context6.next = 101;
|
|
859
861
|
return mem.set(p, "env", opt.process);
|
|
860
|
-
case
|
|
862
|
+
case 101:
|
|
861
863
|
_msg = _objectSpread(_objectSpread({}, (0, _ramda.dissoc)("signer", _opt)), {}, {
|
|
862
864
|
res: res,
|
|
863
865
|
msg: msg
|
|
864
866
|
});
|
|
865
|
-
_context6.next =
|
|
867
|
+
_context6.next = 104;
|
|
866
868
|
return mem.set(_msg, "msgs", opt.message);
|
|
867
|
-
case
|
|
869
|
+
case 104:
|
|
868
870
|
_iterator3 = _createForOfIteratorHelper((_res$Messages = res.Messages) !== null && _res$Messages !== void 0 ? _res$Messages : []);
|
|
869
|
-
_context6.prev =
|
|
871
|
+
_context6.prev = 105;
|
|
870
872
|
_loop = /*#__PURE__*/_regeneratorRuntime().mark(function _loop() {
|
|
871
|
-
var v, _t, _result, slot, fetchHB, info, _connect, request, _tags2, _yield$request, _res2, _data, _yield$fetch$then$Pro, _yield$fetch$then,
|
|
873
|
+
var v, _t, _result, slot, fetchHB, info, _connect, request, _tags2, _yield$request, _res2, _data, sch, tar, ao, _yield$mem$getTx$tags3, _yield$mem$getTx4, _tags3$Action, _v$Data, _tags3, pr, module, _yield$ao$msg, mid, _yield$fetch$then$Pro, _yield$fetch$then, _sch, _tar, procs, _ao, _yield$mem$getTx$tags4, _yield$mem$getTx5, _tags4$Action, _v$Data2, _tags4, _pr, _module2, _yield$_ao$msg, _mid;
|
|
872
874
|
return _regeneratorRuntime().wrap(function _loop$(_context5) {
|
|
873
875
|
while (1) switch (_context5.prev = _context5.next) {
|
|
874
876
|
case 0:
|
|
@@ -891,7 +893,7 @@ var _default = exports["default"] = function _default() {
|
|
|
891
893
|
target: v.Target
|
|
892
894
|
});
|
|
893
895
|
case 6:
|
|
894
|
-
_context5.next =
|
|
896
|
+
_context5.next = 143;
|
|
895
897
|
break;
|
|
896
898
|
case 8:
|
|
897
899
|
_t = (0, _utils.tags)(v.Tags); // this behaviour is different from AOS (temporary hack for remote tests)
|
|
@@ -981,131 +983,212 @@ var _default = exports["default"] = function _default() {
|
|
|
981
983
|
target: opt.process,
|
|
982
984
|
})*/
|
|
983
985
|
}
|
|
984
|
-
_context5.next =
|
|
986
|
+
_context5.next = 143;
|
|
985
987
|
break;
|
|
986
988
|
case 36:
|
|
987
|
-
if (!_t.
|
|
988
|
-
_context5.next =
|
|
989
|
+
if (!_t.__SU__) {
|
|
990
|
+
_context5.next = 78;
|
|
989
991
|
break;
|
|
990
992
|
}
|
|
991
|
-
sch = _t.
|
|
993
|
+
sch = _t.__SU__;
|
|
992
994
|
tar = v.Target;
|
|
995
|
+
/*const procs =
|
|
996
|
+
(await fetch(sch).then(r => r.json()))?.Processes ?? []*/
|
|
993
997
|
_context5.next = 41;
|
|
994
|
-
return
|
|
995
|
-
|
|
996
|
-
});
|
|
998
|
+
return new _ao2["default"]({
|
|
999
|
+
port: sch.split(":").pop() - 2
|
|
1000
|
+
}).init(mu.jwk);
|
|
997
1001
|
case 41:
|
|
998
|
-
|
|
1002
|
+
ao = _context5.sent;
|
|
1003
|
+
_context5.prev = 42;
|
|
1004
|
+
_tags3 = _objectSpread(_objectSpread({}, _t), {}, {
|
|
1005
|
+
"From-Process": opt.process,
|
|
1006
|
+
"Pushed-For": id
|
|
1007
|
+
});
|
|
1008
|
+
_context5.next = 46;
|
|
1009
|
+
return mem.getTx(opt.process);
|
|
1010
|
+
case 46:
|
|
1011
|
+
_context5.t3 = _yield$mem$getTx4 = _context5.sent;
|
|
999
1012
|
_context5.t2 = _context5.t3 === null;
|
|
1000
1013
|
if (_context5.t2) {
|
|
1001
|
-
_context5.next =
|
|
1014
|
+
_context5.next = 50;
|
|
1002
1015
|
break;
|
|
1003
1016
|
}
|
|
1004
|
-
_context5.t2 = _yield$
|
|
1005
|
-
case
|
|
1017
|
+
_context5.t2 = _yield$mem$getTx4 === void 0;
|
|
1018
|
+
case 50:
|
|
1006
1019
|
if (!_context5.t2) {
|
|
1007
|
-
_context5.next =
|
|
1020
|
+
_context5.next = 54;
|
|
1008
1021
|
break;
|
|
1009
1022
|
}
|
|
1010
1023
|
_context5.t4 = void 0;
|
|
1011
|
-
_context5.next =
|
|
1024
|
+
_context5.next = 55;
|
|
1012
1025
|
break;
|
|
1013
|
-
case
|
|
1014
|
-
_context5.t4 = _yield$
|
|
1015
|
-
case
|
|
1016
|
-
_context5.t5 = _yield$
|
|
1026
|
+
case 54:
|
|
1027
|
+
_context5.t4 = _yield$mem$getTx4.tags;
|
|
1028
|
+
case 55:
|
|
1029
|
+
_context5.t5 = _yield$mem$getTx$tags3 = _context5.t4;
|
|
1017
1030
|
_context5.t1 = _context5.t5 !== null;
|
|
1018
1031
|
if (!_context5.t1) {
|
|
1019
|
-
_context5.next =
|
|
1032
|
+
_context5.next = 59;
|
|
1020
1033
|
break;
|
|
1021
1034
|
}
|
|
1022
|
-
_context5.t1 = _yield$
|
|
1023
|
-
case
|
|
1035
|
+
_context5.t1 = _yield$mem$getTx$tags3 !== void 0;
|
|
1036
|
+
case 59:
|
|
1024
1037
|
if (!_context5.t1) {
|
|
1025
|
-
_context5.next =
|
|
1038
|
+
_context5.next = 63;
|
|
1026
1039
|
break;
|
|
1027
1040
|
}
|
|
1028
|
-
_context5.t6 = _yield$
|
|
1029
|
-
_context5.next =
|
|
1041
|
+
_context5.t6 = _yield$mem$getTx$tags3;
|
|
1042
|
+
_context5.next = 64;
|
|
1030
1043
|
break;
|
|
1031
|
-
case
|
|
1044
|
+
case 63:
|
|
1032
1045
|
_context5.t6 = [];
|
|
1033
|
-
case
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1046
|
+
case 64:
|
|
1047
|
+
pr = _context5.t6;
|
|
1048
|
+
module = (0, _utils.tags)(pr).Module;
|
|
1049
|
+
if (module) _tags3["From-Module"] = module;
|
|
1050
|
+
_context5.next = 69;
|
|
1051
|
+
return ao.msg({
|
|
1052
|
+
act: (_tags3$Action = _tags3["Action"]) !== null && _tags3$Action !== void 0 ? _tags3$Action : null,
|
|
1053
|
+
pid: tar,
|
|
1054
|
+
tags: _tags3,
|
|
1055
|
+
data: (_v$Data = v.Data) !== null && _v$Data !== void 0 ? _v$Data : ""
|
|
1056
|
+
});
|
|
1057
|
+
case 69:
|
|
1058
|
+
_yield$ao$msg = _context5.sent;
|
|
1059
|
+
mid = _yield$ao$msg.mid;
|
|
1060
|
+
_context5.next = 76;
|
|
1061
|
+
break;
|
|
1062
|
+
case 73:
|
|
1063
|
+
_context5.prev = 73;
|
|
1064
|
+
_context5.t7 = _context5["catch"](42);
|
|
1065
|
+
console.log(_context5.t7);
|
|
1066
|
+
case 76:
|
|
1067
|
+
_context5.next = 143;
|
|
1068
|
+
break;
|
|
1069
|
+
case 78:
|
|
1070
|
+
if (!_t.__Scheduler__) {
|
|
1071
|
+
_context5.next = 141;
|
|
1072
|
+
break;
|
|
1073
|
+
}
|
|
1074
|
+
_sch = _t.__Scheduler__;
|
|
1075
|
+
_tar = v.Target;
|
|
1076
|
+
_context5.next = 83;
|
|
1077
|
+
return fetch(_sch).then(function (r) {
|
|
1078
|
+
return r.json();
|
|
1079
|
+
});
|
|
1080
|
+
case 83:
|
|
1081
|
+
_context5.t10 = _yield$fetch$then = _context5.sent;
|
|
1082
|
+
_context5.t9 = _context5.t10 === null;
|
|
1083
|
+
if (_context5.t9) {
|
|
1084
|
+
_context5.next = 87;
|
|
1085
|
+
break;
|
|
1086
|
+
}
|
|
1087
|
+
_context5.t9 = _yield$fetch$then === void 0;
|
|
1088
|
+
case 87:
|
|
1089
|
+
if (!_context5.t9) {
|
|
1090
|
+
_context5.next = 91;
|
|
1091
|
+
break;
|
|
1092
|
+
}
|
|
1093
|
+
_context5.t11 = void 0;
|
|
1094
|
+
_context5.next = 92;
|
|
1095
|
+
break;
|
|
1096
|
+
case 91:
|
|
1097
|
+
_context5.t11 = _yield$fetch$then.Processes;
|
|
1098
|
+
case 92:
|
|
1099
|
+
_context5.t12 = _yield$fetch$then$Pro = _context5.t11;
|
|
1100
|
+
_context5.t8 = _context5.t12 !== null;
|
|
1101
|
+
if (!_context5.t8) {
|
|
1102
|
+
_context5.next = 96;
|
|
1103
|
+
break;
|
|
1104
|
+
}
|
|
1105
|
+
_context5.t8 = _yield$fetch$then$Pro !== void 0;
|
|
1106
|
+
case 96:
|
|
1107
|
+
if (!_context5.t8) {
|
|
1108
|
+
_context5.next = 100;
|
|
1109
|
+
break;
|
|
1110
|
+
}
|
|
1111
|
+
_context5.t13 = _yield$fetch$then$Pro;
|
|
1112
|
+
_context5.next = 101;
|
|
1113
|
+
break;
|
|
1114
|
+
case 100:
|
|
1115
|
+
_context5.t13 = [];
|
|
1116
|
+
case 101:
|
|
1117
|
+
procs = _context5.t13;
|
|
1118
|
+
_context5.next = 104;
|
|
1119
|
+
return new _ao2["default"]({
|
|
1120
|
+
port: _sch.split(":").pop() - 3
|
|
1038
1121
|
}).init(mu.jwk);
|
|
1039
|
-
case
|
|
1040
|
-
|
|
1041
|
-
_context5.prev =
|
|
1042
|
-
|
|
1122
|
+
case 104:
|
|
1123
|
+
_ao = _context5.sent;
|
|
1124
|
+
_context5.prev = 105;
|
|
1125
|
+
_tags4 = _objectSpread(_objectSpread({}, _t), {}, {
|
|
1043
1126
|
"From-Process": opt.process,
|
|
1044
1127
|
"Pushed-For": id
|
|
1045
1128
|
});
|
|
1046
|
-
_context5.next =
|
|
1129
|
+
_context5.next = 109;
|
|
1047
1130
|
return mem.getTx(opt.process);
|
|
1048
|
-
case
|
|
1049
|
-
_context5.
|
|
1050
|
-
_context5.
|
|
1051
|
-
if (_context5.
|
|
1052
|
-
_context5.next =
|
|
1131
|
+
case 109:
|
|
1132
|
+
_context5.t16 = _yield$mem$getTx5 = _context5.sent;
|
|
1133
|
+
_context5.t15 = _context5.t16 === null;
|
|
1134
|
+
if (_context5.t15) {
|
|
1135
|
+
_context5.next = 113;
|
|
1053
1136
|
break;
|
|
1054
1137
|
}
|
|
1055
|
-
_context5.
|
|
1056
|
-
case
|
|
1057
|
-
if (!_context5.
|
|
1058
|
-
_context5.next =
|
|
1138
|
+
_context5.t15 = _yield$mem$getTx5 === void 0;
|
|
1139
|
+
case 113:
|
|
1140
|
+
if (!_context5.t15) {
|
|
1141
|
+
_context5.next = 117;
|
|
1059
1142
|
break;
|
|
1060
1143
|
}
|
|
1061
|
-
_context5.
|
|
1062
|
-
_context5.next =
|
|
1144
|
+
_context5.t17 = void 0;
|
|
1145
|
+
_context5.next = 118;
|
|
1063
1146
|
break;
|
|
1064
|
-
case
|
|
1065
|
-
_context5.
|
|
1066
|
-
case
|
|
1067
|
-
_context5.
|
|
1068
|
-
_context5.
|
|
1069
|
-
if (!_context5.
|
|
1070
|
-
_context5.next =
|
|
1147
|
+
case 117:
|
|
1148
|
+
_context5.t17 = _yield$mem$getTx5.tags;
|
|
1149
|
+
case 118:
|
|
1150
|
+
_context5.t18 = _yield$mem$getTx$tags4 = _context5.t17;
|
|
1151
|
+
_context5.t14 = _context5.t18 !== null;
|
|
1152
|
+
if (!_context5.t14) {
|
|
1153
|
+
_context5.next = 122;
|
|
1071
1154
|
break;
|
|
1072
1155
|
}
|
|
1073
|
-
_context5.
|
|
1074
|
-
case
|
|
1075
|
-
if (!_context5.
|
|
1076
|
-
_context5.next =
|
|
1156
|
+
_context5.t14 = _yield$mem$getTx$tags4 !== void 0;
|
|
1157
|
+
case 122:
|
|
1158
|
+
if (!_context5.t14) {
|
|
1159
|
+
_context5.next = 126;
|
|
1077
1160
|
break;
|
|
1078
1161
|
}
|
|
1079
|
-
_context5.
|
|
1080
|
-
_context5.next =
|
|
1162
|
+
_context5.t19 = _yield$mem$getTx$tags4;
|
|
1163
|
+
_context5.next = 127;
|
|
1081
1164
|
break;
|
|
1082
|
-
case
|
|
1083
|
-
_context5.
|
|
1084
|
-
case
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
if (
|
|
1088
|
-
_context5.next =
|
|
1089
|
-
return
|
|
1090
|
-
act: (
|
|
1091
|
-
pid:
|
|
1092
|
-
tags:
|
|
1093
|
-
data: (_v$
|
|
1165
|
+
case 126:
|
|
1166
|
+
_context5.t19 = [];
|
|
1167
|
+
case 127:
|
|
1168
|
+
_pr = _context5.t19;
|
|
1169
|
+
_module2 = (0, _utils.tags)(_pr).Module;
|
|
1170
|
+
if (_module2) _tags4["From-Module"] = _module2;
|
|
1171
|
+
_context5.next = 132;
|
|
1172
|
+
return _ao.msg({
|
|
1173
|
+
act: (_tags4$Action = _tags4["Action"]) !== null && _tags4$Action !== void 0 ? _tags4$Action : null,
|
|
1174
|
+
pid: _tar,
|
|
1175
|
+
tags: _tags4,
|
|
1176
|
+
data: (_v$Data2 = v.Data) !== null && _v$Data2 !== void 0 ? _v$Data2 : ""
|
|
1094
1177
|
});
|
|
1095
|
-
case
|
|
1096
|
-
_yield$
|
|
1097
|
-
|
|
1098
|
-
_context5.next =
|
|
1178
|
+
case 132:
|
|
1179
|
+
_yield$_ao$msg = _context5.sent;
|
|
1180
|
+
_mid = _yield$_ao$msg.mid;
|
|
1181
|
+
_context5.next = 139;
|
|
1099
1182
|
break;
|
|
1100
|
-
case
|
|
1101
|
-
_context5.prev =
|
|
1102
|
-
_context5.
|
|
1103
|
-
console.log(_context5.
|
|
1104
|
-
case
|
|
1105
|
-
_context5.next =
|
|
1183
|
+
case 136:
|
|
1184
|
+
_context5.prev = 136;
|
|
1185
|
+
_context5.t20 = _context5["catch"](105);
|
|
1186
|
+
console.log(_context5.t20);
|
|
1187
|
+
case 139:
|
|
1188
|
+
_context5.next = 143;
|
|
1106
1189
|
break;
|
|
1107
|
-
case
|
|
1108
|
-
_context5.next =
|
|
1190
|
+
case 141:
|
|
1191
|
+
_context5.next = 143;
|
|
1109
1192
|
return record({
|
|
1110
1193
|
"for": opt.message,
|
|
1111
1194
|
tags: v.Tags,
|
|
@@ -1114,45 +1197,45 @@ var _default = exports["default"] = function _default() {
|
|
|
1114
1197
|
from: opt.process,
|
|
1115
1198
|
target: v.Target
|
|
1116
1199
|
});
|
|
1117
|
-
case
|
|
1200
|
+
case 143:
|
|
1118
1201
|
case "end":
|
|
1119
1202
|
return _context5.stop();
|
|
1120
1203
|
}
|
|
1121
|
-
}, _loop, null, [[12, 30], [
|
|
1204
|
+
}, _loop, null, [[12, 30], [42, 73], [105, 136]]);
|
|
1122
1205
|
});
|
|
1123
1206
|
_iterator3.s();
|
|
1124
|
-
case
|
|
1207
|
+
case 108:
|
|
1125
1208
|
if ((_step3 = _iterator3.n()).done) {
|
|
1126
|
-
_context6.next =
|
|
1209
|
+
_context6.next = 112;
|
|
1127
1210
|
break;
|
|
1128
1211
|
}
|
|
1129
|
-
return _context6.delegateYield(_loop(), "t22",
|
|
1130
|
-
case
|
|
1131
|
-
_context6.next =
|
|
1212
|
+
return _context6.delegateYield(_loop(), "t22", 110);
|
|
1213
|
+
case 110:
|
|
1214
|
+
_context6.next = 108;
|
|
1132
1215
|
break;
|
|
1133
|
-
case
|
|
1134
|
-
_context6.next =
|
|
1216
|
+
case 112:
|
|
1217
|
+
_context6.next = 117;
|
|
1135
1218
|
break;
|
|
1136
|
-
case
|
|
1137
|
-
_context6.prev =
|
|
1138
|
-
_context6.t23 = _context6["catch"](
|
|
1219
|
+
case 114:
|
|
1220
|
+
_context6.prev = 114;
|
|
1221
|
+
_context6.t23 = _context6["catch"](105);
|
|
1139
1222
|
_iterator3.e(_context6.t23);
|
|
1140
|
-
case
|
|
1141
|
-
_context6.prev =
|
|
1223
|
+
case 117:
|
|
1224
|
+
_context6.prev = 117;
|
|
1142
1225
|
_iterator3.f();
|
|
1143
|
-
return _context6.finish(
|
|
1144
|
-
case
|
|
1226
|
+
return _context6.finish(117);
|
|
1227
|
+
case 120:
|
|
1145
1228
|
_iterator4 = _createForOfIteratorHelper((_res$Spawns = res.Spawns) !== null && _res$Spawns !== void 0 ? _res$Spawns : []);
|
|
1146
|
-
_context6.prev =
|
|
1229
|
+
_context6.prev = 121;
|
|
1147
1230
|
_iterator4.s();
|
|
1148
|
-
case
|
|
1231
|
+
case 123:
|
|
1149
1232
|
if ((_step4 = _iterator4.n()).done) {
|
|
1150
|
-
_context6.next =
|
|
1233
|
+
_context6.next = 130;
|
|
1151
1234
|
break;
|
|
1152
1235
|
}
|
|
1153
1236
|
v = _step4.value;
|
|
1154
1237
|
__tags = (0, _utils.tags)(v.Tags);
|
|
1155
|
-
_context6.next =
|
|
1238
|
+
_context6.next = 128;
|
|
1156
1239
|
return spawn({
|
|
1157
1240
|
"for": opt.message,
|
|
1158
1241
|
module: __tags.Module,
|
|
@@ -1162,87 +1245,87 @@ var _default = exports["default"] = function _default() {
|
|
|
1162
1245
|
from: __tags["From-Process"],
|
|
1163
1246
|
signer: mu.signer
|
|
1164
1247
|
});
|
|
1165
|
-
case
|
|
1166
|
-
_context6.next =
|
|
1248
|
+
case 128:
|
|
1249
|
+
_context6.next = 123;
|
|
1167
1250
|
break;
|
|
1168
|
-
case
|
|
1169
|
-
_context6.next =
|
|
1251
|
+
case 130:
|
|
1252
|
+
_context6.next = 135;
|
|
1170
1253
|
break;
|
|
1171
|
-
case
|
|
1172
|
-
_context6.prev =
|
|
1173
|
-
_context6.t24 = _context6["catch"](
|
|
1254
|
+
case 132:
|
|
1255
|
+
_context6.prev = 132;
|
|
1256
|
+
_context6.t24 = _context6["catch"](121);
|
|
1174
1257
|
_iterator4.e(_context6.t24);
|
|
1175
|
-
case
|
|
1176
|
-
_context6.prev =
|
|
1258
|
+
case 135:
|
|
1259
|
+
_context6.prev = 135;
|
|
1177
1260
|
_iterator4.f();
|
|
1178
|
-
return _context6.finish(
|
|
1179
|
-
case
|
|
1261
|
+
return _context6.finish(135);
|
|
1262
|
+
case 138:
|
|
1180
1263
|
_iterator5 = _createForOfIteratorHelper((_res$Assignments = res.Assignments) !== null && _res$Assignments !== void 0 ? _res$Assignments : []);
|
|
1181
|
-
_context6.prev =
|
|
1264
|
+
_context6.prev = 139;
|
|
1182
1265
|
_iterator5.s();
|
|
1183
|
-
case
|
|
1266
|
+
case 141:
|
|
1184
1267
|
if ((_step5 = _iterator5.n()).done) {
|
|
1185
|
-
_context6.next =
|
|
1268
|
+
_context6.next = 162;
|
|
1186
1269
|
break;
|
|
1187
1270
|
}
|
|
1188
1271
|
_v = _step5.value;
|
|
1189
1272
|
_iterator6 = _createForOfIteratorHelper(_v.Processes);
|
|
1190
|
-
_context6.prev =
|
|
1273
|
+
_context6.prev = 144;
|
|
1191
1274
|
_iterator6.s();
|
|
1192
|
-
case
|
|
1275
|
+
case 146:
|
|
1193
1276
|
if ((_step6 = _iterator6.n()).done) {
|
|
1194
|
-
_context6.next =
|
|
1277
|
+
_context6.next = 152;
|
|
1195
1278
|
break;
|
|
1196
1279
|
}
|
|
1197
1280
|
v2 = _step6.value;
|
|
1198
|
-
_context6.next =
|
|
1281
|
+
_context6.next = 150;
|
|
1199
1282
|
return _assign({
|
|
1200
1283
|
message: _v.Message,
|
|
1201
1284
|
process: v2,
|
|
1202
1285
|
from: opt.process,
|
|
1203
1286
|
signer: mu.signer
|
|
1204
1287
|
});
|
|
1205
|
-
case
|
|
1206
|
-
_context6.next =
|
|
1288
|
+
case 150:
|
|
1289
|
+
_context6.next = 146;
|
|
1207
1290
|
break;
|
|
1208
|
-
case
|
|
1209
|
-
_context6.next =
|
|
1291
|
+
case 152:
|
|
1292
|
+
_context6.next = 157;
|
|
1210
1293
|
break;
|
|
1211
|
-
case
|
|
1212
|
-
_context6.prev =
|
|
1213
|
-
_context6.t25 = _context6["catch"](
|
|
1294
|
+
case 154:
|
|
1295
|
+
_context6.prev = 154;
|
|
1296
|
+
_context6.t25 = _context6["catch"](144);
|
|
1214
1297
|
_iterator6.e(_context6.t25);
|
|
1215
|
-
case
|
|
1216
|
-
_context6.prev =
|
|
1298
|
+
case 157:
|
|
1299
|
+
_context6.prev = 157;
|
|
1217
1300
|
_iterator6.f();
|
|
1218
|
-
return _context6.finish(
|
|
1219
|
-
case
|
|
1220
|
-
_context6.next =
|
|
1301
|
+
return _context6.finish(157);
|
|
1302
|
+
case 160:
|
|
1303
|
+
_context6.next = 141;
|
|
1221
1304
|
break;
|
|
1222
|
-
case
|
|
1223
|
-
_context6.next =
|
|
1305
|
+
case 162:
|
|
1306
|
+
_context6.next = 167;
|
|
1224
1307
|
break;
|
|
1225
|
-
case
|
|
1226
|
-
_context6.prev =
|
|
1227
|
-
_context6.t26 = _context6["catch"](
|
|
1308
|
+
case 164:
|
|
1309
|
+
_context6.prev = 164;
|
|
1310
|
+
_context6.t26 = _context6["catch"](139);
|
|
1228
1311
|
_iterator5.e(_context6.t26);
|
|
1229
|
-
case
|
|
1230
|
-
_context6.prev =
|
|
1312
|
+
case 167:
|
|
1313
|
+
_context6.prev = 167;
|
|
1231
1314
|
_iterator5.f();
|
|
1232
|
-
return _context6.finish(
|
|
1233
|
-
case
|
|
1315
|
+
return _context6.finish(167);
|
|
1316
|
+
case 170:
|
|
1234
1317
|
return _context6.abrupt("return", id);
|
|
1235
|
-
case
|
|
1236
|
-
_context6.prev =
|
|
1318
|
+
case 173:
|
|
1319
|
+
_context6.prev = 173;
|
|
1237
1320
|
_context6.t27 = _context6["catch"](40);
|
|
1238
1321
|
console.log(_context6.t27);
|
|
1239
|
-
case 175:
|
|
1240
|
-
return _context6.abrupt("return", null);
|
|
1241
1322
|
case 176:
|
|
1323
|
+
return _context6.abrupt("return", null);
|
|
1324
|
+
case 177:
|
|
1242
1325
|
case "end":
|
|
1243
1326
|
return _context6.stop();
|
|
1244
1327
|
}
|
|
1245
|
-
}, _callee5, null, [[40,
|
|
1328
|
+
}, _callee5, null, [[40, 173], [105, 114, 117, 120], [121, 132, 135, 138], [139, 164, 167, 170], [144, 154, 157, 160]]);
|
|
1246
1329
|
}));
|
|
1247
1330
|
return function assign(_x8) {
|
|
1248
1331
|
return _ref9.apply(this, arguments);
|
|
@@ -1250,7 +1333,7 @@ var _default = exports["default"] = function _default() {
|
|
|
1250
1333
|
}();
|
|
1251
1334
|
var message = /*#__PURE__*/function () {
|
|
1252
1335
|
var _ref13 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee6(opt) {
|
|
1253
|
-
var id, owner, item, _opt$id2, _key, i, _yield$ar$httpmsg2, _p, new_slot, last_slot, _opt$item$id, _opt$item, _opt$owner, p, _opt$tags3, _yield$mem$getTx$
|
|
1336
|
+
var id, owner, item, _opt$id2, _key, i, _yield$ar$httpmsg2, _p, new_slot, last_slot, _opt$item$id, _opt$item, _opt$owner, p, _opt$tags3, _yield$mem$getTx$tags5, _yield$mem$getTx6, pr, module, _yield$ar$dataitem3, _msg, _opt, _ref14, _opt$from2, _opt$http_msg$data, from, data, _tags, msg, _env, _yield$mem$getTx7, _yield$mem$getWasm3, format, mod, wasm, wdrive, start, res, _msg2, key;
|
|
1254
1337
|
return _regeneratorRuntime().wrap(function _callee6$(_context7) {
|
|
1255
1338
|
while (1) switch (_context7.prev = _context7.next) {
|
|
1256
1339
|
case 0:
|
|
@@ -1349,13 +1432,13 @@ var _default = exports["default"] = function _default() {
|
|
|
1349
1432
|
_context7.next = 50;
|
|
1350
1433
|
return mem.getTx(opt.from);
|
|
1351
1434
|
case 50:
|
|
1352
|
-
_context7.t2 = _yield$mem$
|
|
1435
|
+
_context7.t2 = _yield$mem$getTx6 = _context7.sent;
|
|
1353
1436
|
_context7.t1 = _context7.t2 === null;
|
|
1354
1437
|
if (_context7.t1) {
|
|
1355
1438
|
_context7.next = 54;
|
|
1356
1439
|
break;
|
|
1357
1440
|
}
|
|
1358
|
-
_context7.t1 = _yield$mem$
|
|
1441
|
+
_context7.t1 = _yield$mem$getTx6 === void 0;
|
|
1359
1442
|
case 54:
|
|
1360
1443
|
if (!_context7.t1) {
|
|
1361
1444
|
_context7.next = 58;
|
|
@@ -1365,21 +1448,21 @@ var _default = exports["default"] = function _default() {
|
|
|
1365
1448
|
_context7.next = 59;
|
|
1366
1449
|
break;
|
|
1367
1450
|
case 58:
|
|
1368
|
-
_context7.t3 = _yield$mem$
|
|
1451
|
+
_context7.t3 = _yield$mem$getTx6.tags;
|
|
1369
1452
|
case 59:
|
|
1370
|
-
_context7.t4 = _yield$mem$getTx$
|
|
1453
|
+
_context7.t4 = _yield$mem$getTx$tags5 = _context7.t3;
|
|
1371
1454
|
_context7.t0 = _context7.t4 !== null;
|
|
1372
1455
|
if (!_context7.t0) {
|
|
1373
1456
|
_context7.next = 63;
|
|
1374
1457
|
break;
|
|
1375
1458
|
}
|
|
1376
|
-
_context7.t0 = _yield$mem$getTx$
|
|
1459
|
+
_context7.t0 = _yield$mem$getTx$tags5 !== void 0;
|
|
1377
1460
|
case 63:
|
|
1378
1461
|
if (!_context7.t0) {
|
|
1379
1462
|
_context7.next = 67;
|
|
1380
1463
|
break;
|
|
1381
1464
|
}
|
|
1382
|
-
_context7.t5 = _yield$mem$getTx$
|
|
1465
|
+
_context7.t5 = _yield$mem$getTx$tags5;
|
|
1383
1466
|
_context7.next = 68;
|
|
1384
1467
|
break;
|
|
1385
1468
|
case 67:
|
|
@@ -1452,13 +1535,13 @@ var _default = exports["default"] = function _default() {
|
|
|
1452
1535
|
_context7.next = 108;
|
|
1453
1536
|
return mem.getTx(p.id);
|
|
1454
1537
|
case 108:
|
|
1455
|
-
_context7.t11 = _yield$mem$
|
|
1538
|
+
_context7.t11 = _yield$mem$getTx7 = _context7.sent;
|
|
1456
1539
|
_context7.t10 = _context7.t11 === null;
|
|
1457
1540
|
if (_context7.t10) {
|
|
1458
1541
|
_context7.next = 112;
|
|
1459
1542
|
break;
|
|
1460
1543
|
}
|
|
1461
|
-
_context7.t10 = _yield$mem$
|
|
1544
|
+
_context7.t10 = _yield$mem$getTx7 === void 0;
|
|
1462
1545
|
case 112:
|
|
1463
1546
|
if (!_context7.t10) {
|
|
1464
1547
|
_context7.next = 116;
|
|
@@ -1468,7 +1551,7 @@ var _default = exports["default"] = function _default() {
|
|
|
1468
1551
|
_context7.next = 117;
|
|
1469
1552
|
break;
|
|
1470
1553
|
case 116:
|
|
1471
|
-
_context7.t12 = _yield$mem$
|
|
1554
|
+
_context7.t12 = _yield$mem$getTx7.item;
|
|
1472
1555
|
case 117:
|
|
1473
1556
|
_context7.t13 = _context7.t12;
|
|
1474
1557
|
_context7.next = 120;
|
|
@@ -1544,7 +1627,7 @@ var _default = exports["default"] = function _default() {
|
|
|
1544
1627
|
var record = /*#__PURE__*/function () {
|
|
1545
1628
|
var _ref15 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee7(opt) {
|
|
1546
1629
|
var _opt$item$id2, _opt$item2, _opt$owner2, _opt$tags4;
|
|
1547
|
-
var id, owner, item, _yield$mem$getTx$
|
|
1630
|
+
var id, owner, item, _yield$mem$getTx$tags6, _yield$mem$getTx8, pr, module, _yield$ar$dataitem4, _msg;
|
|
1548
1631
|
return _regeneratorRuntime().wrap(function _callee7$(_context8) {
|
|
1549
1632
|
while (1) switch (_context8.prev = _context8.next) {
|
|
1550
1633
|
case 0:
|
|
@@ -1571,13 +1654,13 @@ var _default = exports["default"] = function _default() {
|
|
|
1571
1654
|
_context8.next = 9;
|
|
1572
1655
|
return mem.getTx(opt.from);
|
|
1573
1656
|
case 9:
|
|
1574
|
-
_context8.t2 = _yield$mem$
|
|
1657
|
+
_context8.t2 = _yield$mem$getTx8 = _context8.sent;
|
|
1575
1658
|
_context8.t1 = _context8.t2 === null;
|
|
1576
1659
|
if (_context8.t1) {
|
|
1577
1660
|
_context8.next = 13;
|
|
1578
1661
|
break;
|
|
1579
1662
|
}
|
|
1580
|
-
_context8.t1 = _yield$mem$
|
|
1663
|
+
_context8.t1 = _yield$mem$getTx8 === void 0;
|
|
1581
1664
|
case 13:
|
|
1582
1665
|
if (!_context8.t1) {
|
|
1583
1666
|
_context8.next = 17;
|
|
@@ -1587,21 +1670,21 @@ var _default = exports["default"] = function _default() {
|
|
|
1587
1670
|
_context8.next = 18;
|
|
1588
1671
|
break;
|
|
1589
1672
|
case 17:
|
|
1590
|
-
_context8.t3 = _yield$mem$
|
|
1673
|
+
_context8.t3 = _yield$mem$getTx8.tags;
|
|
1591
1674
|
case 18:
|
|
1592
|
-
_context8.t4 = _yield$mem$getTx$
|
|
1675
|
+
_context8.t4 = _yield$mem$getTx$tags6 = _context8.t3;
|
|
1593
1676
|
_context8.t0 = _context8.t4 !== null;
|
|
1594
1677
|
if (!_context8.t0) {
|
|
1595
1678
|
_context8.next = 22;
|
|
1596
1679
|
break;
|
|
1597
1680
|
}
|
|
1598
|
-
_context8.t0 = _yield$mem$getTx$
|
|
1681
|
+
_context8.t0 = _yield$mem$getTx$tags6 !== void 0;
|
|
1599
1682
|
case 22:
|
|
1600
1683
|
if (!_context8.t0) {
|
|
1601
1684
|
_context8.next = 26;
|
|
1602
1685
|
break;
|
|
1603
1686
|
}
|
|
1604
|
-
_context8.t5 = _yield$mem$getTx$
|
|
1687
|
+
_context8.t5 = _yield$mem$getTx$tags6;
|
|
1605
1688
|
_context8.next = 27;
|
|
1606
1689
|
break;
|
|
1607
1690
|
case 26:
|