Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
# ignore
# ignore
.vs/
.vscode/
.DS_Store

# tmp
bin/
obj/
tmp/
publish/
*.jsonl
*.json
Expand All @@ -18,6 +19,7 @@ Modules/M365DSC.mgx/*.json
Modules/M365DSC.mgx/Dependencies/
Modules/M365DSC.mgx/.build-hash


# Test output
TestResults/
tests/TestResults.xml
Expand All @@ -28,3 +30,12 @@ artifacts/

# Re-included from the blanket *.json above, since it pins the ReportGenerator version CI restores
!.config/dotnet-tools.json

# results/ above stays local: it is the append-only per-run log, and one machine's numbers are
# not another's. The baseline beside it is the pinned snapshot a later run is read against, and
# it is committed, so it has to be re-included after *.json has had its say. Nothing here
# re-includes results/ itself.
!tests/benchmarks/baseline.json

# Generated by the CI compat job when run locally
compat-surface-tests.ps1
34 changes: 33 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,36 @@
# Changelog
# Changelog

## 2.1.7

### Added

- `Invoke-MgxRequest -Envelope` emits the payload as the service sent it, collection envelope and all, instead of the items inside it. Without it a collection holding one item and a single entity arrive as the same thing - one object - which a caller that has to tell them apart cannot do. `-All` keeps aggregating pages and ignores the switch. Upstream does not carry this.

### Fixed

- The batch retry loop waited out its exponential fallback without regard for `MaxRetryAfterSeconds`, which caps only the delays a server asks for. Both now answer to the same ceiling.

## 2.1.6

Merges upstream `gromedev/mgx` 2.1.2 through 2.1.5. The module name, version line, target framework, CI and examples remain this fork's. The version jumps from 2.1.1 to 2.1.6 so the two version lines stop colliding: upstream had already released its own 2.1.2.

### Fixed

- A Graph error reported only its top level message, which for a validation failure is only `The request is invalid.`, while the property that was actually wrong sat in the `innerError` of the response and was discarded. `GraphServiceException` now appends that message and exposes it as `InnerErrorMessage`. Upstream does not carry this.

### From upstream

- Request bodies serialize correctly for enums, byte arrays, `TimeSpan`, `DateTime` without a `Kind`, `PSCustomObject` members and non-ASCII text, and refuse `SecureString`, credentials, script blocks and self-referencing objects with an explicit error instead of reflection noise or a stack overflow.
- URI and header handling: no double encoding of pre-encoded `-Filter`, `-Search`, `-Property`, `-Sort` and `-ExpandProperty`, `#` no longer truncates a path, absolute `-Uri` inputs are preserved, array `-Headers` values are sent, content headers are kept, and a caller's `client-request-id` is left alone.
- Response handling: 204 and empty bodies, HTML and other non-JSON bodies, unparseable JSON, a UTF-8 BOM and a declared charset are all handled without an unhandled exception.
- Failure classification is unified across retries, circuit breaking, batch retry, content download and adaptive pacing, and error records carry a specific `ErrorCategory` rather than `NotSpecified`.
- `Invoke-MgxBatchRequest` writes a per-item error record for every failed item, halts on a chunk refusal, reports never-sent items as such, and keeps applied server writes out of the dead-letter file.
- Dead-letter files and `-Debug` traces redact the same pre-authenticated URLs and sensitive names, and an unwritable dead-letter path is refused before the batch is sent.
- `Export-MgxCollection` and `Sync-MgxDelta` no longer let a second run resume the same interrupted operation, reject checkpoints belonging to another run or an older release, and stop with the files as found rather than re-enumerating over them.

### Changed

- The engine and cmdlet sources now follow upstream's wording again. The fork's earlier comment rewrites were cosmetic and cost a conflict on every upstream release.

## 2.1.1

Expand Down
2 changes: 1 addition & 1 deletion Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project>

<PropertyGroup>
<Version>2.1.1</Version>
<Version>2.1.7</Version>
<Authors>Thomas Maillo Grome, Fabien Tschanz</Authors>
<Company>Mgx</Company>
<Copyright>(c) 2026 Thomas Maillo Grome, (c) 2026 Fabien Tschanz. All rights reserved.</Copyright>
Expand Down
12 changes: 10 additions & 2 deletions Modules/M365DSC.mgx/M365DSC.mgx.psd1
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@{
@{
RootModule = 'M365DSC.mgx.psm1'
ModuleVersion = '2.1.1'
ModuleVersion = '2.1.7'
GUID = 'f978315f-75c0-48f5-b929-ca7a7757d1d2'
Author = 'Thomas Maillo Grome, Fabien Tschanz'
CompanyName = 'Mgx'
Expand Down Expand Up @@ -49,6 +49,14 @@
LicenseUri = 'https://github.com/Microsoft365DSC/mgx/blob/main/LICENSE'
ProjectUri = 'https://github.com/Microsoft365DSC/mgx'
ReleaseNotes = @'
v2.1.7
- Added Invoke-MgxRequest -Envelope, emitting the payload as the service sent it, collection envelope and all, so a collection holding one item can be told from a single entity.
- Fixed the batch retry loop waiting out its exponential fallback without regard for MaxRetryAfterSeconds, which capped only the delays a server asked for.

v2.1.6
- Merged upstream gromedev/mgx 2.1.2 through 2.1.5.
- Fixed a Graph error reporting only its top level message: the property that was actually wrong sat in the innerError of the response and was discarded.

v2.1.1
- Fixed Invoke-MgxRequest failing with a missing System.IO.Pipelines assembly on PowerShell 7.6 hosts that do not ship it.

Expand Down
Loading
Loading