Skip to content

Commit dc6faa9

Browse files
Sloader update on _data/OpenXml.json
1 parent 08026fe commit dc6faa9

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

_data/OpenXml.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"Data":{"Sdk":{"Events":[{"Id":"5936259121","Type":"IssuesEvent","CreatedAt":"2026-01-20T17:14:02","Actor":"mikeebowen","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"closed","RelatedUrl":"https://github.com/dotnet/Open-XML-SDK/issues/1931","RelatedDescription":"Closed issue \"Remove usage of Newtonsoft in favor of System.Text\" (#1931) at dotnet/Open-XML-SDK","RelatedBody":"**Is your feature request related to a problem? Please describe.**\nWe currently have both Newtonsoft and System.Text.Json and only should use one.\n\n**Describe the solution you'd like**\nRemove Newtonsoft.JSON and replace usage and associated code/data with System.Text.Json compliant stuff\n"},{"Id":"5936258771","Type":"PullRequestEvent","CreatedAt":"2026-01-20T17:14:00","Actor":"mikeebowen","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"merged","RelatedUrl":null,"RelatedDescription":null,"RelatedBody":null},{"Id":"5835593746","Type":"IssuesEvent","CreatedAt":"2026-01-15T14:58:52","Actor":"mkaszewiak","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"closed","RelatedUrl":"https://github.com/dotnet/Open-XML-SDK/issues/1972","RelatedDescription":"Closed issue \"SpreadsheetDocument.Save() throws OpenXmlPackageException when saving .xlsb file due to unexpected styles.bin content type\" (#1972) at dotnet/Open-XML-SDK","RelatedBody":"\n### Describe the bug\n\nSaving an `.xlsb` opened via `SpreadsheetDocument` throws an `OpenXmlPackageException` about an unexpected content type for `/xl/styles.bin`. This occurs even if no modifications are made; simply opening and calling `Save()` triggers the error for `.xlsb`. The same code path works for `.xlsx` and `.xlsm`.\n\n### Exception\n\n```\nDocumentFormat.OpenXml.Packaging.OpenXmlPackageException: 'The document cannot be opened because there is an invalid part with an unexpected content type. \n[Part Uri=/xl/styles.bin], \n[Content Type=application/vnd.ms-excel.styles], \n[Expected Content Type=application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml].'\n```\n\n\nA temporary workaround is to force-get all public properties of the SpreadsheetDocument instance before saving; after doing so, Save() succeeds.\n\n### Screenshots\n\nN/A\n\n### To Reproduce\n\nA self-contained, minimal repro (console app):\n\n```\nusing DocumentFormat.OpenXml.Packaging;\n\nvar filePath = @\"PathToXlsb\\Book1.xlsb\";\nvar fileBytes = File.ReadAllBytes(filePath);\n\nvar stream = new MemoryStream();\nstream.Write(fileBytes, 0, fileBytes.Length);\nstream.Position = 0;\n\nusing var spreadsheetDocument = SpreadsheetDocument.Open(stream, true);\n\n// works with this solution\n//foreach (var prop in spreadsheetDocument.GetType().GetProperties())\n//{\n// try\n// {\n// _ = prop.GetValue(spreadsheetDocument);\n// }\n// catch { }\n//}\n\n// Throws exception\nspreadsheetDocument.Save();\n```\n\n\n### Steps\n\n1. Open any `.xlsb` file with `SpreadsheetDocument.Open(stream, true)`.\n2. Immediately call `spreadsheetDocument.Save()`.\n3. Observe the `OpenXmlPackageException`.\n\n### Observed behavior\n\nAccessing all public properties on `SpreadsheetDocument` prior to saving (reflection-based getter loop) makes the save succeed.\n\n### Expected behavior\n\nOpening a valid `.xlsb` file, optionally modifying custom properties, and calling `Save()` should succeed without requiring any reflection-based workarounds.\n\n### Desktop (please complete the following information)\n\n- OS: Windows 11 Home (26100.2033)\n- Office version: N/A (repro does not require Office; opening/saving via SDK)\n- .NET Target: .NET 8 and .NET 10 (both reproduce)\n- DocumentFormat.OpenXml Version(s) tested: 3.3.0, 3.2.0, 3.1.1, 3.0.2, 3.0.1\n\n### Additional context\n\n- Only happens with `.xlsb`. The same code works for `.xlsx` and `.xlsm`.\n- The behavior cannot be reproduced with `WordprocessingDocument` or `PresentationDocument` for their respective formats.\n- The workaround (calling getters for all public properties on `SpreadsheetDocument`) suggests a lazy-loading/initialization or part registration issue specific to `.xlsb` styles content types."},{"Id":"5835420473","Type":"IssuesEvent","CreatedAt":"2026-01-15T14:52:10","Actor":"mkaszewiak","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"assigned","RelatedUrl":"https://github.com/dotnet/Open-XML-SDK/issues/1972","RelatedDescription":null,"RelatedBody":"\n### Describe the bug\n\nSaving an `.xlsb` opened via `SpreadsheetDocument` throws an `OpenXmlPackageException` about an unexpected content type for `/xl/styles.bin`. This occurs even if no modifications are made; simply opening and calling `Save()` triggers the error for `.xlsb`. The same code path works for `.xlsx` and `.xlsm`.\n\n### Exception\n\n```\nDocumentFormat.OpenXml.Packaging.OpenXmlPackageException: 'The document cannot be opened because there is an invalid part with an unexpected content type. \n[Part Uri=/xl/styles.bin], \n[Content Type=application/vnd.ms-excel.styles], \n[Expected Content Type=application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml].'\n```\n\n\nA temporary workaround is to force-get all public properties of the SpreadsheetDocument instance before saving; after doing so, Save() succeeds.\n\n### Screenshots\n\nN/A\n\n### To Reproduce\n\nA self-contained, minimal repro (console app):\n\n```\nusing DocumentFormat.OpenXml.Packaging;\n\nvar filePath = @\"PathToXlsb\\Book1.xlsb\";\nvar fileBytes = File.ReadAllBytes(filePath);\n\nvar stream = new MemoryStream();\nstream.Write(fileBytes, 0, fileBytes.Length);\nstream.Position = 0;\n\nusing var spreadsheetDocument = SpreadsheetDocument.Open(stream, true);\n\n// works with this solution\n//foreach (var prop in spreadsheetDocument.GetType().GetProperties())\n//{\n// try\n// {\n// _ = prop.GetValue(spreadsheetDocument);\n// }\n// catch { }\n//}\n\n// Throws exception\nspreadsheetDocument.Save();\n```\n\n\n### Steps\n\n1. Open any `.xlsb` file with `SpreadsheetDocument.Open(stream, true)`.\n2. Immediately call `spreadsheetDocument.Save()`.\n3. Observe the `OpenXmlPackageException`.\n\n### Observed behavior\n\nAccessing all public properties on `SpreadsheetDocument` prior to saving (reflection-based getter loop) makes the save succeed.\n\n### Expected behavior\n\nOpening a valid `.xlsb` file, optionally modifying custom properties, and calling `Save()` should succeed without requiring any reflection-based workarounds.\n\n### Desktop (please complete the following information)\n\n- OS: Windows 11 Home (26100.2033)\n- Office version: N/A (repro does not require Office; opening/saving via SDK)\n- .NET Target: .NET 8 and .NET 10 (both reproduce)\n- DocumentFormat.OpenXml Version(s) tested: 3.3.0, 3.2.0, 3.1.1, 3.0.2, 3.0.1\n\n### Additional context\n\n- Only happens with `.xlsb`. The same code works for `.xlsx` and `.xlsm`.\n- The behavior cannot be reproduced with `WordprocessingDocument` or `PresentationDocument` for their respective formats.\n- The workaround (calling getters for all public properties on `SpreadsheetDocument`) suggests a lazy-loading/initialization or part registration issue specific to `.xlsb` styles content types."},{"Id":"5828794188","Type":"IssuesEvent","CreatedAt":"2026-01-15T10:04:50","Actor":"mkaszewiak","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"labeled","RelatedUrl":"https://github.com/dotnet/Open-XML-SDK/issues/1968","RelatedDescription":null,"RelatedBody":"Exception type: `InvalidOperationException`\n\nException message: `\"Specified part does not exist in the package.\"`\n\nStack trace:\n> at System.IO.Packaging.Package.GetPart(Uri partUri)\n> at DocumentFormat.OpenXml.Features.PackageFeatureBase.DocumentFormat.OpenXml.Packaging.IPackage.GetPart(Uri uriTarget)\n> at DocumentFormat.OpenXml.Packaging.Builder.DelegatingPackageFeature.GetPart(Uri uriTarget)\n> at DocumentFormat.OpenXml.Packaging.Builder.DelegatingPackageFeature.GetPart(Uri uriTarget)\n> at DocumentFormat.OpenXml.Packaging.PackageUriHandlingExtensions.MalformedUriHandlingPackage.GetPart(Uri uriTarget)\n> at DocumentFormat.OpenXml.Packaging.OpenXmlPart.Load(OpenXmlPackage openXmlPackage, OpenXmlPart parent, Uri uriTarget, String id)\n> at DocumentFormat.OpenXml.Packaging.PartRelationshipsFeature.LoadReferencedPartsAndRelationships()\n> at DocumentFormat.OpenXml.Packaging.PartRelationshipsFeature.get_RelationshipMap()\n> at DocumentFormat.OpenXml.Packaging.PartRelationshipsFeature.DocumentFormat.OpenXml.Features.IPartRelationshipsFeature.get_Parts()\n> at DocumentFormat.OpenXml.Packaging.OpenXmlPart.FindAllReachableParts(IDictionary`2 reachableParts)\n> at DocumentFormat.OpenXml.Packaging.OpenXmlPart.FindAllReachableParts(IDictionary`2 reachableParts)\n> at DocumentFormat.OpenXml.Packaging.OpenXmlPart.FindAllReachableParts(IDictionary`2 reachableParts)\n> at DocumentFormat.OpenXml.Packaging.OpenXmlPackage.FindAllReachableParts(IDictionary`2 reachableParts)\n> at DocumentFormat.OpenXml.Packaging.OpenXmlPartContainer.DeletePartCore(String id)\n> at DocumentFormat.OpenXml.Packaging.OpenXmlPartContainer.DeletePart(String id)\n> at Jet.Nimbus.OpenXmlUtility.AddPartToDocument(String partId, String rootElementName, SpreadsheetDocument document, String xml) in C:\\repos\\NimbusEngine\\Jet.Nimbus\\OpenXmlUtility.cs:line 212\n\n\nHello, currently seeing a somewhat strange issue and was hoping for some insight on what could be causing it. \n\nIn our code, we check to see if a CustomXml part with a certain name exists, and if it does then we go ahead and delete that part from our `SpreadsheetDocument` object's `WorkbookPart` property. But even though it exists, that exception gets thrown. If we catch, log, and ignore the exception, I can see that the part with that specific name doesn't exist anymore in `WorkbookPart.ChildrenRelationshipParts`. So it looks like it deletes it from there but that exception gets thrown, but unclear why.\n\nHere is the really weird thing that I notice when debugging in Visual Studio is that if I hit a breakpoint right before the `DeletePart()` call and hover over my `SpreadsheetDocument` object and look into `WorkbookPart.ChildrenRelationshipParts` property and enumerate results in VS, then continue code execution, that exception above doesn't get thrown and it deletes the part just fine. I even tried to enumerate programmatically over the `Parts` property to see if that'll \"pre-load\" anything, but no avail. "}],"ResultType":"GitHubEvent"}},"RunOn":"2026-01-30T03:30:24.8548178Z","RunDurationInMilliseconds":720}
1+
{"Data":{"Sdk":{"Events":[{"Id":"6197281072","Type":"PullRequestEvent","CreatedAt":"2026-01-30T19:23:16","Actor":"dependabot[bot]","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"labeled","RelatedUrl":null,"RelatedDescription":null,"RelatedBody":null},{"Id":"6197280849","Type":"PullRequestEvent","CreatedAt":"2026-01-30T19:23:16","Actor":"dependabot[bot]","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"labeled","RelatedUrl":null,"RelatedDescription":null,"RelatedBody":null},{"Id":"6197280082","Type":"PullRequestEvent","CreatedAt":"2026-01-30T19:23:16","Actor":"dependabot[bot]","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"opened","RelatedUrl":null,"RelatedDescription":"Opened pull request \"\" (#2000) at dotnet/Open-XML-SDK","RelatedBody":null},{"Id":"6197151898","Type":"PullRequestEvent","CreatedAt":"2026-01-30T19:23:16","Actor":"dependabot[bot]","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"labeled","RelatedUrl":null,"RelatedDescription":null,"RelatedBody":null},{"Id":"6197151891","Type":"PullRequestEvent","CreatedAt":"2026-01-30T19:23:16","Actor":"dependabot[bot]","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"labeled","RelatedUrl":null,"RelatedDescription":null,"RelatedBody":null},{"Id":"5936259121","Type":"IssuesEvent","CreatedAt":"2026-01-20T17:14:02","Actor":"mikeebowen","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"closed","RelatedUrl":"https://github.com/dotnet/Open-XML-SDK/issues/1931","RelatedDescription":"Closed issue \"Remove usage of Newtonsoft in favor of System.Text\" (#1931) at dotnet/Open-XML-SDK","RelatedBody":"**Is your feature request related to a problem? Please describe.**\nWe currently have both Newtonsoft and System.Text.Json and only should use one.\n\n**Describe the solution you'd like**\nRemove Newtonsoft.JSON and replace usage and associated code/data with System.Text.Json compliant stuff\n"},{"Id":"5936258771","Type":"PullRequestEvent","CreatedAt":"2026-01-20T17:14:00","Actor":"mikeebowen","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"merged","RelatedUrl":null,"RelatedDescription":null,"RelatedBody":null},{"Id":"5835593746","Type":"IssuesEvent","CreatedAt":"2026-01-15T14:58:52","Actor":"mkaszewiak","Repository":"dotnet/Open-XML-SDK","Organization":"dotnet","RawContent":null,"RelatedAction":"closed","RelatedUrl":"https://github.com/dotnet/Open-XML-SDK/issues/1972","RelatedDescription":"Closed issue \"SpreadsheetDocument.Save() throws OpenXmlPackageException when saving .xlsb file due to unexpected styles.bin content type\" (#1972) at dotnet/Open-XML-SDK","RelatedBody":"\n### Describe the bug\n\nSaving an `.xlsb` opened via `SpreadsheetDocument` throws an `OpenXmlPackageException` about an unexpected content type for `/xl/styles.bin`. This occurs even if no modifications are made; simply opening and calling `Save()` triggers the error for `.xlsb`. The same code path works for `.xlsx` and `.xlsm`.\n\n### Exception\n\n```\nDocumentFormat.OpenXml.Packaging.OpenXmlPackageException: 'The document cannot be opened because there is an invalid part with an unexpected content type. \n[Part Uri=/xl/styles.bin], \n[Content Type=application/vnd.ms-excel.styles], \n[Expected Content Type=application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml].'\n```\n\n\nA temporary workaround is to force-get all public properties of the SpreadsheetDocument instance before saving; after doing so, Save() succeeds.\n\n### Screenshots\n\nN/A\n\n### To Reproduce\n\nA self-contained, minimal repro (console app):\n\n```\nusing DocumentFormat.OpenXml.Packaging;\n\nvar filePath = @\"PathToXlsb\\Book1.xlsb\";\nvar fileBytes = File.ReadAllBytes(filePath);\n\nvar stream = new MemoryStream();\nstream.Write(fileBytes, 0, fileBytes.Length);\nstream.Position = 0;\n\nusing var spreadsheetDocument = SpreadsheetDocument.Open(stream, true);\n\n// works with this solution\n//foreach (var prop in spreadsheetDocument.GetType().GetProperties())\n//{\n// try\n// {\n// _ = prop.GetValue(spreadsheetDocument);\n// }\n// catch { }\n//}\n\n// Throws exception\nspreadsheetDocument.Save();\n```\n\n\n### Steps\n\n1. Open any `.xlsb` file with `SpreadsheetDocument.Open(stream, true)`.\n2. Immediately call `spreadsheetDocument.Save()`.\n3. Observe the `OpenXmlPackageException`.\n\n### Observed behavior\n\nAccessing all public properties on `SpreadsheetDocument` prior to saving (reflection-based getter loop) makes the save succeed.\n\n### Expected behavior\n\nOpening a valid `.xlsb` file, optionally modifying custom properties, and calling `Save()` should succeed without requiring any reflection-based workarounds.\n\n### Desktop (please complete the following information)\n\n- OS: Windows 11 Home (26100.2033)\n- Office version: N/A (repro does not require Office; opening/saving via SDK)\n- .NET Target: .NET 8 and .NET 10 (both reproduce)\n- DocumentFormat.OpenXml Version(s) tested: 3.3.0, 3.2.0, 3.1.1, 3.0.2, 3.0.1\n\n### Additional context\n\n- Only happens with `.xlsb`. The same code works for `.xlsx` and `.xlsm`.\n- The behavior cannot be reproduced with `WordprocessingDocument` or `PresentationDocument` for their respective formats.\n- The workaround (calling getters for all public properties on `SpreadsheetDocument`) suggests a lazy-loading/initialization or part registration issue specific to `.xlsb` styles content types."}],"ResultType":"GitHubEvent"}},"RunOn":"2026-01-31T03:30:25.8641982Z","RunDurationInMilliseconds":740}

0 commit comments

Comments
 (0)