Feature: Enable use of semantic exit codes for adapted PSDSC resources
Maintainer antworten meist innerhalb von 2 Tagen
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 5/5
- Geschätzter Aufwand
- Über eine Woche
- Anfängerfreundlichkeit
- 35/100
Rechercherichtung
Beginne mit lib/dsc-lib/src/dscresources/adapted_resource_manifest.rs und RFC0001/PR #1319, um nachzuverfolgen, wie angepasste Ressourcen Exit-Codes derzeit darstellen. Definiere den Klassen- und Manifest-Vertrag für semantische Codes, einschließlich des Standardverhaltens für 0/1, und überprüfe, dass Ressourcenoperationen einen spezifischen Fehlercode zurückgeben können.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Summary of the new feature / enhancement
As a resource author implementing DSC resources as PowerShell classes,
I want to be able to provide semantic exit codes for my users,
so that my resources can fit into the semantics of DSC more correctly.
Currently, adapted PSDSC resources always return an exit code of 1 for an operational failure. There is no way for a resource implemented as a PowerShell class to:
- Indicate a set of exit codes and their meaning for DSC from the class implementation.
- Indicate a set of exit codes and their meaning for DSC from the adapted resource manifest.
- Surface that the operation is a failure and should exit with a specific code from any given resource operation.
[!NOTE]
This problem affects other adapters as well, but we only have the PowerShell adapters published.
Proposed technical implementation details (optional)
We should add an exitCodes field to the adapted resource manifest to ensure that adapted resources can propagate semantically defined exit codes to DSC and higher order tools.
I can address the specifics of how to retrieve the exit codes from a class definition in RFC0001, but I think we need a way to properly indicate a semantic exit code from within a class method. I can't see an immediately obvious way to do this without either providing a [DscOperationException] class or requiring the resource author to implement a custom exception that includes both an exit code and message that their resource class throws.
When an adapted resource doesn't provide semantic exit codes, we should treat the exit codes the same way we do for other resources (0 for success, 1 for failure). This is an opt-in enhancement for all resources, but currently adapted resource authors can't participate in these semantics.
- Vorherrschende Sprache
- Rust
- Sterne
- 543
- Forks
- 78
- Ø Merge
- 2 T. 6 Std.
- Gemergte PRs (30 T.)
- 18
Entwicklungsumgebung
Startet den Dev-Container des Projekts im Browser, mit Ihrem eigenen GitHub-Konto.
- Kein Dockerfile und keine Docker-Compose-Datei
- Keine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus PowerShell/DSC
-
Failure to parse a resource manifest is logged as INFO instead of WARNEvtl. vergeben @SteveL-MSFT hat das vor 7 Tagen übernommen. OffenIssue-Bug Need-Review
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 69/100
PowerShell/DSC#1765 · 1 zugewiesene Person ·
Maintainer antworten meist innerhalb von 2 Tagen
-
Tracing categoriesEvtl. vergeben @michaeltlombardi hat das vor 9 Tagen übernommen. OffenArea-OpenTelemetry Issue-Enhancement Needs Triage
PowerShell/DSC#1767 · 1 Reaktion · 1 zugewiesene Person ·
Maintainer antworten meist innerhalb von 2 Tagen
-
Issue-Enhancement Needs Triage
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 25/100
PowerShell/DSC#1763 · 1 Kommentar · 1 Reaktion ·
Maintainer antworten meist innerhalb von 2 Tagen
-
Issue-Enhancement Needs Triage
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 35/100
PowerShell/DSC#1760 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
Hardening with dsc 3 ?Evtl. vergeben Ein verknüpfter Pull Request ist offen oder bereits gemergt. OffenIssue-Enhancement Needs Triage
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 12/100
PowerShell/DSC#1755 · 8 Kommentare ·
Maintainer antworten meist innerhalb von 2 Tagen
Ähnliche Issues
-
area:cli bug dotnet good first issue priority:medium
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
rtk-ai/rtk#4844 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
delta-io/delta-kernel-rs#3757 ·
Maintainer antworten meist innerhalb von 3 Tagen
-
area: library data-loss type: bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
alplabai/signex#1740 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
test(fslc): the unreadable mutate catalog test pins the Unix I/O error text and fails on WindowsEvtl. vergeben @rizumita hat das heute übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 82/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 69/100
Maintainer antworten meist innerhalb von 1 Tag