-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(client/cordova/apple/ios): fix failing release build for the cordova ios target #1840
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #1840 +/- ##
=======================================
- Coverage 40% 32% -8%
=======================================
Files 39 45 +6
Lines 1805 2610 +805
Branches 337 337
=======================================
+ Hits 738 859 +121
- Misses 1067 1751 +684
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
@@ -11,7 +11,6 @@ | |||
<key>com.apple.security.application-groups</key> | |||
<array> | |||
<string>group.org.outline.ios.client</string> | |||
<string>$(TeamIdentifierPrefix)org.outline.macos.client</string> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sbruens will this break mac Catalyst?
I don't understand why having this would break the build, since an app can be in multiple application groups. Perhaps we need to configure the application group to include the ios app.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
when it fails it says that the provision (org.outline.ios.client
) doesn't match what's in this group (e.g. the macos group). perhaps we can use the interpolation to change this at compile time?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will most likely break macOS, because they share this file.
Please wait for @sbruens to chime in.
Other than that, Makefile and pbxproj look good.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It will break catalyst because this app group is used in several places to share data between the network extension, launcher and host app, like the logs directory for Sentry and the tunnel store (see https://github.com/search?q=repo%3AJigsaw-Code%2Foutline-client%20%22QT8Z3Q9V3A.org.outline.macos.client%22&type=code).
Those values need to match the app groups the app has access to. I think we may be able to move catalyst over to use the ios app group but it would mean that the catalyst app would no longer use the existing mac paths for logs and tunnel store preferences, but that might be ok?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Btw I added those entitlements very recently: #1811
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps the iOS app provisioning profile needs to be updated online to add those groups?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the problem is that macOS groups are special and not managed in the Developer portal. So you can't even create an app group that doesn't start with group.
.
That app groups shouldn't be set on the iOS app anyway. But the XCode UI is weird where it automatically adds macOS app groups to the iOS section (but not the other way around?). Is there a way to set them in the release script?
I guess the best course of action would be to update those hard-coded values and move catalyst over to the iOS app group.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will the user lose their server list? That would be a very bad experience.
Perhaps we need separate projects? Can we have a per-platform plist?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think so. They are not stored under the app group.
@daniellacosse you should be able to check that by running the catalyst app after you change these values and checking that your servers show up.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure whether it's related (maybe not), but @sbruens and I discovered that the latest Gomobile behaves weirdly until a go get xxx/gomobile
is run targeting the root folder.
You shouldn’t use go get to install binaries, because who knows what
version you’ll use.
The right way is tools.go, pinned version on go.sum (use go mod tidy), then
go build.
…On Thu, Feb 22, 2024 at 8:11 PM J. Yi ***@***.***> wrote:
***@***.**** commented on this pull request.
Not sure whether it's related (maybe not), but @sbruens
<https://github.com/sbruens> and I discovered that the latest Gomobile
behaves weirdly until a go get xxx/gomobile is run targeting the root
folder.
------------------------------
In Makefile
<#1840 (comment)>
:
> @@ -23,7 +23,7 @@ $(BUILDDIR)/android/tun2socks.aar: $(GOMOBILE)
$(BUILDDIR)/ios/Tun2socks.xcframework: $(GOMOBILE)
# -iosversion should match what outline-client supports.
- $(GOBIND) -iosversion=11.0 -target=ios,iossimulator -o $@ -ldflags '-w' -bundleid org.outline.tun2socks $(IMPORT_PATH)/$(ROOT_PKG)/outline/tun2socks $(IMPORT_PATH)/$(ROOT_PKG)/outline/shadowsocks
+ $(GOBIND) -iosversion=12.0 -target=ios,iossimulator -o $@ -ldflags '-w' -bundleid org.outline.tun2socks $(IMPORT_PATH)/$(ROOT_PKG)/outline/tun2socks $(IMPORT_PATH)/$(ROOT_PKG)/outline/shadowsocks
Will this drop the support of iOS 11 ? If so, do we need to announce it
somewhere, maybe in Reddit?
—
Reply to this email directly, view it on GitHub
<#1840 (review)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAA3XHL7SH4G7YTS6ODDGZTYU7UFBAVCNFSM6AAAAABDLEALFOVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMYTQOJXGI2DSNZQHA>
.
You are receiving this because your review was requested.Message ID:
***@***.***>
|
I thought we had that and it wasn't working for some reason? I forget
On Thu, Feb 22, 2024 at 9:15 PM Vinicius Fortuna ***@***.***>
wrote:
… You shouldn’t use go get to install binaries, because who knows what
version you’ll use.
The right way is tools.go, pinned version on go.sum (use go mod tidy),
then
go build.
On Thu, Feb 22, 2024 at 8:11 PM J. Yi ***@***.***> wrote:
> ***@***.**** commented on this pull request.
>
> Not sure whether it's related (maybe not), but @sbruens
> <https://github.com/sbruens> and I discovered that the latest Gomobile
> behaves weirdly until a go get xxx/gomobile is run targeting the root
> folder.
> ------------------------------
>
> In Makefile
> <
#1840 (comment)>
> :
>
> > @@ -23,7 +23,7 @@ $(BUILDDIR)/android/tun2socks.aar: $(GOMOBILE)
>
> $(BUILDDIR)/ios/Tun2socks.xcframework: $(GOMOBILE)
> # -iosversion should match what outline-client supports.
> - $(GOBIND) -iosversion=11.0 -target=ios,iossimulator -o $@ -ldflags
'-w' -bundleid org.outline.tun2socks
$(IMPORT_PATH)/$(ROOT_PKG)/outline/tun2socks
$(IMPORT_PATH)/$(ROOT_PKG)/outline/shadowsocks
> + $(GOBIND) -iosversion=12.0 -target=ios,iossimulator -o $@ -ldflags
'-w' -bundleid org.outline.tun2socks
$(IMPORT_PATH)/$(ROOT_PKG)/outline/tun2socks
$(IMPORT_PATH)/$(ROOT_PKG)/outline/shadowsocks
>
> Will this drop the support of iOS 11 ? If so, do we need to announce it
> somewhere, maybe in Reddit?
>
> —
> Reply to this email directly, view it on GitHub
> <
#1840 (review)>,
> or unsubscribe
> <
https://github.com/notifications/unsubscribe-auth/AAA3XHL7SH4G7YTS6ODDGZTYU7UFBAVCNFSM6AAAAABDLEALFOVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMYTQOJXGI2DSNZQHA>
> .
> You are receiving this because your review was requested.Message ID:
> ***@***.***>
>
—
Reply to this email directly, view it on GitHub
<#1840 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AA4V5VHVSWWSVGBAWWUJQNDYU73S7AVCNFSM6AAAAABDLEALFOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNRQGY2DGNBSGE>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Please also let the QA team test the following behavior on macOS once the PR is merged:
- Install an old version
- Add some servers (
ss://
andssconf://
) - Upgrade to the new version
- Make sure all servers and configurations are still there
I'm gonna merge this, considering it's semi-blocking release |
I was getting multiple errors attempting to build the latest release for ios: