Skip to content
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

[Feature request]: Stabilize iOS support #244

Open
1 task done
attzonko opened this issue Aug 9, 2022 · 47 comments · Fixed by #587
Open
1 task done

[Feature request]: Stabilize iOS support #244

attzonko opened this issue Aug 9, 2022 · 47 comments · Fixed by #587
Assignees
Labels
enhancement Small enhancements to existing features help wanted Extra attention is needed

Comments

@attzonko
Copy link

attzonko commented Aug 9, 2022

Update

Initial iOS support was merged.
Download here!
Click here to get to the latest update.


Is your feature request related to a problem? Please describe

No response

Describe your feature request!

Amazing work! Do you have any plans to add an iOS app and support using the Apple Pencil? If not would you consider it?

Additional context

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@attzonko attzonko added the enhancement Small enhancements to existing features label Aug 9, 2022
@CodeDoctorDE CodeDoctorDE moved this to 📕 Todo in Butterfly Aug 9, 2022
@CodeDoctorDE
Copy link
Member

Hello,

iOS and Mac support (#191) are planned.
But unlike mac, you need an apple developer account to get apps on the iPhone.
For android you don't need to register and if you want you only need to play 15$ once.
On apple you need to pay 99$ yearly. I can't afford this.
Do you have any other ideas how I can do this without paying this yearly?

@CodeDoctorDE
Copy link
Member

For now you can use the web version: https://butterfly.linwood.dev
It has the same functionality and you can use it offline.

@CodeDoctorDE CodeDoctorDE added the help wanted Extra attention is needed label Aug 9, 2022
@MrDrache333
Copy link

Hello,

iOS and Mac support (#191) are planned.

But unlike mac, you need an apple developer account to get apps on the iPhone.

For android you don't need to register and if you want you only need to play 15$ once.

On apple you need to pay 99$ yearly. I can't afford this.

Do you have any other ideas how I can do this without paying this yearly?

Maybe with Patreon? Or just Support via PayPal, BuyMeACoffe etc.?

@CodeDoctorDE
Copy link
Member

That's planned. But I don't know if I'll make a minus financially then. It needs to pay yearly and if I want to have a partreon/paypal, I want to have some money for me. Additionally I need to buy a mac to test it and look if everything works. And a mac costs more than 1000€ https://www.apple.com/de/mac/
Additionally the web version has all features as the native version and I can test it on my linux/windows device. Safari has also the feature to let it run offline: https://caniuse.com/?search=service%20worker.

@MrDrache333
Copy link

That's planned. But I don't know if I'll make a minus financially then. It needs to pay yearly and if I want to have a partreon/paypal, I want to have some money for me. Additionally I need to buy a mac to test it and look if everything works. And a mac costs more than 1000€ https://www.apple.com/de/mac/

Additionally the web version has all features as the native version and I can test it on my linux/windows device. Safari has also the feature to let it run offline: https://caniuse.com/?search=service%20worker.

For an affordable Mac take a look at scaleway.com. There you're able to rent a mac mini for a couple of euros per month. I've used it for some time and it works perfectly 😄👍🏻 And it's definitely cheaper then buying a mac yourself 😄

@attzonko
Copy link
Author

Does the web version work with the Pencil?

@CodeDoctorDE
Copy link
Member

Should be, you can try it. I tested it on windows and linux and it works fine

Repository owner moved this from 📕 Todo to ✅ Done in Butterfly Aug 25, 2022
@CodeDoctorDE
Copy link
Member

Please let it open that other users can find it too

@CodeDoctorDE CodeDoctorDE reopened this Aug 25, 2022
Repository owner moved this from ✅ Done to 🚧 In Progress in Butterfly Aug 25, 2022
@CodeDoctorDE CodeDoctorDE moved this from 🚧 In Progress to 📕 Todo in Butterfly Sep 20, 2022
@xmha97
Copy link

xmha97 commented May 19, 2023

I bought an iPad to install this app.

I thought that Apple App Store, like Google Play Store, only takes money from developers once, but now that I understand, I don't want to use it anymore.

Apple's store system is very bad and causes no free or open source apps to be made for iOS.

I hope that in the next version of iPadOS (iOS) it will be possible to sideload apps.

(Sorry for my bad English)

@CodeDoctorDE
Copy link
Member

Oh yeah. In europe ios needs to be able to sideload apps. I hope I can add support for ios after that

@thomastthai
Copy link

You can run MacOS in a VM on Proxmox.

@CodeDoctorDE
Copy link
Member

I tried it but I didnt get metal to work and flutter currently only supports metal

@thomastthai
Copy link

Temporary solution, downgrade Flutter to the last working version until they fix the situation. That atleast gets you going.

@CodeDoctorDE
Copy link
Member

CodeDoctorDE commented Dec 18, 2023

Hmm,
I don't know if this is worth my time. Apple puts a thousand hurdles in front of me and I don't know how I can get it running.
Downgrading doesn't help because I'm using the latest features of flutter and I don't know where they introduced it. The web version is one solution for ios users that wants to use my app.
I'm open for any prs that fixes it

@thomastthai
Copy link

Sorry, Apple's wall garden sucks.

@CodeDoctorDE
Copy link
Member

Sorry for the bad updates, but...
Apple is making bad decisions to comply to the eu regulations...
https://www.youtube.com/watch?v=cVEbxpOE13s
I won't pay a runtime fee for a free app

@thomastthai
Copy link

I wished those people who buy Apple products realize the corporate behaviors they are supporting. It comes down to greed.

I need to buy a Mac Mini or MacBook Air to develop an app. Not looking forward to paying $100/year on top of 15-30% Apple tax.

@fritzlb
Copy link
Contributor

fritzlb commented Feb 8, 2024

If you own a mac and an Apple ID you can develop for iOS (without paying anything), just not distribute the app using the appstore. It is sufficient to log in to developer.apple.com once and accept the terms. distributing an ipa isn't that uncommon for projects that simply aren't allowed on the app store (UTMapp is an example). The issue I see with app store distribution is (apart from apples bs with their fees) the license, afaik gplv3 (and therefore agplv3) are fundamentally incompatible with apples terms

@CodeDoctorDE
Copy link
Member

CodeDoctorDE commented Feb 8, 2024

Hmm, I wouldn't change the license, I like the license for a end user application.
And I wouldn't pay money for a platform where I don't know any device. I heard the app needs to be also verified and signed if you distribute it with a file?

@fritzlb
Copy link
Contributor

fritzlb commented Feb 9, 2024

Yesn‘t. You can (with apples new terms and runtime fees) get the app signed and then everyone can sideload it using an alternative App Store, but that’s not what I meant. Everyone with an Apple ID can sideload up to 3 apps to their devices, but the certificates do expire after about a week or so. There are tools like sideloadly or AltStore that run on a pc in your local network and automatically refresh the app certificates once in a while. So in theory it would be possible to distribute an unsigned ipa file and everyone who‘d like to install it has to sign it themselves - either with a paid dev account, then the certs last one year or with a free account, then they‘ll have to renew every week.
Still not nice what Apple does to their developers

@CodeDoctorDE
Copy link
Member

CodeDoctorDE commented Feb 9, 2024

No problem. There is no hurry. I assigned you to this issue so I can see that's your issue

@CodeDoctorDE CodeDoctorDE removed their assignment Feb 9, 2024
@fritzlb
Copy link
Contributor

fritzlb commented Feb 9, 2024

Okay, the ipa does build in my fork. It's not pretty (yet) and the app is quite large, by setting the minimum ios version to something like 14.4+ we could probably get our file size down from ~90mb to ~30mb.

@CodeDoctorDE
Copy link
Member

Wow that's wonderful. Can you test if everything works fine on it?
90mb is really quite large but removing an 3 year old operating version isn't good. I'm also supporting windows 7 and android 5.
How about releasing 2 binaries: one smaller with 14.4+ requirement and one for older devices?
You could solve this for example by creating a script in app/scripts and replacing it with higher requirements

@fritzlb
Copy link
Contributor

fritzlb commented Feb 9, 2024

for some reason compiling locally reduces file sizes by a lot for me, with the right settings (14.4+) I got the file size down to 16mb, while compiling using github actions creates files with ~80mb. two binaries would be an option, idk how xcode stores the minimum ios version and idk either how to change it with a script or sth.
anyway... the app needs a lot of work before ios becomes usable, importing packages is impossible, trying to use the camera will result in a crash, including images doesn't work, ...
maybe a dependency isn't compatible with ios or requires a newer minimum version?
also the build number isn't the app version number right now

@CodeDoctorDE
Copy link
Member

I commented on this issue. Can you look if the min requirements are at iOS if it is set to iOS 12?
Also to work with imports, we need to add Uniform Type Identifiers to all XTypeGroups (you can search for this in the code. If you are familiar with this you can add this in your pr, otherwise I will try adding it after that

@CodeDoctorDE CodeDoctorDE linked a pull request Feb 10, 2024 that will close this issue
@CodeDoctorDE CodeDoctorDE changed the title [Feature request]: iOS App + Pencil Support [Feature request]: Stabilize iOS support Feb 10, 2024
@CodeDoctorDE
Copy link
Member

CodeDoctorDE commented Feb 10, 2024

Update 2024-02-10:

Initial iOS support was merged. It will be available in nightly versions starting with 2.0.3-rc.1! I renamed this issue to better reflect the current state. Please report all iOS problems here. I will post updates here to the current status. After stabilizing, this issue will get closed and all issues should be reported as normal issue.
Known issues:

  • Exporting document, images and svg does not work

@fritzlb
Copy link
Contributor

fritzlb commented Feb 10, 2024

Just tested the build, works beautifully so far!
As for the camera thing simply adding the camera permission nscamerausagedescription to info.plist doesn‘t change anything except that the apps asks for camera permissions before crashing
Also export seems to be broken

@CodeDoctorDE
Copy link
Member

It should already be fixed in the latest commit. Can you test it and maybe debug it?
Here is a guide for this: https://docs.flutter.dev/tools/vs-code#run-app-with-breakpoints, https://docs.flutter.dev/platform-integration/ios/ios-debugging or maybe it works with xcode?

@fritzlb
Copy link
Contributor

fritzlb commented Feb 10, 2024

Camera works. Export doesn't.
Here is a file with all logs I could collect:
bterfly.txt

for exporting the document it seems like "Only support loading options for CKShare and SWY types." is the issue
for exporting svg creating the image already seems like an issue, idk if iOS supports creating svgs at all
exporting an image doesn't work bc of some entitlements if I interpret the log correctly, probably something similar as with the camera.
pdf seems like a similar issue like exporting a document.
changing the quality in the print dialog might crash the app, but the iOS print window does open and actually can be used to export a pdf.

@CodeDoctorDE CodeDoctorDE pinned this issue Feb 10, 2024
@CodeDoctorDE
Copy link
Member

I think I fixed it in 965eb0b. Can you try it?

@fritzlb
Copy link
Contributor

fritzlb commented Feb 10, 2024

log.txt
nope, different errors but same result.

@CodeDoctorDE
Copy link
Member

okay, now it should finally be fixed 4fc05ef

Btw: the camera also needs to have microphone permission for some reason, maybe this was the fix

@fritzlb
Copy link
Contributor

fritzlb commented Feb 10, 2024

exporting bfly does work but throws errors, the rest doesn't.

error.txt
for exporting images it seems like there is still a permission error
...and my Xcode is taking about 70GB of storage again for pretty much nothing with no easy way to delete it, now I know again why I didn't like iOS development.

@CodeDoctorDE
Copy link
Member

CodeDoctorDE commented Feb 11, 2024

Okay thanks for testing. I couldn't help you with xcode, I don't have any experience with this.
The exportPdf should be fixed now.
Can you join the discord/matrix so we can look at it, otherwise this issue can get very large

@Lenni-builder
Copy link

What about publishing this to TestFlight? I know a few iPad users who'd like to try this out, but yideloading is too complicated for them.

@fritzlb
Copy link
Contributor

fritzlb commented May 11, 2024

I'm pretty sure that's against the AGPL v3 (cause nobody's able to run modified code on their devices because of codesigning with Apple)
Long story short: apple isn't developer friendly, especially not open source developer friendly

@CodeDoctorDE
Copy link
Member

For a testflight system I also need a developer account which costs me too much money for this what it's worth.
Apple is the most closed system I could know of. The eu has tried their best to open it a bit but it doesn't help. In the eu you also need to pay install fees if you didn't push it to the appstore.

@Lenni-builder
Copy link

Oh right, that Apple and GPL thing...

@Lenni-builder
Copy link

For a testflight system I also need a developer account which costs me too much money for this what it's worth. Apple is the most closed system I could know of. The eu has tried their best to open it a bit but it doesn't help. In the eu you also need to pay install fees if you didn't push it to the appstore.

Yes, I also hate Apple, but sadly their products are very popular, especially in German schools for some reason.

@CodeDoctorDE
Copy link
Member

Yeah I can agree. I was also on a german school and they all had ipads. The only thing you can do to run butterfly on these devices is to use the webversion sadly

@Lenni-builder
Copy link

I don't know if it's a Flutter or Safari/WebKit issue, but the web version is as good as unusable on iPads

@CodeDoctorDE
Copy link
Member

Welcome to the Apple news :)

The eu doesn't like what apple does with their new rules: https://ec.europa.eu/commission/presscorner/detail/en/IP_24_3433
I hope they will change their rules on their os so I can finally support ios/ipad os officially

@fritzlb
Copy link
Contributor

fritzlb commented Jun 24, 2024

Just read about that but I kinda fear it'll take a long time.

@Obi-Wahn
Copy link

does anyone have an ipad with ios 18 and is in the eu? There should be new possibilities with AltStore:

https://techcrunch.com/2024/09/13/alternative-app-stores-allowed-on-the-ipad-in-the-eu-starting-september-16/

@fritzlb
Copy link
Contributor

fritzlb commented Sep 28, 2024

I do! Already installed AltStore which works pretty well. The issue with a paid developer account and mac persists tho and while it seems like Apple is finally waiving the stupid ‘core technology fee‘ for developers that only publish free apps, all the hassle with app review remains.
Also they didn’t change their DRM or TOS which means there’s a risk that every contributor (even of only a few lines of code) could take down the app at any time

To properly support iOS it’d need for every contributor to sign an alternative license that allows distribution via app store/alternative stores, at least 500€/year for hardware, apples developer subscription and a lot of time to deal with app review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Small enhancements to existing features help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

8 participants