xcsync sync -tfm net9.0-ios issues after adding Widget Extension to generated project
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 38/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Domain
- mobile-dev, tooling
Research direction
Reproduce the failure by syncing a generated .NET 9 iOS project after adding a Widget Extension. Start with XcodeObjectConverter.cs at line 18 and XcodeProjectObjectsJsonConverter.cs at line 30, then follow XcodeWorkspace.LoadProjectAsync at line 261. Done means xcsync can load and sync the generated project without the unknown PBXCopyFilesBuildPhase exception.
Written by the indexing model from the issue text.
Description
Hello,
Generating and syncing an Xcode project for our .NET9 MAUI application is functioning without any issues for a basic application. However, as soon as I add the Widget Extension to that project, I encounter the following error:
[13:37:35 INF xcsync (1)] Syncing files from project 'obj/Debug/net9.0-ios/iossimulator-x64/xcsync' to target 'MyApp.UI.csproj'
Unhandled exception: System.Text.Json.JsonException: Unknown isa value: PBXCopyFilesBuildPhase
at xcsync.Projects.Xcode.XcodeObjectConverter.Read(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options) in /_/src/xcsync/Projects/Xcode/XcodeObjectConverter.cs:line 18
at xcsync.Projects.Xcode.XcodeProjectObjectsJsonConverter.Read(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options) in /_/src/xcsync/Projects/Xcode/XcodeProjectObjectsJsonConverter.cs:line 30
at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader)
at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
at System.Text.Json.Serialization.JsonConverter`1.ReadCore(Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state)
at System.Text.Json.Serialization.Metadata.JsonTypeInfo`1.ContinueDeserialize(ReadBufferState& bufferState, JsonReaderState& jsonReaderState, ReadStack& readStack)
at System.Text.Json.Serialization.Metadata.JsonTypeInfo`1.DeserializeAsync(Stream utf8Json, CancellationToken cancellationToken)
at xcsync.Projects.XcodeWorkspace.LoadProjectAsync(String path, CancellationToken cancellationToken) in /_/src/xcsync/Projects/XcodeWorkspace.cs:line 261
at xcsync.Projects.XcodeWorkspace.LoadAsync(CancellationToken cancellationToken) in /_/src/xcsync/Projects/XcodeWorkspace.cs:line 63
at xcsync.SyncContext.SyncFromXcodeAsync(CancellationToken token) in /_/src/xcsync/SyncContext.cs:line 484
at xcsync.SyncContext.SyncAsync(CancellationToken token) in /_/src/xcsync/SyncContext.cs:line 33
at xcsync.Commands.SyncCommand.Execute() in /_/src/xcsync/Commands/SyncCommand.cs:line 22
at System.CommandLine.Invocation.AnonymousCommandHandler.InvokeAsync(InvocationContext context)
at System.CommandLine.Invocation.InvocationPipeline.<>c__DisplayClass4_0.<<BuildInvocationChain>b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass17_0.<<UseParseErrorReporting>b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass12_0.<<UseHelp>b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass22_0.<<UseVersionOption>b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass19_0.<<UseTypoCorrections>b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c.<<UseSuggestDirective>b__18_0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass16_0.<<UseParseDirective>b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c.<<RegisterWithDotnetSuggest>b__5_0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass8_0.<<UseExceptionHandler>b__0>d.MoveNext()
Is this a known bug, or is it related to the fact that the Widget Extension is based on SwiftUI rather than Objective-C? Currently, I have a working .NET MAUI application with Live Activity support by creating a (separate) native Xcode project with the same BundleIdentifiers as the MAUI iOS app.
- Dominant language
- C#
- Stars
- 25
- Forks
- 10
- Avg merge
- 12h 50m
- Merged PRs (30d)
- 10
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from dotnet/xcsync
-
Difficulty 3/5 1-2 days Newbie friendliness 48/100
-
Difficulty 5/5 Over a week Newbie friendliness 20/100
-
Difficulty 3/5 1-2 days Newbie friendliness 55/100
-
Difficulty 3/5 1-2 days Newbie friendliness 45/100
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
Similar issues
-
[Feat] 조합 영역 구분선 개선 Open
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
type/automation type/tech-debt
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
t/bug
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
ci-failure-cause test-failure
Difficulty 2/5 1-3 hours Newbie friendliness 82/100