@lace-cloud/canvas 0.21.1 → 0.23.0

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.
@@ -2888,7 +2888,7 @@ var ModuleReference = {
2888
2888
  }
2889
2889
  };
2890
2890
  function createBaseTerraformBlock() {
2891
- return { required_version: "", required_providers: {}, backend: void 0 };
2891
+ return { required_version: "", required_providers: {} };
2892
2892
  }
2893
2893
  var TerraformBlock = {
2894
2894
  encode(message, writer = new import_wire3.BinaryWriter()) {
@@ -2898,9 +2898,6 @@ var TerraformBlock = {
2898
2898
  globalThis.Object.entries(message.required_providers).forEach(([key, value]) => {
2899
2899
  TerraformBlock_RequiredProvidersEntry.encode({ key, value }, writer.uint32(18).fork()).join();
2900
2900
  });
2901
- if (message.backend !== void 0) {
2902
- BackendConfig.encode(message.backend, writer.uint32(26).fork()).join();
2903
- }
2904
2901
  return writer;
2905
2902
  },
2906
2903
  decode(input, length) {
@@ -2927,13 +2924,6 @@ var TerraformBlock = {
2927
2924
  }
2928
2925
  continue;
2929
2926
  }
2930
- case 3: {
2931
- if (tag !== 26) {
2932
- break;
2933
- }
2934
- message.backend = BackendConfig.decode(reader, reader.uint32());
2935
- continue;
2936
- }
2937
2927
  }
2938
2928
  if ((tag & 7) === 4 || tag === 0) {
2939
2929
  break;
@@ -2957,8 +2947,7 @@ var TerraformBlock = {
2957
2947
  return acc;
2958
2948
  },
2959
2949
  {}
2960
- ) : {},
2961
- backend: isSet2(object.backend) ? BackendConfig.fromJSON(object.backend) : void 0
2950
+ ) : {}
2962
2951
  };
2963
2952
  },
2964
2953
  toJSON(message) {
@@ -2975,9 +2964,6 @@ var TerraformBlock = {
2975
2964
  });
2976
2965
  }
2977
2966
  }
2978
- if (message.backend !== void 0) {
2979
- obj.backend = BackendConfig.toJSON(message.backend);
2980
- }
2981
2967
  return obj;
2982
2968
  },
2983
2969
  create(base) {
@@ -2995,7 +2981,6 @@ var TerraformBlock = {
2995
2981
  },
2996
2982
  {}
2997
2983
  );
2998
- message.backend = object.backend !== void 0 && object.backend !== null ? BackendConfig.fromPartial(object.backend) : void 0;
2999
2984
  return message;
3000
2985
  }
3001
2986
  };
@@ -3150,167 +3135,6 @@ var ProviderRequirement = {
3150
3135
  return message;
3151
3136
  }
3152
3137
  };
3153
- function createBaseBackendConfig() {
3154
- return { type: "", config: {} };
3155
- }
3156
- var BackendConfig = {
3157
- encode(message, writer = new import_wire3.BinaryWriter()) {
3158
- if (message.type !== "") {
3159
- writer.uint32(10).string(message.type);
3160
- }
3161
- globalThis.Object.entries(message.config).forEach(([key, value]) => {
3162
- if (value !== void 0) {
3163
- BackendConfig_ConfigEntry.encode({ key, value }, writer.uint32(18).fork()).join();
3164
- }
3165
- });
3166
- return writer;
3167
- },
3168
- decode(input, length) {
3169
- const reader = input instanceof import_wire3.BinaryReader ? input : new import_wire3.BinaryReader(input);
3170
- const end = length === void 0 ? reader.len : reader.pos + length;
3171
- const message = createBaseBackendConfig();
3172
- while (reader.pos < end) {
3173
- const tag = reader.uint32();
3174
- switch (tag >>> 3) {
3175
- case 1: {
3176
- if (tag !== 10) {
3177
- break;
3178
- }
3179
- message.type = reader.string();
3180
- continue;
3181
- }
3182
- case 2: {
3183
- if (tag !== 18) {
3184
- break;
3185
- }
3186
- const entry2 = BackendConfig_ConfigEntry.decode(reader, reader.uint32());
3187
- if (entry2.value !== void 0) {
3188
- message.config[entry2.key] = entry2.value;
3189
- }
3190
- continue;
3191
- }
3192
- }
3193
- if ((tag & 7) === 4 || tag === 0) {
3194
- break;
3195
- }
3196
- reader.skip(tag & 7);
3197
- }
3198
- return message;
3199
- },
3200
- fromJSON(object) {
3201
- return {
3202
- type: isSet2(object.type) ? globalThis.String(object.type) : "",
3203
- config: isObject2(object.config) ? globalThis.Object.entries(object.config).reduce(
3204
- (acc, [key, value]) => {
3205
- acc[key] = value;
3206
- return acc;
3207
- },
3208
- {}
3209
- ) : {}
3210
- };
3211
- },
3212
- toJSON(message) {
3213
- const obj = {};
3214
- if (message.type !== "") {
3215
- obj.type = message.type;
3216
- }
3217
- if (message.config) {
3218
- const entries = globalThis.Object.entries(message.config);
3219
- if (entries.length > 0) {
3220
- obj.config = {};
3221
- entries.forEach(([k, v]) => {
3222
- obj.config[k] = v;
3223
- });
3224
- }
3225
- }
3226
- return obj;
3227
- },
3228
- create(base) {
3229
- return BackendConfig.fromPartial(base ?? {});
3230
- },
3231
- fromPartial(object) {
3232
- const message = createBaseBackendConfig();
3233
- message.type = object.type ?? "";
3234
- message.config = globalThis.Object.entries(object.config ?? {}).reduce(
3235
- (acc, [key, value]) => {
3236
- if (value !== void 0) {
3237
- acc[key] = value;
3238
- }
3239
- return acc;
3240
- },
3241
- {}
3242
- );
3243
- return message;
3244
- }
3245
- };
3246
- function createBaseBackendConfig_ConfigEntry() {
3247
- return { key: "", value: void 0 };
3248
- }
3249
- var BackendConfig_ConfigEntry = {
3250
- encode(message, writer = new import_wire3.BinaryWriter()) {
3251
- if (message.key !== "") {
3252
- writer.uint32(10).string(message.key);
3253
- }
3254
- if (message.value !== void 0) {
3255
- Value.encode(Value.wrap(message.value), writer.uint32(18).fork()).join();
3256
- }
3257
- return writer;
3258
- },
3259
- decode(input, length) {
3260
- const reader = input instanceof import_wire3.BinaryReader ? input : new import_wire3.BinaryReader(input);
3261
- const end = length === void 0 ? reader.len : reader.pos + length;
3262
- const message = createBaseBackendConfig_ConfigEntry();
3263
- while (reader.pos < end) {
3264
- const tag = reader.uint32();
3265
- switch (tag >>> 3) {
3266
- case 1: {
3267
- if (tag !== 10) {
3268
- break;
3269
- }
3270
- message.key = reader.string();
3271
- continue;
3272
- }
3273
- case 2: {
3274
- if (tag !== 18) {
3275
- break;
3276
- }
3277
- message.value = Value.unwrap(Value.decode(reader, reader.uint32()));
3278
- continue;
3279
- }
3280
- }
3281
- if ((tag & 7) === 4 || tag === 0) {
3282
- break;
3283
- }
3284
- reader.skip(tag & 7);
3285
- }
3286
- return message;
3287
- },
3288
- fromJSON(object) {
3289
- return {
3290
- key: isSet2(object.key) ? globalThis.String(object.key) : "",
3291
- value: isSet2(object?.value) ? object.value : void 0
3292
- };
3293
- },
3294
- toJSON(message) {
3295
- const obj = {};
3296
- if (message.key !== "") {
3297
- obj.key = message.key;
3298
- }
3299
- if (message.value !== void 0) {
3300
- obj.value = message.value;
3301
- }
3302
- return obj;
3303
- },
3304
- create(base) {
3305
- return BackendConfig_ConfigEntry.fromPartial(base ?? {});
3306
- },
3307
- fromPartial(object) {
3308
- const message = createBaseBackendConfig_ConfigEntry();
3309
- message.key = object.key ?? "";
3310
- message.value = object.value ?? void 0;
3311
- return message;
3312
- }
3313
- };
3314
3138
  function createBaseProviderConfig() {
3315
3139
  return { name: "", alias: "", config: {}, blocks: [] };
3316
3140
  }
@@ -6008,13 +5832,16 @@ var UngroupAction = {
6008
5832
  }
6009
5833
  };
6010
5834
  function createBaseSetVariablesAction() {
6011
- return { variables: [] };
5835
+ return { variables: [], scope: "" };
6012
5836
  }
6013
5837
  var SetVariablesAction = {
6014
5838
  encode(message, writer = new import_wire4.BinaryWriter()) {
6015
5839
  for (const v of message.variables) {
6016
5840
  InputDef2.encode(v, writer.uint32(10).fork()).join();
6017
5841
  }
5842
+ if (message.scope !== "") {
5843
+ writer.uint32(18).string(message.scope);
5844
+ }
6018
5845
  return writer;
6019
5846
  },
6020
5847
  decode(input, length) {
@@ -6031,6 +5858,13 @@ var SetVariablesAction = {
6031
5858
  message.variables.push(InputDef2.decode(reader, reader.uint32()));
6032
5859
  continue;
6033
5860
  }
5861
+ case 2: {
5862
+ if (tag !== 18) {
5863
+ break;
5864
+ }
5865
+ message.scope = reader.string();
5866
+ continue;
5867
+ }
6034
5868
  }
6035
5869
  if ((tag & 7) === 4 || tag === 0) {
6036
5870
  break;
@@ -6041,7 +5875,8 @@ var SetVariablesAction = {
6041
5875
  },
6042
5876
  fromJSON(object) {
6043
5877
  return {
6044
- variables: globalThis.Array.isArray(object?.variables) ? object.variables.map((e) => InputDef2.fromJSON(e)) : []
5878
+ variables: globalThis.Array.isArray(object?.variables) ? object.variables.map((e) => InputDef2.fromJSON(e)) : [],
5879
+ scope: isSet3(object.scope) ? globalThis.String(object.scope) : ""
6045
5880
  };
6046
5881
  },
6047
5882
  toJSON(message) {
@@ -6049,6 +5884,9 @@ var SetVariablesAction = {
6049
5884
  if (message.variables?.length) {
6050
5885
  obj.variables = message.variables.map((e) => InputDef2.toJSON(e));
6051
5886
  }
5887
+ if (message.scope !== "") {
5888
+ obj.scope = message.scope;
5889
+ }
6052
5890
  return obj;
6053
5891
  },
6054
5892
  create(base) {
@@ -6057,11 +5895,12 @@ var SetVariablesAction = {
6057
5895
  fromPartial(object) {
6058
5896
  const message = createBaseSetVariablesAction();
6059
5897
  message.variables = object.variables?.map((e) => InputDef2.fromPartial(e)) || [];
5898
+ message.scope = object.scope ?? "";
6060
5899
  return message;
6061
5900
  }
6062
5901
  };
6063
5902
  function createBaseSetExportsAction() {
6064
- return { outputs: [], output_defs: [] };
5903
+ return { outputs: [], output_defs: [], scope: "" };
6065
5904
  }
6066
5905
  var SetExportsAction = {
6067
5906
  encode(message, writer = new import_wire4.BinaryWriter()) {
@@ -6071,6 +5910,9 @@ var SetExportsAction = {
6071
5910
  for (const v of message.output_defs) {
6072
5911
  OutputDef2.encode(v, writer.uint32(18).fork()).join();
6073
5912
  }
5913
+ if (message.scope !== "") {
5914
+ writer.uint32(26).string(message.scope);
5915
+ }
6074
5916
  return writer;
6075
5917
  },
6076
5918
  decode(input, length) {
@@ -6094,6 +5936,13 @@ var SetExportsAction = {
6094
5936
  message.output_defs.push(OutputDef2.decode(reader, reader.uint32()));
6095
5937
  continue;
6096
5938
  }
5939
+ case 3: {
5940
+ if (tag !== 26) {
5941
+ break;
5942
+ }
5943
+ message.scope = reader.string();
5944
+ continue;
5945
+ }
6097
5946
  }
6098
5947
  if ((tag & 7) === 4 || tag === 0) {
6099
5948
  break;
@@ -6105,7 +5954,8 @@ var SetExportsAction = {
6105
5954
  fromJSON(object) {
6106
5955
  return {
6107
5956
  outputs: globalThis.Array.isArray(object?.outputs) ? object.outputs.map((e) => OutputExportEntry.fromJSON(e)) : [],
6108
- output_defs: globalThis.Array.isArray(object?.outputDefs) ? object.outputDefs.map((e) => OutputDef2.fromJSON(e)) : globalThis.Array.isArray(object?.output_defs) ? object.output_defs.map((e) => OutputDef2.fromJSON(e)) : []
5957
+ output_defs: globalThis.Array.isArray(object?.outputDefs) ? object.outputDefs.map((e) => OutputDef2.fromJSON(e)) : globalThis.Array.isArray(object?.output_defs) ? object.output_defs.map((e) => OutputDef2.fromJSON(e)) : [],
5958
+ scope: isSet3(object.scope) ? globalThis.String(object.scope) : ""
6109
5959
  };
6110
5960
  },
6111
5961
  toJSON(message) {
@@ -6116,6 +5966,9 @@ var SetExportsAction = {
6116
5966
  if (message.output_defs?.length) {
6117
5967
  obj.outputDefs = message.output_defs.map((e) => OutputDef2.toJSON(e));
6118
5968
  }
5969
+ if (message.scope !== "") {
5970
+ obj.scope = message.scope;
5971
+ }
6119
5972
  return obj;
6120
5973
  },
6121
5974
  create(base) {
@@ -6125,22 +5978,20 @@ var SetExportsAction = {
6125
5978
  const message = createBaseSetExportsAction();
6126
5979
  message.outputs = object.outputs?.map((e) => OutputExportEntry.fromPartial(e)) || [];
6127
5980
  message.output_defs = object.output_defs?.map((e) => OutputDef2.fromPartial(e)) || [];
5981
+ message.scope = object.scope ?? "";
6128
5982
  return message;
6129
5983
  }
6130
5984
  };
6131
5985
  function createBaseOutputExportEntry() {
6132
- return { name: "", source_instance: "", source_output: "" };
5986
+ return { name: "", value: "" };
6133
5987
  }
6134
5988
  var OutputExportEntry = {
6135
5989
  encode(message, writer = new import_wire4.BinaryWriter()) {
6136
5990
  if (message.name !== "") {
6137
5991
  writer.uint32(10).string(message.name);
6138
5992
  }
6139
- if (message.source_instance !== "") {
6140
- writer.uint32(18).string(message.source_instance);
6141
- }
6142
- if (message.source_output !== "") {
6143
- writer.uint32(26).string(message.source_output);
5993
+ if (message.value !== "") {
5994
+ writer.uint32(34).string(message.value);
6144
5995
  }
6145
5996
  return writer;
6146
5997
  },
@@ -6158,18 +6009,11 @@ var OutputExportEntry = {
6158
6009
  message.name = reader.string();
6159
6010
  continue;
6160
6011
  }
6161
- case 2: {
6162
- if (tag !== 18) {
6163
- break;
6164
- }
6165
- message.source_instance = reader.string();
6166
- continue;
6167
- }
6168
- case 3: {
6169
- if (tag !== 26) {
6012
+ case 4: {
6013
+ if (tag !== 34) {
6170
6014
  break;
6171
6015
  }
6172
- message.source_output = reader.string();
6016
+ message.value = reader.string();
6173
6017
  continue;
6174
6018
  }
6175
6019
  }
@@ -6183,8 +6027,7 @@ var OutputExportEntry = {
6183
6027
  fromJSON(object) {
6184
6028
  return {
6185
6029
  name: isSet3(object.name) ? globalThis.String(object.name) : "",
6186
- source_instance: isSet3(object.sourceInstance) ? globalThis.String(object.sourceInstance) : isSet3(object.source_instance) ? globalThis.String(object.source_instance) : "",
6187
- source_output: isSet3(object.sourceOutput) ? globalThis.String(object.sourceOutput) : isSet3(object.source_output) ? globalThis.String(object.source_output) : ""
6030
+ value: isSet3(object.value) ? globalThis.String(object.value) : ""
6188
6031
  };
6189
6032
  },
6190
6033
  toJSON(message) {
@@ -6192,11 +6035,8 @@ var OutputExportEntry = {
6192
6035
  if (message.name !== "") {
6193
6036
  obj.name = message.name;
6194
6037
  }
6195
- if (message.source_instance !== "") {
6196
- obj.sourceInstance = message.source_instance;
6197
- }
6198
- if (message.source_output !== "") {
6199
- obj.sourceOutput = message.source_output;
6038
+ if (message.value !== "") {
6039
+ obj.value = message.value;
6200
6040
  }
6201
6041
  return obj;
6202
6042
  },
@@ -6206,13 +6046,12 @@ var OutputExportEntry = {
6206
6046
  fromPartial(object) {
6207
6047
  const message = createBaseOutputExportEntry();
6208
6048
  message.name = object.name ?? "";
6209
- message.source_instance = object.source_instance ?? "";
6210
- message.source_output = object.source_output ?? "";
6049
+ message.value = object.value ?? "";
6211
6050
  return message;
6212
6051
  }
6213
6052
  };
6214
6053
  function createBaseSetTerraformAction() {
6215
- return { required_version: "", required_providers: [], backend: void 0 };
6054
+ return { required_version: "", required_providers: [], scope: "" };
6216
6055
  }
6217
6056
  var SetTerraformAction = {
6218
6057
  encode(message, writer = new import_wire4.BinaryWriter()) {
@@ -6222,8 +6061,8 @@ var SetTerraformAction = {
6222
6061
  for (const v of message.required_providers) {
6223
6062
  ProviderReqView.encode(v, writer.uint32(18).fork()).join();
6224
6063
  }
6225
- if (message.backend !== void 0) {
6226
- BackendView.encode(message.backend, writer.uint32(26).fork()).join();
6064
+ if (message.scope !== "") {
6065
+ writer.uint32(34).string(message.scope);
6227
6066
  }
6228
6067
  return writer;
6229
6068
  },
@@ -6248,11 +6087,11 @@ var SetTerraformAction = {
6248
6087
  message.required_providers.push(ProviderReqView.decode(reader, reader.uint32()));
6249
6088
  continue;
6250
6089
  }
6251
- case 3: {
6252
- if (tag !== 26) {
6090
+ case 4: {
6091
+ if (tag !== 34) {
6253
6092
  break;
6254
6093
  }
6255
- message.backend = BackendView.decode(reader, reader.uint32());
6094
+ message.scope = reader.string();
6256
6095
  continue;
6257
6096
  }
6258
6097
  }
@@ -6267,7 +6106,7 @@ var SetTerraformAction = {
6267
6106
  return {
6268
6107
  required_version: isSet3(object.requiredVersion) ? globalThis.String(object.requiredVersion) : isSet3(object.required_version) ? globalThis.String(object.required_version) : "",
6269
6108
  required_providers: globalThis.Array.isArray(object?.requiredProviders) ? object.requiredProviders.map((e) => ProviderReqView.fromJSON(e)) : globalThis.Array.isArray(object?.required_providers) ? object.required_providers.map((e) => ProviderReqView.fromJSON(e)) : [],
6270
- backend: isSet3(object.backend) ? BackendView.fromJSON(object.backend) : void 0
6109
+ scope: isSet3(object.scope) ? globalThis.String(object.scope) : ""
6271
6110
  };
6272
6111
  },
6273
6112
  toJSON(message) {
@@ -6278,8 +6117,8 @@ var SetTerraformAction = {
6278
6117
  if (message.required_providers?.length) {
6279
6118
  obj.requiredProviders = message.required_providers.map((e) => ProviderReqView.toJSON(e));
6280
6119
  }
6281
- if (message.backend !== void 0) {
6282
- obj.backend = BackendView.toJSON(message.backend);
6120
+ if (message.scope !== "") {
6121
+ obj.scope = message.scope;
6283
6122
  }
6284
6123
  return obj;
6285
6124
  },
@@ -6290,18 +6129,21 @@ var SetTerraformAction = {
6290
6129
  const message = createBaseSetTerraformAction();
6291
6130
  message.required_version = object.required_version ?? "";
6292
6131
  message.required_providers = object.required_providers?.map((e) => ProviderReqView.fromPartial(e)) || [];
6293
- message.backend = object.backend !== void 0 && object.backend !== null ? BackendView.fromPartial(object.backend) : void 0;
6132
+ message.scope = object.scope ?? "";
6294
6133
  return message;
6295
6134
  }
6296
6135
  };
6297
6136
  function createBaseSetProvidersAction() {
6298
- return { providers: [] };
6137
+ return { providers: [], scope: "" };
6299
6138
  }
6300
6139
  var SetProvidersAction = {
6301
6140
  encode(message, writer = new import_wire4.BinaryWriter()) {
6302
6141
  for (const v of message.providers) {
6303
6142
  ProviderView.encode(v, writer.uint32(10).fork()).join();
6304
6143
  }
6144
+ if (message.scope !== "") {
6145
+ writer.uint32(18).string(message.scope);
6146
+ }
6305
6147
  return writer;
6306
6148
  },
6307
6149
  decode(input, length) {
@@ -6318,6 +6160,13 @@ var SetProvidersAction = {
6318
6160
  message.providers.push(ProviderView.decode(reader, reader.uint32()));
6319
6161
  continue;
6320
6162
  }
6163
+ case 2: {
6164
+ if (tag !== 18) {
6165
+ break;
6166
+ }
6167
+ message.scope = reader.string();
6168
+ continue;
6169
+ }
6321
6170
  }
6322
6171
  if ((tag & 7) === 4 || tag === 0) {
6323
6172
  break;
@@ -6328,7 +6177,8 @@ var SetProvidersAction = {
6328
6177
  },
6329
6178
  fromJSON(object) {
6330
6179
  return {
6331
- providers: globalThis.Array.isArray(object?.providers) ? object.providers.map((e) => ProviderView.fromJSON(e)) : []
6180
+ providers: globalThis.Array.isArray(object?.providers) ? object.providers.map((e) => ProviderView.fromJSON(e)) : [],
6181
+ scope: isSet3(object.scope) ? globalThis.String(object.scope) : ""
6332
6182
  };
6333
6183
  },
6334
6184
  toJSON(message) {
@@ -6336,6 +6186,9 @@ var SetProvidersAction = {
6336
6186
  if (message.providers?.length) {
6337
6187
  obj.providers = message.providers.map((e) => ProviderView.toJSON(e));
6338
6188
  }
6189
+ if (message.scope !== "") {
6190
+ obj.scope = message.scope;
6191
+ }
6339
6192
  return obj;
6340
6193
  },
6341
6194
  create(base) {
@@ -6344,17 +6197,21 @@ var SetProvidersAction = {
6344
6197
  fromPartial(object) {
6345
6198
  const message = createBaseSetProvidersAction();
6346
6199
  message.providers = object.providers?.map((e) => ProviderView.fromPartial(e)) || [];
6200
+ message.scope = object.scope ?? "";
6347
6201
  return message;
6348
6202
  }
6349
6203
  };
6350
6204
  function createBaseSetLocalsAction() {
6351
- return { locals: [] };
6205
+ return { locals: [], scope: "" };
6352
6206
  }
6353
6207
  var SetLocalsAction = {
6354
6208
  encode(message, writer = new import_wire4.BinaryWriter()) {
6355
6209
  for (const v of message.locals) {
6356
6210
  LocalEntry.encode(v, writer.uint32(10).fork()).join();
6357
6211
  }
6212
+ if (message.scope !== "") {
6213
+ writer.uint32(18).string(message.scope);
6214
+ }
6358
6215
  return writer;
6359
6216
  },
6360
6217
  decode(input, length) {
@@ -6371,6 +6228,13 @@ var SetLocalsAction = {
6371
6228
  message.locals.push(LocalEntry.decode(reader, reader.uint32()));
6372
6229
  continue;
6373
6230
  }
6231
+ case 2: {
6232
+ if (tag !== 18) {
6233
+ break;
6234
+ }
6235
+ message.scope = reader.string();
6236
+ continue;
6237
+ }
6374
6238
  }
6375
6239
  if ((tag & 7) === 4 || tag === 0) {
6376
6240
  break;
@@ -6381,7 +6245,8 @@ var SetLocalsAction = {
6381
6245
  },
6382
6246
  fromJSON(object) {
6383
6247
  return {
6384
- locals: globalThis.Array.isArray(object?.locals) ? object.locals.map((e) => LocalEntry.fromJSON(e)) : []
6248
+ locals: globalThis.Array.isArray(object?.locals) ? object.locals.map((e) => LocalEntry.fromJSON(e)) : [],
6249
+ scope: isSet3(object.scope) ? globalThis.String(object.scope) : ""
6385
6250
  };
6386
6251
  },
6387
6252
  toJSON(message) {
@@ -6389,6 +6254,9 @@ var SetLocalsAction = {
6389
6254
  if (message.locals?.length) {
6390
6255
  obj.locals = message.locals.map((e) => LocalEntry.toJSON(e));
6391
6256
  }
6257
+ if (message.scope !== "") {
6258
+ obj.scope = message.scope;
6259
+ }
6392
6260
  return obj;
6393
6261
  },
6394
6262
  create(base) {
@@ -6397,35 +6265,95 @@ var SetLocalsAction = {
6397
6265
  fromPartial(object) {
6398
6266
  const message = createBaseSetLocalsAction();
6399
6267
  message.locals = object.locals?.map((e) => LocalEntry.fromPartial(e)) || [];
6268
+ message.scope = object.scope ?? "";
6400
6269
  return message;
6401
6270
  }
6402
6271
  };
6403
6272
  function createBaseLocalEntry() {
6404
- return { name: "", mode: "", value: void 0, variable: "", expression: "" };
6273
+ return { name: "", value: "" };
6405
6274
  }
6406
6275
  var LocalEntry = {
6407
6276
  encode(message, writer = new import_wire4.BinaryWriter()) {
6408
6277
  if (message.name !== "") {
6409
6278
  writer.uint32(10).string(message.name);
6410
6279
  }
6411
- if (message.mode !== "") {
6412
- writer.uint32(18).string(message.mode);
6280
+ if (message.value !== "") {
6281
+ writer.uint32(50).string(message.value);
6413
6282
  }
6414
- if (message.value !== void 0) {
6415
- Value.encode(Value.wrap(message.value), writer.uint32(26).fork()).join();
6283
+ return writer;
6284
+ },
6285
+ decode(input, length) {
6286
+ const reader = input instanceof import_wire4.BinaryReader ? input : new import_wire4.BinaryReader(input);
6287
+ const end = length === void 0 ? reader.len : reader.pos + length;
6288
+ const message = createBaseLocalEntry();
6289
+ while (reader.pos < end) {
6290
+ const tag = reader.uint32();
6291
+ switch (tag >>> 3) {
6292
+ case 1: {
6293
+ if (tag !== 10) {
6294
+ break;
6295
+ }
6296
+ message.name = reader.string();
6297
+ continue;
6298
+ }
6299
+ case 6: {
6300
+ if (tag !== 50) {
6301
+ break;
6302
+ }
6303
+ message.value = reader.string();
6304
+ continue;
6305
+ }
6306
+ }
6307
+ if ((tag & 7) === 4 || tag === 0) {
6308
+ break;
6309
+ }
6310
+ reader.skip(tag & 7);
6416
6311
  }
6417
- if (message.variable !== "") {
6418
- writer.uint32(34).string(message.variable);
6312
+ return message;
6313
+ },
6314
+ fromJSON(object) {
6315
+ return {
6316
+ name: isSet3(object.name) ? globalThis.String(object.name) : "",
6317
+ value: isSet3(object.value) ? globalThis.String(object.value) : ""
6318
+ };
6319
+ },
6320
+ toJSON(message) {
6321
+ const obj = {};
6322
+ if (message.name !== "") {
6323
+ obj.name = message.name;
6419
6324
  }
6420
- if (message.expression !== "") {
6421
- writer.uint32(42).string(message.expression);
6325
+ if (message.value !== "") {
6326
+ obj.value = message.value;
6327
+ }
6328
+ return obj;
6329
+ },
6330
+ create(base) {
6331
+ return LocalEntry.fromPartial(base ?? {});
6332
+ },
6333
+ fromPartial(object) {
6334
+ const message = createBaseLocalEntry();
6335
+ message.name = object.name ?? "";
6336
+ message.value = object.value ?? "";
6337
+ return message;
6338
+ }
6339
+ };
6340
+ function createBaseSetDirectivesAction() {
6341
+ return { blocks: [], scope: "" };
6342
+ }
6343
+ var SetDirectivesAction = {
6344
+ encode(message, writer = new import_wire4.BinaryWriter()) {
6345
+ for (const v of message.blocks) {
6346
+ BlockView.encode(v, writer.uint32(10).fork()).join();
6347
+ }
6348
+ if (message.scope !== "") {
6349
+ writer.uint32(18).string(message.scope);
6422
6350
  }
6423
6351
  return writer;
6424
6352
  },
6425
6353
  decode(input, length) {
6426
6354
  const reader = input instanceof import_wire4.BinaryReader ? input : new import_wire4.BinaryReader(input);
6427
6355
  const end = length === void 0 ? reader.len : reader.pos + length;
6428
- const message = createBaseLocalEntry();
6356
+ const message = createBaseSetDirectivesAction();
6429
6357
  while (reader.pos < end) {
6430
6358
  const tag = reader.uint32();
6431
6359
  switch (tag >>> 3) {
@@ -6433,35 +6361,195 @@ var LocalEntry = {
6433
6361
  if (tag !== 10) {
6434
6362
  break;
6435
6363
  }
6436
- message.name = reader.string();
6364
+ message.blocks.push(BlockView.decode(reader, reader.uint32()));
6437
6365
  continue;
6438
6366
  }
6439
6367
  case 2: {
6440
6368
  if (tag !== 18) {
6441
6369
  break;
6442
6370
  }
6443
- message.mode = reader.string();
6371
+ message.scope = reader.string();
6372
+ continue;
6373
+ }
6374
+ }
6375
+ if ((tag & 7) === 4 || tag === 0) {
6376
+ break;
6377
+ }
6378
+ reader.skip(tag & 7);
6379
+ }
6380
+ return message;
6381
+ },
6382
+ fromJSON(object) {
6383
+ return {
6384
+ blocks: globalThis.Array.isArray(object?.blocks) ? object.blocks.map((e) => BlockView.fromJSON(e)) : [],
6385
+ scope: isSet3(object.scope) ? globalThis.String(object.scope) : ""
6386
+ };
6387
+ },
6388
+ toJSON(message) {
6389
+ const obj = {};
6390
+ if (message.blocks?.length) {
6391
+ obj.blocks = message.blocks.map((e) => BlockView.toJSON(e));
6392
+ }
6393
+ if (message.scope !== "") {
6394
+ obj.scope = message.scope;
6395
+ }
6396
+ return obj;
6397
+ },
6398
+ create(base) {
6399
+ return SetDirectivesAction.fromPartial(base ?? {});
6400
+ },
6401
+ fromPartial(object) {
6402
+ const message = createBaseSetDirectivesAction();
6403
+ message.blocks = object.blocks?.map((e) => BlockView.fromPartial(e)) || [];
6404
+ message.scope = object.scope ?? "";
6405
+ return message;
6406
+ }
6407
+ };
6408
+ function createBaseSetBlocksAction() {
6409
+ return { instance_id: "", blocks: [], scope: "" };
6410
+ }
6411
+ var SetBlocksAction = {
6412
+ encode(message, writer = new import_wire4.BinaryWriter()) {
6413
+ if (message.instance_id !== "") {
6414
+ writer.uint32(10).string(message.instance_id);
6415
+ }
6416
+ for (const v of message.blocks) {
6417
+ BlockView.encode(v, writer.uint32(18).fork()).join();
6418
+ }
6419
+ if (message.scope !== "") {
6420
+ writer.uint32(26).string(message.scope);
6421
+ }
6422
+ return writer;
6423
+ },
6424
+ decode(input, length) {
6425
+ const reader = input instanceof import_wire4.BinaryReader ? input : new import_wire4.BinaryReader(input);
6426
+ const end = length === void 0 ? reader.len : reader.pos + length;
6427
+ const message = createBaseSetBlocksAction();
6428
+ while (reader.pos < end) {
6429
+ const tag = reader.uint32();
6430
+ switch (tag >>> 3) {
6431
+ case 1: {
6432
+ if (tag !== 10) {
6433
+ break;
6434
+ }
6435
+ message.instance_id = reader.string();
6436
+ continue;
6437
+ }
6438
+ case 2: {
6439
+ if (tag !== 18) {
6440
+ break;
6441
+ }
6442
+ message.blocks.push(BlockView.decode(reader, reader.uint32()));
6444
6443
  continue;
6445
6444
  }
6446
6445
  case 3: {
6447
6446
  if (tag !== 26) {
6448
6447
  break;
6449
6448
  }
6450
- message.value = Value.unwrap(Value.decode(reader, reader.uint32()));
6449
+ message.scope = reader.string();
6450
+ continue;
6451
+ }
6452
+ }
6453
+ if ((tag & 7) === 4 || tag === 0) {
6454
+ break;
6455
+ }
6456
+ reader.skip(tag & 7);
6457
+ }
6458
+ return message;
6459
+ },
6460
+ fromJSON(object) {
6461
+ return {
6462
+ instance_id: isSet3(object.instanceId) ? globalThis.String(object.instanceId) : isSet3(object.instance_id) ? globalThis.String(object.instance_id) : "",
6463
+ blocks: globalThis.Array.isArray(object?.blocks) ? object.blocks.map((e) => BlockView.fromJSON(e)) : [],
6464
+ scope: isSet3(object.scope) ? globalThis.String(object.scope) : ""
6465
+ };
6466
+ },
6467
+ toJSON(message) {
6468
+ const obj = {};
6469
+ if (message.instance_id !== "") {
6470
+ obj.instanceId = message.instance_id;
6471
+ }
6472
+ if (message.blocks?.length) {
6473
+ obj.blocks = message.blocks.map((e) => BlockView.toJSON(e));
6474
+ }
6475
+ if (message.scope !== "") {
6476
+ obj.scope = message.scope;
6477
+ }
6478
+ return obj;
6479
+ },
6480
+ create(base) {
6481
+ return SetBlocksAction.fromPartial(base ?? {});
6482
+ },
6483
+ fromPartial(object) {
6484
+ const message = createBaseSetBlocksAction();
6485
+ message.instance_id = object.instance_id ?? "";
6486
+ message.blocks = object.blocks?.map((e) => BlockView.fromPartial(e)) || [];
6487
+ message.scope = object.scope ?? "";
6488
+ return message;
6489
+ }
6490
+ };
6491
+ function createBaseSetMetaArgumentsAction() {
6492
+ return { instance_id: "", count: "", for_each: "", provider: "", scope: "" };
6493
+ }
6494
+ var SetMetaArgumentsAction = {
6495
+ encode(message, writer = new import_wire4.BinaryWriter()) {
6496
+ if (message.instance_id !== "") {
6497
+ writer.uint32(10).string(message.instance_id);
6498
+ }
6499
+ if (message.count !== "") {
6500
+ writer.uint32(18).string(message.count);
6501
+ }
6502
+ if (message.for_each !== "") {
6503
+ writer.uint32(26).string(message.for_each);
6504
+ }
6505
+ if (message.provider !== "") {
6506
+ writer.uint32(34).string(message.provider);
6507
+ }
6508
+ if (message.scope !== "") {
6509
+ writer.uint32(42).string(message.scope);
6510
+ }
6511
+ return writer;
6512
+ },
6513
+ decode(input, length) {
6514
+ const reader = input instanceof import_wire4.BinaryReader ? input : new import_wire4.BinaryReader(input);
6515
+ const end = length === void 0 ? reader.len : reader.pos + length;
6516
+ const message = createBaseSetMetaArgumentsAction();
6517
+ while (reader.pos < end) {
6518
+ const tag = reader.uint32();
6519
+ switch (tag >>> 3) {
6520
+ case 1: {
6521
+ if (tag !== 10) {
6522
+ break;
6523
+ }
6524
+ message.instance_id = reader.string();
6525
+ continue;
6526
+ }
6527
+ case 2: {
6528
+ if (tag !== 18) {
6529
+ break;
6530
+ }
6531
+ message.count = reader.string();
6532
+ continue;
6533
+ }
6534
+ case 3: {
6535
+ if (tag !== 26) {
6536
+ break;
6537
+ }
6538
+ message.for_each = reader.string();
6451
6539
  continue;
6452
6540
  }
6453
6541
  case 4: {
6454
6542
  if (tag !== 34) {
6455
6543
  break;
6456
6544
  }
6457
- message.variable = reader.string();
6545
+ message.provider = reader.string();
6458
6546
  continue;
6459
6547
  }
6460
6548
  case 5: {
6461
6549
  if (tag !== 42) {
6462
6550
  break;
6463
6551
  }
6464
- message.expression = reader.string();
6552
+ message.scope = reader.string();
6465
6553
  continue;
6466
6554
  }
6467
6555
  }
@@ -6474,42 +6562,140 @@ var LocalEntry = {
6474
6562
  },
6475
6563
  fromJSON(object) {
6476
6564
  return {
6477
- name: isSet3(object.name) ? globalThis.String(object.name) : "",
6478
- mode: isSet3(object.mode) ? globalThis.String(object.mode) : "",
6479
- value: isSet3(object?.value) ? object.value : void 0,
6480
- variable: isSet3(object.variable) ? globalThis.String(object.variable) : "",
6481
- expression: isSet3(object.expression) ? globalThis.String(object.expression) : ""
6565
+ instance_id: isSet3(object.instanceId) ? globalThis.String(object.instanceId) : isSet3(object.instance_id) ? globalThis.String(object.instance_id) : "",
6566
+ count: isSet3(object.count) ? globalThis.String(object.count) : "",
6567
+ for_each: isSet3(object.forEach) ? globalThis.String(object.forEach) : isSet3(object.for_each) ? globalThis.String(object.for_each) : "",
6568
+ provider: isSet3(object.provider) ? globalThis.String(object.provider) : "",
6569
+ scope: isSet3(object.scope) ? globalThis.String(object.scope) : ""
6482
6570
  };
6483
6571
  },
6484
6572
  toJSON(message) {
6485
6573
  const obj = {};
6574
+ if (message.instance_id !== "") {
6575
+ obj.instanceId = message.instance_id;
6576
+ }
6577
+ if (message.count !== "") {
6578
+ obj.count = message.count;
6579
+ }
6580
+ if (message.for_each !== "") {
6581
+ obj.forEach = message.for_each;
6582
+ }
6583
+ if (message.provider !== "") {
6584
+ obj.provider = message.provider;
6585
+ }
6586
+ if (message.scope !== "") {
6587
+ obj.scope = message.scope;
6588
+ }
6589
+ return obj;
6590
+ },
6591
+ create(base) {
6592
+ return SetMetaArgumentsAction.fromPartial(base ?? {});
6593
+ },
6594
+ fromPartial(object) {
6595
+ const message = createBaseSetMetaArgumentsAction();
6596
+ message.instance_id = object.instance_id ?? "";
6597
+ message.count = object.count ?? "";
6598
+ message.for_each = object.for_each ?? "";
6599
+ message.provider = object.provider ?? "";
6600
+ message.scope = object.scope ?? "";
6601
+ return message;
6602
+ }
6603
+ };
6604
+ function createBaseAddResourceAction() {
6605
+ return { kind: "", type: "", name: "", scope: "" };
6606
+ }
6607
+ var AddResourceAction = {
6608
+ encode(message, writer = new import_wire4.BinaryWriter()) {
6609
+ if (message.kind !== "") {
6610
+ writer.uint32(10).string(message.kind);
6611
+ }
6612
+ if (message.type !== "") {
6613
+ writer.uint32(18).string(message.type);
6614
+ }
6486
6615
  if (message.name !== "") {
6487
- obj.name = message.name;
6616
+ writer.uint32(26).string(message.name);
6488
6617
  }
6489
- if (message.mode !== "") {
6490
- obj.mode = message.mode;
6618
+ if (message.scope !== "") {
6619
+ writer.uint32(34).string(message.scope);
6491
6620
  }
6492
- if (message.value !== void 0) {
6493
- obj.value = message.value;
6621
+ return writer;
6622
+ },
6623
+ decode(input, length) {
6624
+ const reader = input instanceof import_wire4.BinaryReader ? input : new import_wire4.BinaryReader(input);
6625
+ const end = length === void 0 ? reader.len : reader.pos + length;
6626
+ const message = createBaseAddResourceAction();
6627
+ while (reader.pos < end) {
6628
+ const tag = reader.uint32();
6629
+ switch (tag >>> 3) {
6630
+ case 1: {
6631
+ if (tag !== 10) {
6632
+ break;
6633
+ }
6634
+ message.kind = reader.string();
6635
+ continue;
6636
+ }
6637
+ case 2: {
6638
+ if (tag !== 18) {
6639
+ break;
6640
+ }
6641
+ message.type = reader.string();
6642
+ continue;
6643
+ }
6644
+ case 3: {
6645
+ if (tag !== 26) {
6646
+ break;
6647
+ }
6648
+ message.name = reader.string();
6649
+ continue;
6650
+ }
6651
+ case 4: {
6652
+ if (tag !== 34) {
6653
+ break;
6654
+ }
6655
+ message.scope = reader.string();
6656
+ continue;
6657
+ }
6658
+ }
6659
+ if ((tag & 7) === 4 || tag === 0) {
6660
+ break;
6661
+ }
6662
+ reader.skip(tag & 7);
6494
6663
  }
6495
- if (message.variable !== "") {
6496
- obj.variable = message.variable;
6664
+ return message;
6665
+ },
6666
+ fromJSON(object) {
6667
+ return {
6668
+ kind: isSet3(object.kind) ? globalThis.String(object.kind) : "",
6669
+ type: isSet3(object.type) ? globalThis.String(object.type) : "",
6670
+ name: isSet3(object.name) ? globalThis.String(object.name) : "",
6671
+ scope: isSet3(object.scope) ? globalThis.String(object.scope) : ""
6672
+ };
6673
+ },
6674
+ toJSON(message) {
6675
+ const obj = {};
6676
+ if (message.kind !== "") {
6677
+ obj.kind = message.kind;
6497
6678
  }
6498
- if (message.expression !== "") {
6499
- obj.expression = message.expression;
6679
+ if (message.type !== "") {
6680
+ obj.type = message.type;
6681
+ }
6682
+ if (message.name !== "") {
6683
+ obj.name = message.name;
6684
+ }
6685
+ if (message.scope !== "") {
6686
+ obj.scope = message.scope;
6500
6687
  }
6501
6688
  return obj;
6502
6689
  },
6503
6690
  create(base) {
6504
- return LocalEntry.fromPartial(base ?? {});
6691
+ return AddResourceAction.fromPartial(base ?? {});
6505
6692
  },
6506
6693
  fromPartial(object) {
6507
- const message = createBaseLocalEntry();
6694
+ const message = createBaseAddResourceAction();
6695
+ message.kind = object.kind ?? "";
6696
+ message.type = object.type ?? "";
6508
6697
  message.name = object.name ?? "";
6509
- message.mode = object.mode ?? "";
6510
- message.value = object.value ?? void 0;
6511
- message.variable = object.variable ?? "";
6512
- message.expression = object.expression ?? "";
6698
+ message.scope = object.scope ?? "";
6513
6699
  return message;
6514
6700
  }
6515
6701
  };
@@ -6948,7 +7134,11 @@ function createBaseAction() {
6948
7134
  redo: void 0,
6949
7135
  place_module: void 0,
6950
7136
  set_use_providers: void 0,
6951
- ungroup: void 0
7137
+ ungroup: void 0,
7138
+ set_blocks: void 0,
7139
+ set_directives: void 0,
7140
+ set_meta_arguments: void 0,
7141
+ add_resource: void 0
6952
7142
  };
6953
7143
  }
6954
7144
  var Action = {
@@ -7013,6 +7203,18 @@ var Action = {
7013
7203
  if (message.ungroup !== void 0) {
7014
7204
  UngroupAction.encode(message.ungroup, writer.uint32(194).fork()).join();
7015
7205
  }
7206
+ if (message.set_blocks !== void 0) {
7207
+ SetBlocksAction.encode(message.set_blocks, writer.uint32(202).fork()).join();
7208
+ }
7209
+ if (message.set_directives !== void 0) {
7210
+ SetDirectivesAction.encode(message.set_directives, writer.uint32(210).fork()).join();
7211
+ }
7212
+ if (message.set_meta_arguments !== void 0) {
7213
+ SetMetaArgumentsAction.encode(message.set_meta_arguments, writer.uint32(218).fork()).join();
7214
+ }
7215
+ if (message.add_resource !== void 0) {
7216
+ AddResourceAction.encode(message.add_resource, writer.uint32(226).fork()).join();
7217
+ }
7016
7218
  return writer;
7017
7219
  },
7018
7220
  decode(input, length) {
@@ -7162,6 +7364,34 @@ var Action = {
7162
7364
  message.ungroup = UngroupAction.decode(reader, reader.uint32());
7163
7365
  continue;
7164
7366
  }
7367
+ case 25: {
7368
+ if (tag !== 202) {
7369
+ break;
7370
+ }
7371
+ message.set_blocks = SetBlocksAction.decode(reader, reader.uint32());
7372
+ continue;
7373
+ }
7374
+ case 26: {
7375
+ if (tag !== 210) {
7376
+ break;
7377
+ }
7378
+ message.set_directives = SetDirectivesAction.decode(reader, reader.uint32());
7379
+ continue;
7380
+ }
7381
+ case 27: {
7382
+ if (tag !== 218) {
7383
+ break;
7384
+ }
7385
+ message.set_meta_arguments = SetMetaArgumentsAction.decode(reader, reader.uint32());
7386
+ continue;
7387
+ }
7388
+ case 28: {
7389
+ if (tag !== 226) {
7390
+ break;
7391
+ }
7392
+ message.add_resource = AddResourceAction.decode(reader, reader.uint32());
7393
+ continue;
7394
+ }
7165
7395
  }
7166
7396
  if ((tag & 7) === 4 || tag === 0) {
7167
7397
  break;
@@ -7191,7 +7421,11 @@ var Action = {
7191
7421
  redo: isSet3(object.redo) ? RedoAction.fromJSON(object.redo) : void 0,
7192
7422
  place_module: isSet3(object.placeModule) ? PlaceModuleAction.fromJSON(object.placeModule) : isSet3(object.place_module) ? PlaceModuleAction.fromJSON(object.place_module) : void 0,
7193
7423
  set_use_providers: isSet3(object.setUseProviders) ? SetUseProvidersAction.fromJSON(object.setUseProviders) : isSet3(object.set_use_providers) ? SetUseProvidersAction.fromJSON(object.set_use_providers) : void 0,
7194
- ungroup: isSet3(object.ungroup) ? UngroupAction.fromJSON(object.ungroup) : void 0
7424
+ ungroup: isSet3(object.ungroup) ? UngroupAction.fromJSON(object.ungroup) : void 0,
7425
+ set_blocks: isSet3(object.setBlocks) ? SetBlocksAction.fromJSON(object.setBlocks) : isSet3(object.set_blocks) ? SetBlocksAction.fromJSON(object.set_blocks) : void 0,
7426
+ set_directives: isSet3(object.setDirectives) ? SetDirectivesAction.fromJSON(object.setDirectives) : isSet3(object.set_directives) ? SetDirectivesAction.fromJSON(object.set_directives) : void 0,
7427
+ set_meta_arguments: isSet3(object.setMetaArguments) ? SetMetaArgumentsAction.fromJSON(object.setMetaArguments) : isSet3(object.set_meta_arguments) ? SetMetaArgumentsAction.fromJSON(object.set_meta_arguments) : void 0,
7428
+ add_resource: isSet3(object.addResource) ? AddResourceAction.fromJSON(object.addResource) : isSet3(object.add_resource) ? AddResourceAction.fromJSON(object.add_resource) : void 0
7195
7429
  };
7196
7430
  },
7197
7431
  toJSON(message) {
@@ -7256,6 +7490,18 @@ var Action = {
7256
7490
  if (message.ungroup !== void 0) {
7257
7491
  obj.ungroup = UngroupAction.toJSON(message.ungroup);
7258
7492
  }
7493
+ if (message.set_blocks !== void 0) {
7494
+ obj.setBlocks = SetBlocksAction.toJSON(message.set_blocks);
7495
+ }
7496
+ if (message.set_directives !== void 0) {
7497
+ obj.setDirectives = SetDirectivesAction.toJSON(message.set_directives);
7498
+ }
7499
+ if (message.set_meta_arguments !== void 0) {
7500
+ obj.setMetaArguments = SetMetaArgumentsAction.toJSON(message.set_meta_arguments);
7501
+ }
7502
+ if (message.add_resource !== void 0) {
7503
+ obj.addResource = AddResourceAction.toJSON(message.add_resource);
7504
+ }
7259
7505
  return obj;
7260
7506
  },
7261
7507
  create(base) {
@@ -7283,6 +7529,10 @@ var Action = {
7283
7529
  message.place_module = object.place_module !== void 0 && object.place_module !== null ? PlaceModuleAction.fromPartial(object.place_module) : void 0;
7284
7530
  message.set_use_providers = object.set_use_providers !== void 0 && object.set_use_providers !== null ? SetUseProvidersAction.fromPartial(object.set_use_providers) : void 0;
7285
7531
  message.ungroup = object.ungroup !== void 0 && object.ungroup !== null ? UngroupAction.fromPartial(object.ungroup) : void 0;
7532
+ message.set_blocks = object.set_blocks !== void 0 && object.set_blocks !== null ? SetBlocksAction.fromPartial(object.set_blocks) : void 0;
7533
+ message.set_directives = object.set_directives !== void 0 && object.set_directives !== null ? SetDirectivesAction.fromPartial(object.set_directives) : void 0;
7534
+ message.set_meta_arguments = object.set_meta_arguments !== void 0 && object.set_meta_arguments !== null ? SetMetaArgumentsAction.fromPartial(object.set_meta_arguments) : void 0;
7535
+ message.add_resource = object.add_resource !== void 0 && object.add_resource !== null ? AddResourceAction.fromPartial(object.add_resource) : void 0;
7286
7536
  return message;
7287
7537
  }
7288
7538
  };
@@ -7634,7 +7884,7 @@ var ReadWiringCandidatesResponse = {
7634
7884
  }
7635
7885
  };
7636
7886
  function createBaseInvokeRequest() {
7637
- return { invoke_id: "", path: [], argv: [], working_directory: "" };
7887
+ return { invoke_id: "", path: [], argv: [], working_directory: "", stdin: new Uint8Array(0) };
7638
7888
  }
7639
7889
  var InvokeRequest = {
7640
7890
  encode(message, writer = new import_wire4.BinaryWriter()) {
@@ -7650,6 +7900,9 @@ var InvokeRequest = {
7650
7900
  if (message.working_directory !== "") {
7651
7901
  writer.uint32(42).string(message.working_directory);
7652
7902
  }
7903
+ if (message.stdin.length !== 0) {
7904
+ writer.uint32(50).bytes(message.stdin);
7905
+ }
7653
7906
  return writer;
7654
7907
  },
7655
7908
  decode(input, length) {
@@ -7687,6 +7940,13 @@ var InvokeRequest = {
7687
7940
  message.working_directory = reader.string();
7688
7941
  continue;
7689
7942
  }
7943
+ case 6: {
7944
+ if (tag !== 50) {
7945
+ break;
7946
+ }
7947
+ message.stdin = reader.bytes();
7948
+ continue;
7949
+ }
7690
7950
  }
7691
7951
  if ((tag & 7) === 4 || tag === 0) {
7692
7952
  break;
@@ -7700,7 +7960,8 @@ var InvokeRequest = {
7700
7960
  invoke_id: isSet3(object.invokeId) ? globalThis.String(object.invokeId) : isSet3(object.invoke_id) ? globalThis.String(object.invoke_id) : "",
7701
7961
  path: globalThis.Array.isArray(object?.path) ? object.path.map((e) => globalThis.String(e)) : [],
7702
7962
  argv: globalThis.Array.isArray(object?.argv) ? object.argv.map((e) => globalThis.String(e)) : [],
7703
- working_directory: isSet3(object.workingDirectory) ? globalThis.String(object.workingDirectory) : isSet3(object.working_directory) ? globalThis.String(object.working_directory) : ""
7963
+ working_directory: isSet3(object.workingDirectory) ? globalThis.String(object.workingDirectory) : isSet3(object.working_directory) ? globalThis.String(object.working_directory) : "",
7964
+ stdin: isSet3(object.stdin) ? bytesFromBase64(object.stdin) : new Uint8Array(0)
7704
7965
  };
7705
7966
  },
7706
7967
  toJSON(message) {
@@ -7717,6 +7978,9 @@ var InvokeRequest = {
7717
7978
  if (message.working_directory !== "") {
7718
7979
  obj.workingDirectory = message.working_directory;
7719
7980
  }
7981
+ if (message.stdin.length !== 0) {
7982
+ obj.stdin = base64FromBytes(message.stdin);
7983
+ }
7720
7984
  return obj;
7721
7985
  },
7722
7986
  create(base) {
@@ -7728,6 +7992,7 @@ var InvokeRequest = {
7728
7992
  message.path = object.path?.map((e) => e) || [];
7729
7993
  message.argv = object.argv?.map((e) => e) || [];
7730
7994
  message.working_directory = object.working_directory ?? "";
7995
+ message.stdin = object.stdin ?? new Uint8Array(0);
7731
7996
  return message;
7732
7997
  }
7733
7998
  };
@@ -9225,25 +9490,29 @@ var ProviderReqView = {
9225
9490
  return message;
9226
9491
  }
9227
9492
  };
9228
- function createBaseBackendView() {
9229
- return { type: "", config: {} };
9493
+ function createBaseProviderView() {
9494
+ return { name: "", alias: "", config: {}, blocks: [] };
9230
9495
  }
9231
- var BackendView = {
9496
+ var ProviderView = {
9232
9497
  encode(message, writer = new import_wire4.BinaryWriter()) {
9233
- if (message.type !== "") {
9234
- writer.uint32(10).string(message.type);
9498
+ if (message.name !== "") {
9499
+ writer.uint32(10).string(message.name);
9500
+ }
9501
+ if (message.alias !== "") {
9502
+ writer.uint32(18).string(message.alias);
9235
9503
  }
9236
9504
  globalThis.Object.entries(message.config).forEach(([key, value]) => {
9237
- if (value !== void 0) {
9238
- BackendView_ConfigEntry.encode({ key, value }, writer.uint32(18).fork()).join();
9239
- }
9505
+ ProviderView_ConfigEntry.encode({ key, value }, writer.uint32(26).fork()).join();
9240
9506
  });
9507
+ for (const v of message.blocks) {
9508
+ BlockView.encode(v, writer.uint32(42).fork()).join();
9509
+ }
9241
9510
  return writer;
9242
9511
  },
9243
9512
  decode(input, length) {
9244
9513
  const reader = input instanceof import_wire4.BinaryReader ? input : new import_wire4.BinaryReader(input);
9245
9514
  const end = length === void 0 ? reader.len : reader.pos + length;
9246
- const message = createBaseBackendView();
9515
+ const message = createBaseProviderView();
9247
9516
  while (reader.pos < end) {
9248
9517
  const tag = reader.uint32();
9249
9518
  switch (tag >>> 3) {
@@ -9251,17 +9520,31 @@ var BackendView = {
9251
9520
  if (tag !== 10) {
9252
9521
  break;
9253
9522
  }
9254
- message.type = reader.string();
9523
+ message.name = reader.string();
9524
+ continue;
9525
+ }
9526
+ case 2: {
9527
+ if (tag !== 18) {
9528
+ break;
9529
+ }
9530
+ message.alias = reader.string();
9531
+ continue;
9532
+ }
9533
+ case 3: {
9534
+ if (tag !== 26) {
9535
+ break;
9536
+ }
9537
+ const entry3 = ProviderView_ConfigEntry.decode(reader, reader.uint32());
9538
+ if (entry3.value !== void 0) {
9539
+ message.config[entry3.key] = entry3.value;
9540
+ }
9255
9541
  continue;
9256
9542
  }
9257
- case 2: {
9258
- if (tag !== 18) {
9543
+ case 5: {
9544
+ if (tag !== 42) {
9259
9545
  break;
9260
9546
  }
9261
- const entry2 = BackendView_ConfigEntry.decode(reader, reader.uint32());
9262
- if (entry2.value !== void 0) {
9263
- message.config[entry2.key] = entry2.value;
9264
- }
9547
+ message.blocks.push(BlockView.decode(reader, reader.uint32()));
9265
9548
  continue;
9266
9549
  }
9267
9550
  }
@@ -9274,20 +9557,25 @@ var BackendView = {
9274
9557
  },
9275
9558
  fromJSON(object) {
9276
9559
  return {
9277
- type: isSet3(object.type) ? globalThis.String(object.type) : "",
9560
+ name: isSet3(object.name) ? globalThis.String(object.name) : "",
9561
+ alias: isSet3(object.alias) ? globalThis.String(object.alias) : "",
9278
9562
  config: isObject3(object.config) ? globalThis.Object.entries(object.config).reduce(
9279
9563
  (acc, [key, value]) => {
9280
- acc[key] = value;
9564
+ acc[key] = globalThis.String(value);
9281
9565
  return acc;
9282
9566
  },
9283
9567
  {}
9284
- ) : {}
9568
+ ) : {},
9569
+ blocks: globalThis.Array.isArray(object?.blocks) ? object.blocks.map((e) => BlockView.fromJSON(e)) : []
9285
9570
  };
9286
9571
  },
9287
9572
  toJSON(message) {
9288
9573
  const obj = {};
9289
- if (message.type !== "") {
9290
- obj.type = message.type;
9574
+ if (message.name !== "") {
9575
+ obj.name = message.name;
9576
+ }
9577
+ if (message.alias !== "") {
9578
+ obj.alias = message.alias;
9291
9579
  }
9292
9580
  if (message.config) {
9293
9581
  const entries = globalThis.Object.entries(message.config);
@@ -9298,43 +9586,48 @@ var BackendView = {
9298
9586
  });
9299
9587
  }
9300
9588
  }
9589
+ if (message.blocks?.length) {
9590
+ obj.blocks = message.blocks.map((e) => BlockView.toJSON(e));
9591
+ }
9301
9592
  return obj;
9302
9593
  },
9303
9594
  create(base) {
9304
- return BackendView.fromPartial(base ?? {});
9595
+ return ProviderView.fromPartial(base ?? {});
9305
9596
  },
9306
9597
  fromPartial(object) {
9307
- const message = createBaseBackendView();
9308
- message.type = object.type ?? "";
9598
+ const message = createBaseProviderView();
9599
+ message.name = object.name ?? "";
9600
+ message.alias = object.alias ?? "";
9309
9601
  message.config = globalThis.Object.entries(object.config ?? {}).reduce(
9310
9602
  (acc, [key, value]) => {
9311
9603
  if (value !== void 0) {
9312
- acc[key] = value;
9604
+ acc[key] = globalThis.String(value);
9313
9605
  }
9314
9606
  return acc;
9315
9607
  },
9316
9608
  {}
9317
9609
  );
9610
+ message.blocks = object.blocks?.map((e) => BlockView.fromPartial(e)) || [];
9318
9611
  return message;
9319
9612
  }
9320
9613
  };
9321
- function createBaseBackendView_ConfigEntry() {
9322
- return { key: "", value: void 0 };
9614
+ function createBaseProviderView_ConfigEntry() {
9615
+ return { key: "", value: "" };
9323
9616
  }
9324
- var BackendView_ConfigEntry = {
9617
+ var ProviderView_ConfigEntry = {
9325
9618
  encode(message, writer = new import_wire4.BinaryWriter()) {
9326
9619
  if (message.key !== "") {
9327
9620
  writer.uint32(10).string(message.key);
9328
9621
  }
9329
- if (message.value !== void 0) {
9330
- Value.encode(Value.wrap(message.value), writer.uint32(18).fork()).join();
9622
+ if (message.value !== "") {
9623
+ writer.uint32(18).string(message.value);
9331
9624
  }
9332
9625
  return writer;
9333
9626
  },
9334
9627
  decode(input, length) {
9335
9628
  const reader = input instanceof import_wire4.BinaryReader ? input : new import_wire4.BinaryReader(input);
9336
9629
  const end = length === void 0 ? reader.len : reader.pos + length;
9337
- const message = createBaseBackendView_ConfigEntry();
9630
+ const message = createBaseProviderView_ConfigEntry();
9338
9631
  while (reader.pos < end) {
9339
9632
  const tag = reader.uint32();
9340
9633
  switch (tag >>> 3) {
@@ -9349,7 +9642,7 @@ var BackendView_ConfigEntry = {
9349
9642
  if (tag !== 18) {
9350
9643
  break;
9351
9644
  }
9352
- message.value = Value.unwrap(Value.decode(reader, reader.uint32()));
9645
+ message.value = reader.string();
9353
9646
  continue;
9354
9647
  }
9355
9648
  }
@@ -9363,7 +9656,7 @@ var BackendView_ConfigEntry = {
9363
9656
  fromJSON(object) {
9364
9657
  return {
9365
9658
  key: isSet3(object.key) ? globalThis.String(object.key) : "",
9366
- value: isSet3(object?.value) ? object.value : void 0
9659
+ value: isSet3(object.value) ? globalThis.String(object.value) : ""
9367
9660
  };
9368
9661
  },
9369
9662
  toJSON(message) {
@@ -9371,44 +9664,44 @@ var BackendView_ConfigEntry = {
9371
9664
  if (message.key !== "") {
9372
9665
  obj.key = message.key;
9373
9666
  }
9374
- if (message.value !== void 0) {
9667
+ if (message.value !== "") {
9375
9668
  obj.value = message.value;
9376
9669
  }
9377
9670
  return obj;
9378
9671
  },
9379
9672
  create(base) {
9380
- return BackendView_ConfigEntry.fromPartial(base ?? {});
9673
+ return ProviderView_ConfigEntry.fromPartial(base ?? {});
9381
9674
  },
9382
9675
  fromPartial(object) {
9383
- const message = createBaseBackendView_ConfigEntry();
9676
+ const message = createBaseProviderView_ConfigEntry();
9384
9677
  message.key = object.key ?? "";
9385
- message.value = object.value ?? void 0;
9678
+ message.value = object.value ?? "";
9386
9679
  return message;
9387
9680
  }
9388
9681
  };
9389
- function createBaseProviderView() {
9390
- return { name: "", alias: "", config: {}, blocks: [] };
9682
+ function createBaseBlockView() {
9683
+ return { type: "", labels: [], attributes: [], blocks: [] };
9391
9684
  }
9392
- var ProviderView = {
9685
+ var BlockView = {
9393
9686
  encode(message, writer = new import_wire4.BinaryWriter()) {
9394
- if (message.name !== "") {
9395
- writer.uint32(10).string(message.name);
9687
+ if (message.type !== "") {
9688
+ writer.uint32(10).string(message.type);
9396
9689
  }
9397
- if (message.alias !== "") {
9398
- writer.uint32(18).string(message.alias);
9690
+ for (const v of message.labels) {
9691
+ writer.uint32(18).string(v);
9692
+ }
9693
+ for (const v of message.attributes) {
9694
+ AttributeView.encode(v, writer.uint32(26).fork()).join();
9399
9695
  }
9400
- globalThis.Object.entries(message.config).forEach(([key, value]) => {
9401
- ProviderView_ConfigEntry.encode({ key, value }, writer.uint32(26).fork()).join();
9402
- });
9403
9696
  for (const v of message.blocks) {
9404
- Block.encode(v, writer.uint32(34).fork()).join();
9697
+ BlockView.encode(v, writer.uint32(34).fork()).join();
9405
9698
  }
9406
9699
  return writer;
9407
9700
  },
9408
9701
  decode(input, length) {
9409
9702
  const reader = input instanceof import_wire4.BinaryReader ? input : new import_wire4.BinaryReader(input);
9410
9703
  const end = length === void 0 ? reader.len : reader.pos + length;
9411
- const message = createBaseProviderView();
9704
+ const message = createBaseBlockView();
9412
9705
  while (reader.pos < end) {
9413
9706
  const tag = reader.uint32();
9414
9707
  switch (tag >>> 3) {
@@ -9416,31 +9709,28 @@ var ProviderView = {
9416
9709
  if (tag !== 10) {
9417
9710
  break;
9418
9711
  }
9419
- message.name = reader.string();
9712
+ message.type = reader.string();
9420
9713
  continue;
9421
9714
  }
9422
9715
  case 2: {
9423
9716
  if (tag !== 18) {
9424
9717
  break;
9425
9718
  }
9426
- message.alias = reader.string();
9719
+ message.labels.push(reader.string());
9427
9720
  continue;
9428
9721
  }
9429
9722
  case 3: {
9430
9723
  if (tag !== 26) {
9431
9724
  break;
9432
9725
  }
9433
- const entry3 = ProviderView_ConfigEntry.decode(reader, reader.uint32());
9434
- if (entry3.value !== void 0) {
9435
- message.config[entry3.key] = entry3.value;
9436
- }
9726
+ message.attributes.push(AttributeView.decode(reader, reader.uint32()));
9437
9727
  continue;
9438
9728
  }
9439
9729
  case 4: {
9440
9730
  if (tag !== 34) {
9441
9731
  break;
9442
9732
  }
9443
- message.blocks.push(Block.decode(reader, reader.uint32()));
9733
+ message.blocks.push(BlockView.decode(reader, reader.uint32()));
9444
9734
  continue;
9445
9735
  }
9446
9736
  }
@@ -9453,67 +9743,47 @@ var ProviderView = {
9453
9743
  },
9454
9744
  fromJSON(object) {
9455
9745
  return {
9456
- name: isSet3(object.name) ? globalThis.String(object.name) : "",
9457
- alias: isSet3(object.alias) ? globalThis.String(object.alias) : "",
9458
- config: isObject3(object.config) ? globalThis.Object.entries(object.config).reduce(
9459
- (acc, [key, value]) => {
9460
- acc[key] = globalThis.String(value);
9461
- return acc;
9462
- },
9463
- {}
9464
- ) : {},
9465
- blocks: globalThis.Array.isArray(object?.blocks) ? object.blocks.map((e) => Block.fromJSON(e)) : []
9746
+ type: isSet3(object.type) ? globalThis.String(object.type) : "",
9747
+ labels: globalThis.Array.isArray(object?.labels) ? object.labels.map((e) => globalThis.String(e)) : [],
9748
+ attributes: globalThis.Array.isArray(object?.attributes) ? object.attributes.map((e) => AttributeView.fromJSON(e)) : [],
9749
+ blocks: globalThis.Array.isArray(object?.blocks) ? object.blocks.map((e) => BlockView.fromJSON(e)) : []
9466
9750
  };
9467
9751
  },
9468
9752
  toJSON(message) {
9469
9753
  const obj = {};
9470
- if (message.name !== "") {
9471
- obj.name = message.name;
9754
+ if (message.type !== "") {
9755
+ obj.type = message.type;
9472
9756
  }
9473
- if (message.alias !== "") {
9474
- obj.alias = message.alias;
9757
+ if (message.labels?.length) {
9758
+ obj.labels = message.labels;
9475
9759
  }
9476
- if (message.config) {
9477
- const entries = globalThis.Object.entries(message.config);
9478
- if (entries.length > 0) {
9479
- obj.config = {};
9480
- entries.forEach(([k, v]) => {
9481
- obj.config[k] = v;
9482
- });
9483
- }
9760
+ if (message.attributes?.length) {
9761
+ obj.attributes = message.attributes.map((e) => AttributeView.toJSON(e));
9484
9762
  }
9485
9763
  if (message.blocks?.length) {
9486
- obj.blocks = message.blocks.map((e) => Block.toJSON(e));
9764
+ obj.blocks = message.blocks.map((e) => BlockView.toJSON(e));
9487
9765
  }
9488
9766
  return obj;
9489
9767
  },
9490
9768
  create(base) {
9491
- return ProviderView.fromPartial(base ?? {});
9769
+ return BlockView.fromPartial(base ?? {});
9492
9770
  },
9493
9771
  fromPartial(object) {
9494
- const message = createBaseProviderView();
9495
- message.name = object.name ?? "";
9496
- message.alias = object.alias ?? "";
9497
- message.config = globalThis.Object.entries(object.config ?? {}).reduce(
9498
- (acc, [key, value]) => {
9499
- if (value !== void 0) {
9500
- acc[key] = globalThis.String(value);
9501
- }
9502
- return acc;
9503
- },
9504
- {}
9505
- );
9506
- message.blocks = object.blocks?.map((e) => Block.fromPartial(e)) || [];
9772
+ const message = createBaseBlockView();
9773
+ message.type = object.type ?? "";
9774
+ message.labels = object.labels?.map((e) => e) || [];
9775
+ message.attributes = object.attributes?.map((e) => AttributeView.fromPartial(e)) || [];
9776
+ message.blocks = object.blocks?.map((e) => BlockView.fromPartial(e)) || [];
9507
9777
  return message;
9508
9778
  }
9509
9779
  };
9510
- function createBaseProviderView_ConfigEntry() {
9511
- return { key: "", value: "" };
9780
+ function createBaseAttributeView() {
9781
+ return { name: "", value: "" };
9512
9782
  }
9513
- var ProviderView_ConfigEntry = {
9783
+ var AttributeView = {
9514
9784
  encode(message, writer = new import_wire4.BinaryWriter()) {
9515
- if (message.key !== "") {
9516
- writer.uint32(10).string(message.key);
9785
+ if (message.name !== "") {
9786
+ writer.uint32(10).string(message.name);
9517
9787
  }
9518
9788
  if (message.value !== "") {
9519
9789
  writer.uint32(18).string(message.value);
@@ -9523,7 +9793,7 @@ var ProviderView_ConfigEntry = {
9523
9793
  decode(input, length) {
9524
9794
  const reader = input instanceof import_wire4.BinaryReader ? input : new import_wire4.BinaryReader(input);
9525
9795
  const end = length === void 0 ? reader.len : reader.pos + length;
9526
- const message = createBaseProviderView_ConfigEntry();
9796
+ const message = createBaseAttributeView();
9527
9797
  while (reader.pos < end) {
9528
9798
  const tag = reader.uint32();
9529
9799
  switch (tag >>> 3) {
@@ -9531,7 +9801,7 @@ var ProviderView_ConfigEntry = {
9531
9801
  if (tag !== 10) {
9532
9802
  break;
9533
9803
  }
9534
- message.key = reader.string();
9804
+ message.name = reader.string();
9535
9805
  continue;
9536
9806
  }
9537
9807
  case 2: {
@@ -9551,14 +9821,14 @@ var ProviderView_ConfigEntry = {
9551
9821
  },
9552
9822
  fromJSON(object) {
9553
9823
  return {
9554
- key: isSet3(object.key) ? globalThis.String(object.key) : "",
9824
+ name: isSet3(object.name) ? globalThis.String(object.name) : "",
9555
9825
  value: isSet3(object.value) ? globalThis.String(object.value) : ""
9556
9826
  };
9557
9827
  },
9558
9828
  toJSON(message) {
9559
9829
  const obj = {};
9560
- if (message.key !== "") {
9561
- obj.key = message.key;
9830
+ if (message.name !== "") {
9831
+ obj.name = message.name;
9562
9832
  }
9563
9833
  if (message.value !== "") {
9564
9834
  obj.value = message.value;
@@ -9566,11 +9836,11 @@ var ProviderView_ConfigEntry = {
9566
9836
  return obj;
9567
9837
  },
9568
9838
  create(base) {
9569
- return ProviderView_ConfigEntry.fromPartial(base ?? {});
9839
+ return AttributeView.fromPartial(base ?? {});
9570
9840
  },
9571
9841
  fromPartial(object) {
9572
- const message = createBaseProviderView_ConfigEntry();
9573
- message.key = object.key ?? "";
9842
+ const message = createBaseAttributeView();
9843
+ message.name = object.name ?? "";
9574
9844
  message.value = object.value ?? "";
9575
9845
  return message;
9576
9846
  }
@@ -10112,6 +10382,21 @@ var LaceEngineDefinition = {
10112
10382
  }
10113
10383
  }
10114
10384
  };
10385
+ function bytesFromBase64(b64) {
10386
+ const bin = globalThis.atob(b64);
10387
+ const arr = new Uint8Array(bin.length);
10388
+ for (let i = 0; i < bin.length; ++i) {
10389
+ arr[i] = bin.charCodeAt(i);
10390
+ }
10391
+ return arr;
10392
+ }
10393
+ function base64FromBytes(arr) {
10394
+ const bin = [];
10395
+ arr.forEach((byte) => {
10396
+ bin.push(globalThis.String.fromCharCode(byte));
10397
+ });
10398
+ return globalThis.btoa(bin.join(""));
10399
+ }
10115
10400
  function longToNumber(int64) {
10116
10401
  const num = globalThis.Number(int64.toString());
10117
10402
  if (num > globalThis.Number.MAX_SAFE_INTEGER) {
@@ -10312,13 +10597,13 @@ var SERVICE_PATH = "/lace.engine.LaceEngine";
10312
10597
  var REQUEST_CODECS = new Map(
10313
10598
  Object.values(LaceEngineDefinition.methods).map((m) => [
10314
10599
  m.name,
10315
- { toJSON: m.requestType.toJSON }
10600
+ { fromPartial: m.requestType.fromPartial, toJSON: m.requestType.toJSON }
10316
10601
  ])
10317
10602
  );
10318
- function requestCodec(method) {
10603
+ function encodeRequest(method, request) {
10319
10604
  const codec = REQUEST_CODECS.get(method);
10320
10605
  if (!codec) throw new Error(`EngineCaller: unknown method "${method}"`);
10321
- return codec;
10606
+ return codec.toJSON(codec.fromPartial(request));
10322
10607
  }
10323
10608
  var RESPONSE_CODECS = {
10324
10609
  Initialize: LaceEngineDefinition.methods.initialize.responseType,
@@ -10342,7 +10627,7 @@ function connectCaller(options) {
10342
10627
  const res = await fetchImpl(`${baseUrl}${SERVICE_PATH}/${method}`, {
10343
10628
  method: "POST",
10344
10629
  headers: { "content-type": "application/json", authorization: `Bearer ${token}` },
10345
- body: JSON.stringify(requestCodec(method).toJSON(request))
10630
+ body: JSON.stringify(encodeRequest(method, request))
10346
10631
  });
10347
10632
  const bodyText = await res.text();
10348
10633
  if (!res.ok) {
@@ -10362,7 +10647,7 @@ function connectCaller(options) {
10362
10647
  return RESPONSE_CODECS[method].fromJSON(json);
10363
10648
  }
10364
10649
  async function* stream(method, request, signal) {
10365
- const body = encodeConnectFrame(JSON.stringify(requestCodec(method).toJSON(request)));
10650
+ const body = encodeConnectFrame(JSON.stringify(encodeRequest(method, request)));
10366
10651
  let res;
10367
10652
  try {
10368
10653
  res = await fetchImpl(`${baseUrl}${SERVICE_PATH}/${method}`, {
@@ -10468,7 +10753,7 @@ function bridgeCaller(bridge) {
10468
10753
  settle: (raw) => resolve(RESPONSE_CODECS[method].fromJSON(raw)),
10469
10754
  reject
10470
10755
  });
10471
- bridge.post({ kind: "unary", id, method, request: requestCodec(method).toJSON(request) });
10756
+ bridge.post({ kind: "unary", id, method, request: encodeRequest(method, request) });
10472
10757
  });
10473
10758
  }
10474
10759
  function stream(method, request, signal) {
@@ -10477,7 +10762,7 @@ function bridgeCaller(bridge) {
10477
10762
  queue.end();
10478
10763
  return queue.iterable;
10479
10764
  }
10480
- const body = requestCodec(method).toJSON(request);
10765
+ const body = encodeRequest(method, request);
10481
10766
  const id = crypto.randomUUID();
10482
10767
  function finish() {
10483
10768
  pendingStreams.delete(id);
@@ -10511,36 +10796,41 @@ var import_proto = require("@lace-cloud/proto");
10511
10796
 
10512
10797
  // src/contracts/commands.gen.ts
10513
10798
  var COMMANDS = {
10514
- "chaos get": {
10515
- "path": "chaos get",
10516
- "positionals": [
10517
- {
10518
- "name": "run",
10519
- "kind": "required"
10520
- }
10521
- ],
10799
+ "chaos run": {
10800
+ "path": "chaos run",
10801
+ "positionals": [],
10522
10802
  "flags": {
10523
- "org": {
10803
+ "commit": {
10524
10804
  "type": "string"
10525
10805
  },
10526
- "output": {
10806
+ "credential": {
10807
+ "type": "string"
10808
+ },
10809
+ "duration": {
10810
+ "type": "string"
10811
+ },
10812
+ "engine": {
10527
10813
  "type": "string",
10528
10814
  "values": [
10529
- "table",
10530
- "json"
10815
+ "aws_fis",
10816
+ "gremlin",
10817
+ "litmus_chaos"
10531
10818
  ]
10532
10819
  },
10533
- "team": {
10820
+ "excludeResourceType": {
10821
+ "type": "stringArray",
10822
+ "repeated": true
10823
+ },
10824
+ "excludeResourceUri": {
10825
+ "type": "stringArray",
10826
+ "repeated": true
10827
+ },
10828
+ "experimentId": {
10534
10829
  "type": "string"
10535
- }
10536
- },
10537
- "hidden": false,
10538
- "yes": false
10539
- },
10540
- "chaos list": {
10541
- "path": "chaos list",
10542
- "positionals": [],
10543
- "flags": {
10830
+ },
10831
+ "file": {
10832
+ "type": "string"
10833
+ },
10544
10834
  "org": {
10545
10835
  "type": "string"
10546
10836
  },
@@ -10551,39 +10841,34 @@ var COMMANDS = {
10551
10841
  "json"
10552
10842
  ]
10553
10843
  },
10554
- "stack": {
10555
- "type": "string",
10556
- "required": true
10557
- },
10558
- "team": {
10844
+ "prUrl": {
10559
10845
  "type": "string"
10560
- }
10561
- },
10562
- "hidden": false,
10563
- "yes": false
10564
- },
10565
- "chaos run": {
10566
- "path": "chaos run",
10567
- "positionals": [],
10568
- "flags": {
10569
- "chaosBinding": {
10570
- "type": "string",
10571
- "required": true
10572
10846
  },
10573
- "org": {
10847
+ "ref": {
10574
10848
  "type": "string"
10575
10849
  },
10576
- "output": {
10850
+ "resourceType": {
10851
+ "type": "stringArray",
10852
+ "repeated": true
10853
+ },
10854
+ "selector": {
10577
10855
  "type": "string",
10578
10856
  "values": [
10579
- "table",
10580
- "json"
10857
+ "first",
10858
+ "random"
10581
10859
  ]
10582
10860
  },
10583
10861
  "stack": {
10584
10862
  "type": "string",
10585
10863
  "required": true
10586
10864
  },
10865
+ "tag": {
10866
+ "type": "string"
10867
+ },
10868
+ "tagFilter": {
10869
+ "type": "stringArray",
10870
+ "repeated": true
10871
+ },
10587
10872
  "team": {
10588
10873
  "type": "string"
10589
10874
  }
@@ -11828,8 +12113,6 @@ var moduleValidateDeviationSchema = import_zod.z.object({
11828
12113
  backendFindings: import_zod.z.array(import_zod.z.object({ file: import_zod.z.string(), line: import_zod.z.number(), kind: import_zod.z.string() })),
11829
12114
  sharedLocalSource: import_zod.z.boolean(),
11830
12115
  sharedLocalFindings: import_zod.z.array(import_zod.z.unknown()),
11831
- uncomposable: import_zod.z.boolean(),
11832
- uncomposableReason: import_zod.z.string(),
11833
12116
  registryVersionNotExact: import_zod.z.array(import_zod.z.unknown()),
11834
12117
  childNotLaceForm: import_zod.z.array(import_zod.z.unknown())
11835
12118
  });
@@ -11847,7 +12130,7 @@ var commandDiagnosticSchema = import_zod.z.object({
11847
12130
  var moduleValidateResultSchema = import_zod.z.object({
11848
12131
  root: import_zod.z.string().min(1).optional(),
11849
12132
  treeHash: import_zod.z.string().min(1).optional(),
11850
- verdict: import_zod.z.enum(["already-lace-style", "representable-but-transpilable", "lossy"]).optional(),
12133
+ verdict: import_zod.z.enum(["already-lace-style", "representable-but-transpilable", "uncomposable", "lossy"]).optional(),
11851
12134
  residuals: import_zod.z.array(
11852
12135
  import_zod.z.object({
11853
12136
  construct: import_zod.z.string(),
@@ -12009,8 +12292,6 @@ var stackSchema = import_zod.z.object({
12009
12292
  lastDriftStale: import_zod.z.boolean(),
12010
12293
  lastDriftConfirmedAt: import_zod.z.string().nullable(),
12011
12294
  lastDriftUndeterminedReason: import_zod.z.string().nullable(),
12012
- chaosLockedByRunId: import_zod.z.string().nullable(),
12013
- chaosLockedAt: import_zod.z.string().nullable(),
12014
12295
  createdBy: import_zod.z.string(),
12015
12296
  createdAt: import_zod.z.string(),
12016
12297
  updatedAt: import_zod.z.string(),
@@ -12126,23 +12407,47 @@ var runListSchema = import_zod.z.object({
12126
12407
  nextCursor: import_zod.z.string().nullable(),
12127
12408
  hasMore: import_zod.z.boolean()
12128
12409
  });
12129
- var chaosListSchema = import_zod.z.object({
12130
- stackId: import_zod.z.string(),
12131
- connectionBlock: import_zod.z.unknown().nullable(),
12132
- experiments: import_zod.z.array(
12133
- import_zod.z.object({
12134
- bindingId: import_zod.z.string(),
12135
- name: import_zod.z.string(),
12136
- assertionCount: import_zod.z.number(),
12137
- engine: import_zod.z.string()
12138
- })
12139
- )
12140
- });
12141
12410
  var planSummarySchema = import_zod.z.object({
12142
12411
  resourceAdd: import_zod.z.number(),
12143
12412
  resourceChange: import_zod.z.number(),
12144
12413
  resourceDestroy: import_zod.z.number()
12145
12414
  });
12415
+ var previewAdvisorySchema = import_zod.z.object({
12416
+ id: import_zod.z.string(),
12417
+ manifestation: import_zod.z.string(),
12418
+ emittedByInstallId: import_zod.z.string(),
12419
+ emittedByDisplayName: import_zod.z.string(),
12420
+ confidenceScore: import_zod.z.number(),
12421
+ producedAt: import_zod.z.string(),
12422
+ outputJson: import_zod.z.unknown()
12423
+ });
12424
+ var previewEntrySchema = import_zod.z.discriminatedUnion("kind", [
12425
+ import_zod.z.object({
12426
+ kind: import_zod.z.literal("consensus"),
12427
+ subject: import_zod.z.object({
12428
+ resourceUri: import_zod.z.string(),
12429
+ riskCategory: import_zod.z.string(),
12430
+ remediationKind: import_zod.z.string(),
12431
+ remediationFingerprint: import_zod.z.string()
12432
+ }),
12433
+ advisories: import_zod.z.array(previewAdvisorySchema).min(1),
12434
+ agentCount: import_zod.z.number()
12435
+ }),
12436
+ import_zod.z.object({
12437
+ kind: import_zod.z.literal("disagreement"),
12438
+ subject: import_zod.z.object({
12439
+ resourceUri: import_zod.z.string(),
12440
+ riskCategory: import_zod.z.string(),
12441
+ remediationKind: import_zod.z.string()
12442
+ }),
12443
+ lanes: import_zod.z.array(
12444
+ import_zod.z.object({
12445
+ remediationFingerprint: import_zod.z.string(),
12446
+ advisories: import_zod.z.array(previewAdvisorySchema).min(1)
12447
+ })
12448
+ ).min(2)
12449
+ })
12450
+ ]);
12146
12451
  var stackPreviewSchema = import_zod.z.object({
12147
12452
  stack: import_zod.z.object({ id: import_zod.z.string(), slug: import_zod.z.string() }),
12148
12453
  treeHash: import_zod.z.string(),
@@ -12154,30 +12459,55 @@ var stackPreviewSchema = import_zod.z.object({
12154
12459
  rulesFired: import_zod.z.array(import_zod.z.string()),
12155
12460
  reason: import_zod.z.string(),
12156
12461
  approvalMode: import_zod.z.string().nullable(),
12157
- isAuthoringTimePreview: import_zod.z.boolean()
12158
- }).nullable()
12462
+ isAuthoringTimePreview: import_zod.z.boolean(),
12463
+ bindings: import_zod.z.array(
12464
+ import_zod.z.object({
12465
+ policyId: import_zod.z.string(),
12466
+ name: import_zod.z.string(),
12467
+ handler: import_zod.z.string(),
12468
+ mode: import_zod.z.string(),
12469
+ decision: import_zod.z.string(),
12470
+ reason: import_zod.z.string(),
12471
+ rulesFired: import_zod.z.array(import_zod.z.string()),
12472
+ approvalMode: import_zod.z.string().nullable()
12473
+ })
12474
+ )
12475
+ }).nullable(),
12476
+ // What the Preview shows of the Agents bound at it: the curated queue of
12477
+ // their Advisories about this tree, how many were recorded under the
12478
+ // Preview's floor, how many bound Agents have not answered, and how many
12479
+ // Agent Bindings the preview activated.
12480
+ advisories: import_zod.z.object({
12481
+ queue: import_zod.z.object({
12482
+ manifestation: import_zod.z.literal("preview"),
12483
+ floor: import_zod.z.number(),
12484
+ entries: import_zod.z.array(previewEntrySchema),
12485
+ belowFloor: import_zod.z.number()
12486
+ }),
12487
+ truncated: import_zod.z.boolean(),
12488
+ pending: import_zod.z.number(),
12489
+ bound: import_zod.z.number().optional()
12490
+ })
12159
12491
  });
12160
- var changeRequestSchema = import_zod.z.object({
12492
+ var gateChangeRequestSchema = import_zod.z.object({
12161
12493
  id: import_zod.z.string(),
12162
- orgId: import_zod.z.string(),
12163
- teamId: import_zod.z.string(),
12164
- runId: import_zod.z.string(),
12165
- bindingId: import_zod.z.string().nullable(),
12166
- invocationId: import_zod.z.string().nullable(),
12167
12494
  state: import_zod.z.string(),
12168
- approverUserId: import_zod.z.string().nullable(),
12169
- approvalChain: import_zod.z.unknown(),
12170
- emergencyApproval: import_zod.z.boolean(),
12171
- narrativeArtifactId: import_zod.z.string().nullable(),
12172
- policyResolution: import_zod.z.unknown(),
12173
- externalSystemId: import_zod.z.string().nullable(),
12174
- externalRef: import_zod.z.string().nullable(),
12175
- idempotencyKey: import_zod.z.string().nullable(),
12176
- lastReconciledAt: import_zod.z.string().nullable(),
12177
- submittedByUserId: import_zod.z.string().nullable(),
12178
- submittedAt: import_zod.z.string().nullable(),
12179
- createdAt: import_zod.z.string(),
12180
- updatedAt: import_zod.z.string()
12495
+ requirements: import_zod.z.array(
12496
+ import_zod.z.object({
12497
+ id: import_zod.z.string(),
12498
+ state: import_zod.z.string(),
12499
+ decidedBy: import_zod.z.enum(["lace", "ecm"])
12500
+ })
12501
+ ),
12502
+ records: import_zod.z.array(
12503
+ import_zod.z.object({
12504
+ externalSystemId: import_zod.z.string(),
12505
+ kind: import_zod.z.string(),
12506
+ externalRef: import_zod.z.string().nullable(),
12507
+ externalUrl: import_zod.z.string().nullable(),
12508
+ state: import_zod.z.string().nullable()
12509
+ })
12510
+ )
12181
12511
  });
12182
12512
  var runEventSchema = import_zod.z.discriminatedUnion("type", [
12183
12513
  import_zod.z.object({ type: import_zod.z.literal("log"), text: import_zod.z.string() }),
@@ -12185,8 +12515,11 @@ var runEventSchema = import_zod.z.discriminatedUnion("type", [
12185
12515
  import_zod.z.object({
12186
12516
  type: import_zod.z.literal("gate"),
12187
12517
  resolution: import_zod.z.object({ mode: import_zod.z.string(), reason: import_zod.z.string().optional() }),
12188
- changeRequest: changeRequestSchema.nullable()
12189
- }),
12518
+ changeRequest: gateChangeRequestSchema.nullable()
12519
+ }).refine(
12520
+ (gate) => gate.resolution.mode === "awaiting_approval" === (gate.changeRequest !== null),
12521
+ { message: "a gate event carries a change request exactly when it holds the Run" }
12522
+ ),
12190
12523
  import_zod.z.object({
12191
12524
  type: import_zod.z.literal("result"),
12192
12525
  run: runSchema,
@@ -12294,7 +12627,6 @@ var SCHEMAS = {
12294
12627
  "stack describe": stackDescribeSchema,
12295
12628
  "policy list": policyListSchema,
12296
12629
  "run list": runListSchema,
12297
- "chaos list": chaosListSchema,
12298
12630
  "stack preview": stackPreviewSchema,
12299
12631
  "stack apply": runEventSchema,
12300
12632
  "stack destroy": runEventSchema,
@@ -12884,6 +13216,18 @@ var MODULE_COMMAND_ACTIONS = [
12884
13216
  requiredPorts: ["commands"],
12885
13217
  requiredContext: ["root"],
12886
13218
  binding: convert
13219
+ },
13220
+ // The refused-tf banner's one action while the tree is out of lace shape:
13221
+ // the same `module convert` the toolbar runs. The engine re-derives the
13222
+ // tree it writes, which accepts it and lifts the lock.
13223
+ {
13224
+ id: "convert-refused",
13225
+ label: "Convert",
13226
+ icon: "convert",
13227
+ placement: { row: "source-refused" },
13228
+ requiredPorts: ["commands"],
13229
+ requiredContext: ["root", "needsConversion"],
13230
+ binding: convert
12887
13231
  }
12888
13232
  ];
12889
13233
  var STACK_COMMAND_ACTIONS = [
@@ -12969,6 +13313,10 @@ var CORE_COMMAND_ACTIONS = [
12969
13313
  ];
12970
13314
 
12971
13315
  // src/core/diagnostics.ts
13316
+ var NOT_LACE_SHAPE = "not_lace_shape";
13317
+ function holdsLaceShapeRefusal(diagnostics) {
13318
+ return diagnostics.some((d) => d.code === NOT_LACE_SHAPE);
13319
+ }
12972
13320
  function findingKey(d) {
12973
13321
  return JSON.stringify([
12974
13322
  d.file,
@@ -13102,10 +13450,10 @@ function reduceRun(prev, token, event) {
13102
13450
  const lastLog = event.type === "log" ? event.text : carried?.lastLog ?? null;
13103
13451
  const phases = event.type === "phase" ? withPhase(carried?.phases ?? [], event.name) : carried?.phases ?? [];
13104
13452
  const submitted = carried?.submitted || event.type === "phase" && event.name === "submit";
13105
- if (event.type === "gate" && event.resolution.mode === "awaiting_approval") {
13453
+ if (event.type === "gate" && event.changeRequest !== null) {
13106
13454
  return {
13107
13455
  token,
13108
- outcome: { kind: "awaiting-approval", changeRequestId: event.changeRequest?.id ?? "" },
13456
+ outcome: { kind: "awaiting-approval", changeRequest: event.changeRequest },
13109
13457
  lastLog,
13110
13458
  submitted,
13111
13459
  phases: closePhases(phases)
@@ -13285,6 +13633,7 @@ var CONTEXT_NEEDS = {
13285
13633
  resolved: "no open Keep or Reload conflict",
13286
13634
  conflict: "an open Keep or Reload conflict",
13287
13635
  sourceRefused: "the source-refused lock",
13636
+ needsConversion: "a tree that needs conversion",
13288
13637
  "selection.node": "a selected node",
13289
13638
  "selection.edge": "a selected connection",
13290
13639
  diagnostics: "diagnostics to show",
@@ -13309,6 +13658,8 @@ function keySatisfied(ctx, key) {
13309
13658
  if (key === "resolved") return ctx.view !== void 0 && ctx.view.conflict === void 0;
13310
13659
  if (key === "conflict") return ctx.view?.conflict !== void 0;
13311
13660
  if (key === "sourceRefused") return ctx.sourceRefused === true;
13661
+ if (key === "needsConversion")
13662
+ return ctx.sourceRefused === true && holdsLaceShapeRefusal(ctx.diagnostics ?? []);
13312
13663
  if (key === "selection.node")
13313
13664
  return ctx.selection !== void 0 && ctx.selection.nodes.length > 0;
13314
13665
  if (key === "selection.edge") return ctx.selection !== void 0 && ctx.selection.edge !== null;