@autorest/powershell 4.0.754 → 4.0.758

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.
@@ -8,7 +8,7 @@
8
8
  "powershell/autorest-configuration-for-sdk.md": "d6bd98068a88d8f9cb41b8a731cfea21d0787e4e",
9
9
  "powershell/autorest-configuration.md": "3a47bf36e4b80be07ddfd20d77fabf82aacfd77f",
10
10
  "powershell/changelog.md": "438e32cc7c4d86e08e32c2fd4085928c0e70b1b9",
11
- "powershell/cmdlets/class.ts": "37a384a468164bf5bcf0968869c6e91e3f71944c",
11
+ "powershell/cmdlets/class.ts": "415a82888099d22c7bf946384fb27da52d284808",
12
12
  "powershell/cmdlets/namespace.ts": "3d5f007d0833a3df909fdff97df939c6c80b0fb4",
13
13
  "powershell/cmdlets/parameter.ts": "7c67fea43eded2c358ad802306dde505c8d0e30f",
14
14
  "powershell/enums/namespace.ts": "1206b2c779837a0660b314059e312a472a145c87",
@@ -24,12 +24,12 @@
24
24
  "powershell/generators/nuspec.ts": "a290cb054b420d209091ec79e59103b7b7ab321f",
25
25
  "powershell/generators/psm1.custom.ts": "68ad4aa17f5b867d4e471ef570f196e77ea23999",
26
26
  "powershell/generators/psm1.internal.ts": "98829f795fb438d13780eb78bf84a97f473772cd",
27
- "powershell/generators/psm1.ts": "01985a80f31586d45f83ab3a91e702752591d05f",
27
+ "powershell/generators/psm1.ts": "23b66a586f76ce03a929116d2f9496edf7aaf657",
28
28
  "powershell/generators/readme.ts": "7b6bd39f2b2984209d1bf4eab6a4f7707b1dc354",
29
29
  "powershell/generators/script-cmdlet.ts": "c3ea68a007b2cdc5b95fc49b3d8d9081e0048657",
30
30
  "powershell/internal/name-inferrer.ts": "8270005536a5462b6f3e998a3df4c1f112b221ec",
31
- "powershell/internal/powershell-declarations.ts": "0cbb0c67b76cbefc1d962cd9952ca0c43cf693e5",
32
- "powershell/internal/project.ts": "4d61fa74bf57ebfe1bea4e6770d2879ea6b61875",
31
+ "powershell/internal/powershell-declarations.ts": "50e1759823228dbba3c396e0967c9c1f8c547fc5",
32
+ "powershell/internal/project.ts": "b0d91956c760bbf74182997391ac969c08c82e35",
33
33
  "powershell/internal/state.ts": "ed2dcc72cf386b051f73d6be4164a29998d32a4e",
34
34
  "powershell/internal/verbs.ts": "c8fd6b534923b1dd1bd71be0f33936265468942e",
35
35
  "powershell/llcsharp/clientruntime.ts": "e8fe49c0fcd85f0a76f9f0a8df976c21cfed108d",
@@ -76,9 +76,9 @@
76
76
  "powershell/llcsharp/validations.ts": "0a86cb8934b4536461efbce10de737075c599866",
77
77
  "powershell/main.ts": "0eacdbffe3e1179a7e66ce79e9e3882855b42f0a",
78
78
  "powershell/models/model-extensions.ts": "2b3c129d070b0a30b01d32eb8998043c30b1bd7d",
79
- "powershell/module/module-class.ts": "1c552107e1b780db75e56ec302aaec8d490d5695",
79
+ "powershell/module/module-class.ts": "e8950fd6d4988bfa7b8f49b46ce24d418c590550",
80
80
  "powershell/module/module-namespace.ts": "f6afc90087e8d733f0323b0de8ba41d923955732",
81
- "powershell/package.json": "e8eb2b3f8e405c482a3af4b88bf5fc7957d914c4",
81
+ "powershell/package.json": "cc0b65429fcac26850cedef90a5aa5f474fc1efa",
82
82
  "powershell/plugins/add-azure-completers-v2.ts": "46e91eb274a6a863315be8c0d5c9d84597654bce",
83
83
  "powershell/plugins/create-commands-v2.ts": "b4788ac66e3c21959b38f69a78d275991f90b660",
84
84
  "powershell/plugins/cs-namer-v2.ts": "f16981643ae24355e937ea717e33508e46dd2da2",
@@ -218,7 +218,7 @@
218
218
  "powershell/resources/psruntime/BuildTime/Cmdlets/ExportFormatPs1xml.cs": "e974093cbafba7c6190c7c07219f84ed81bad063",
219
219
  "powershell/resources/psruntime/BuildTime/Cmdlets/ExportHelpMarkdown.cs": "4c79464f693bbb6dbc798a6cec590e5fbf539656",
220
220
  "powershell/resources/psruntime/BuildTime/Cmdlets/ExportModelSurface.cs": "e4af60bd7ad7b57a036474c5aed7c4cab4b1997d",
221
- "powershell/resources/psruntime/BuildTime/Cmdlets/ExportProxyCmdlet.cs": "f36346b8291eef621d487b090bd184cbd9fa3a9e",
221
+ "powershell/resources/psruntime/BuildTime/Cmdlets/ExportProxyCmdlet.cs": "38d7cbe28a5b7a67c8315c6a4970793340e16a6e",
222
222
  "powershell/resources/psruntime/BuildTime/Cmdlets/ExportPsd1.cs": "b3833ffb92514646dc99611eaf5aab4e4a232664",
223
223
  "powershell/resources/psruntime/BuildTime/Cmdlets/ExportTestStub.cs": "57f53b7abccf6edf11bfa822224452ace2506b74",
224
224
  "powershell/resources/psruntime/BuildTime/Cmdlets/GetCommonParameter.cs": "bf5c757829449599eee8ff1786b3198d703ed7a6",
@@ -230,7 +230,7 @@
230
230
  "powershell/resources/psruntime/BuildTime/Models/PsHelpMarkdownOutputs.cs": "056be554968d76667c0659d169f674ef5dbb74ed",
231
231
  "powershell/resources/psruntime/BuildTime/Models/PsHelpTypes.cs": "4f239ab459b0abf4f3e1dc0cb7e6cf490fb9cf21",
232
232
  "powershell/resources/psruntime/BuildTime/Models/PsMarkdownTypes.cs": "c2c068932d2e4ab31a46d566e7b24f357f68c6f8",
233
- "powershell/resources/psruntime/BuildTime/Models/PsProxyOutputs.cs": "52400e58df7c94113f9ec235e0aa749fc3814026",
233
+ "powershell/resources/psruntime/BuildTime/Models/PsProxyOutputs.cs": "8004f5c588e128945c5b04cf3b2946df6ef2871e",
234
234
  "powershell/resources/psruntime/BuildTime/Models/PsProxyTypes.cs": "75ea91810089fb5d7170f1bed0d8023aabd2f74a",
235
235
  "powershell/resources/psruntime/BuildTime/PsAttributes.cs": "42cd061f1a91cef396cd392584e7eab268c4bc3a",
236
236
  "powershell/resources/psruntime/BuildTime/PsExtensions.cs": "52083232ddc161a0f41496cbdf979d709c490194",
@@ -330,7 +330,7 @@
330
330
  "powershell/resources/runtime/csharp/pipeline/EventData.cs": "e0ad3c5ea54e9615ca7bc3e71672e3c1c74b2b27",
331
331
  "powershell/resources/runtime/csharp/pipeline/EventListener.cs": "350991c330499c8770e33d0ca3cf34edfd93bf0a",
332
332
  "powershell/resources/runtime/csharp/pipeline/Events.cs": "63b08de750ffa3eb77fb45012d4d1b19d1c52654",
333
- "powershell/resources/runtime/csharp/pipeline/ISendAsync.cs": "479c7ab4908d8049afc28187d694cdc2687118c7",
333
+ "powershell/resources/runtime/csharp/pipeline/ISendAsync.cs": "0c35d456824a3369d1b03fc5cd7c5ae7aa1bba1d",
334
334
  "powershell/resources/runtime/csharp/pipeline/PipelineMocking.cs": "6082ba80ed830698b034b88e31ae16050fbcd6c8",
335
335
  "powershell/resources/runtime/csharp/pipeline/Response.cs": "0916ff12e3cbe15950a260245274af684256158b",
336
336
  "powershell/resources/runtime/csharp/pipeline/delegates.cs": "3abbd1354807e026f0d05a72e7d538533d775984",
@@ -386,7 +386,7 @@
386
386
  "powershell/utils/security-scheme.ts": "5ad1d05e51b94b9645c95104a08d748c17b8d3ac",
387
387
  "powershell/utils/sort-parameters.ts": "65cabd68e4adde1d6e93e35d740ec8da4929f36b",
388
388
  "powershell/utils/tsp-generator.ts": "3fd32e49d1a52e8019180905c077694f8bf1e2c8",
389
- "powershell/utils/tsp-host.ts": "5ff5c76c652fcd4fc859463f3033d7039ccc7dd3",
389
+ "powershell/utils/tsp-host.ts": "4fcdce1e55ccb8f794d13d7a6edee71ff49ef38d",
390
390
  "powershell/utils/uid.ts": "dbeb7ffd9dba79a6ce37a9b21955c00e42c8f6ae"
391
391
  },
392
392
  "arguments": "tsc -p . "
@@ -69,6 +69,7 @@ export declare class CmdletClass extends Class {
69
69
  private NewImplementSerialization;
70
70
  private implementConstructors;
71
71
  private implementIContext;
72
+ private implementChangeSafetyParameters;
72
73
  private implementIEventListener;
73
74
  private NewAddPowershellParameters;
74
75
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"class.d.ts","sourceRoot":"","sources":["../../cmdlets/class.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,MAAM,IAAI,SAAS,EA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CAAG,aAAa;IAoLvB,OAAO,CAAC,0BAA0B;IAIlC,OAAO,CAAC,6BAA6B;IAIrC,OAAO,CAAC,qCAAqC;IAI7C,OAAO,CAAC,8CAA8C;IAItD,OAAO,CAAC,2CAA2C;IAInD,OAAO,CAAC,8CAA8C;IAKtD,OAAO,CAAC,mCAAmC;IAO3C,OAAO,CAAC,qCAAqC;IAgB7C,OAAO,CAAC,yCAAyC;IA8BjD,OAAO,CAAC,gDAAgD;IAoCxD,OAAO,CAAC,qCAAqC;IAI7C,OAAO,CAAC,gBAAgB;IAyCxB,OAAO,CAAC,0BAA0B;IA0RlC,OAAO,CAAC,yBAAyB;IAoCjC,OAAO,CAAC,qBAAqB;IAK7B,OAAO,CAAC,iBAAiB;IAUzB,OAAO,CAAC,+BAA+B;IAkDvC,OAAO,CAAC,uBAAuB;IAiJ/B,OAAO,CAAC,0BAA0B;IA2WlC;;;;;OAKG;IACH,OAAO,CAAC,cAAc;IAUtB,OAAO,CAAC,qBAAqB;IA0J7B,OAAO,CAAC,4BAA4B;CAuErC"}
@@ -387,6 +387,8 @@ class CmdletClass extends codegen_csharp_1.Class {
387
387
  this.implementIEventListener();
388
388
  // implement part of the IContext
389
389
  this.implementIContext();
390
+ // Change Safety: emit codegen-owned inline dynamic parameters on write-verb cmdlets
391
+ this.implementChangeSafetyParameters();
390
392
  // add constructors
391
393
  this.implementConstructors();
392
394
  // add callback methods
@@ -1453,6 +1455,56 @@ class CmdletClass extends codegen_csharp_1.Class {
1453
1455
  extensibleParametersProp.get = (0, codegen_csharp_1.toExpression)(`${extensibleParameters.value} `);
1454
1456
  this.add(extensibleParametersProp);
1455
1457
  }
1458
+ implementChangeSafetyParameters() {
1459
+ var _a;
1460
+ // Change Safety (codegen-owned inline dynamic parameters): only azure management-plane (ARM)
1461
+ // write cmdlets expose the opt-in Change Safety parameters. They are surfaced via an inline
1462
+ // IDynamicParameters implementation (the same dynamic-parameter mechanism SDK cmdlets use),
1463
+ // emitted directly in the generated cmdlet -- no runtime-wired VTable delegate. PowerShell
1464
+ // binds the returned parameters into BoundParameters, where the module-level HTTP pipeline
1465
+ // step (in Az.Accounts) reads them.
1466
+ // Opt-in per module via `enable-change-safety: true` in the module readme (default off), so
1467
+ // the 180+ module rollout is deliberate rather than triggered by any unrelated regeneration.
1468
+ if (!this.state.project.enableChangeSafety) {
1469
+ return;
1470
+ }
1471
+ if (!this.state.project.azure) {
1472
+ return;
1473
+ }
1474
+ // Change Safety is a management-plane concept; skip data-plane modules, which target a
1475
+ // custom service endpoint (identified by an endpoint-resource-id-key-name). This matches
1476
+ // the data-plane detection used in module-class.ts (isDataPlane).
1477
+ if (this.state.project.endpointResourceIdKeyName) {
1478
+ return;
1479
+ }
1480
+ // Gate on the PowerShell verb rather than sniffing the HTTP method off requests[0]. A cmdlet's
1481
+ // callGraph can contain multiple operations (e.g. a GetPut Update = GET + PUT) and a single
1482
+ // operation can carry multiple requests, so requests[0] is not a reliable signal for whether
1483
+ // the cmdlet mutates. The verb encodes the mutating intent computed across the whole call graph
1484
+ // and, unlike the raw HTTP method, correctly treats POST "list"-style operations (surfaced as
1485
+ // Get) as reads.
1486
+ const verb = ((_a = this.operation.details.csharp.verb) !== null && _a !== void 0 ? _a : '').toLowerCase();
1487
+ const readOnlyVerbs = ['get', 'test', 'find', 'search', 'measure', 'show', 'ping', 'trace', 'resolve', 'read'];
1488
+ if (readOnlyVerbs.includes(verb)) {
1489
+ return;
1490
+ }
1491
+ // Emit an inline IDynamicParameters implementation. GetDynamicParameters builds the
1492
+ // RuntimeDefinedParameterDictionary locally with names + help text that mirror
1493
+ // azure-powershell-common's ChangeSafetyParameters (there is no compile-time link across repos;
1494
+ // a contract pin test in Accounts.Test keeps these literals in sync). This matches how SDK
1495
+ // cmdlets surface -AcquirePolicyToken / -ChangeReference, so the two are indistinguishable.
1496
+ this.interfaces.push(powershell_declarations_1.IDynamicParameters);
1497
+ const getDynamicParameters = this.add(new codegen_csharp_1.Method('GetDynamicParameters', codegen_csharp_1.dotnet.Object, {
1498
+ description: 'Returns the Change Safety dynamic parameters (-AcquirePolicyToken / -ChangeReference) for this write cmdlet.',
1499
+ returnsDescription: 'A <see cref="System.Management.Automation.RuntimeDefinedParameterDictionary" /> containing the Change Safety parameters.'
1500
+ }));
1501
+ getDynamicParameters.add(function* () {
1502
+ yield 'var parameters = new global::System.Management.Automation.RuntimeDefinedParameterDictionary();';
1503
+ yield 'parameters.Add("AcquirePolicyToken", new global::System.Management.Automation.RuntimeDefinedParameter("AcquirePolicyToken", typeof(global::System.Management.Automation.SwitchParameter), new global::System.Collections.ObjectModel.Collection<global::System.Attribute> { new global::System.Management.Automation.ParameterAttribute { HelpMessage = "Acquire an Azure Policy token automatically for this resource operation.", ParameterSetName = global::System.Management.Automation.ParameterAttribute.AllParameterSets } }));';
1504
+ yield 'parameters.Add("ChangeReference", new global::System.Management.Automation.RuntimeDefinedParameter("ChangeReference", typeof(string), new global::System.Collections.ObjectModel.Collection<global::System.Attribute> { new global::System.Management.Automation.ParameterAttribute { HelpMessage = "The change reference resource ID for this resource operation.", ParameterSetName = global::System.Management.Automation.ParameterAttribute.AllParameterSets } }));';
1505
+ yield 'return parameters;';
1506
+ });
1507
+ }
1456
1508
  implementIEventListener() {
1457
1509
  const $this = this;
1458
1510
  const cts = this.add(new codegen_csharp_1.Field('_cancellationTokenSource', codegen_csharp_1.System.Threading.CancellationTokenSource, {