GithubHelp home page GithubHelp logo

Comments (16)

Nimrodda avatar Nimrodda commented on July 28, 2024 1

That's a great discovery and thank you so much for sharing it here. I wonder if this is a bug in latest Xcode or something. It should be possible to add it via the UI as well 🤔

from flutter_nsd.

Nimrodda avatar Nimrodda commented on July 28, 2024 1

from flutter_nsd.

Nimrodda avatar Nimrodda commented on July 28, 2024

from flutter_nsd.

guojunlong avatar guojunlong commented on July 28, 2024

Have you tried with iOS version before 14?

The version number of my ios device is 14.7.1, and the model is iPhone6s Plus

from flutter_nsd.

Nimrodda avatar Nimrodda commented on July 28, 2024

Please try on iOS simulator that runs iOS lower than 14. For example iOS 11. The requirement to add these entries in info.plist is only for iOS 14+. If it works on older versions then the issue is in your info.plist configuration.

from flutter_nsd.

guojunlong avatar guojunlong commented on July 28, 2024

Please try on iOS simulator that runs iOS lower than 14. For example iOS 11. The requirement to add these entries in info.plist is only for iOS 14+. If it works on older versions then the issue is in your info.plist configuration.

I tried to run the overload ios Simulator today, and I can get the local network permission. According to what you said, the problem should be in my info.plist file. Could you please help me find out what the problem is?

截屏2021-09-23 下午10 07 50

from flutter_nsd.

Nimrodda avatar Nimrodda commented on July 28, 2024

from flutter_nsd.

guojunlong avatar guojunlong commented on July 28, 2024

Looks about right. Have you tried with the example app?

Yes, I created a Flutter project and tested this function separately. Could you please help me find out what the problem is?

The device is iPhone 6S Plus and the system is 14.7.1. After running, click "Start" and there is no prompt for local network authorization.

https://github.com/guojunlong/untitled_test_nsd.git

from flutter_nsd.

Nimrodda avatar Nimrodda commented on July 28, 2024

I did a quick test with the example app and indeed I don't see the prompt on my iPhone. Nevertheless, it shows that Local Network permission is granted under Settings->Privacy->Local Network. I'll have to investigate this. Please let me know if you find anything. Thanks!

from flutter_nsd.

guojunlong avatar guojunlong commented on July 28, 2024

I did a quick test with the example app and indeed I don't see the prompt on my iPhone. Nevertheless, it shows that Local Network permission is granted under Settings->Privacy->Local Network. I'll have to investigate this. Please let me know if you find anything. Thanks!

Yes, I found the problem, you were right before, it is the info.plist file, it is the problem of "NSBonjourServices", open the info.plist file as "Source Code" and find
“Bonjour Services", change the Key value to "NSBonjourServices", and then run again to get the prompt of local network permission, but why the project does not recognize "BonjourServices", I do not know. If you know the reason, please tell me. Thank you

from flutter_nsd.

Nimrodda avatar Nimrodda commented on July 28, 2024

Which version of Xcode are you using? Mine is version 13.0 (13A233). For now I updated the README.md with example XML from Info.plist. I filed a bug report to Apple .

from flutter_nsd.

guojunlong avatar guojunlong commented on July 28, 2024

13.0 (13A233).

I use the same Xcode as your version, also 13.0 (13A233).

from flutter_nsd.

Nimrodda avatar Nimrodda commented on July 28, 2024

Are you able to reproduce this issue? Now when I add Bonjour Services via the UI and then inspect the source code it seems to be correct everytime. Really weird.

from flutter_nsd.

guojunlong avatar guojunlong commented on July 28, 2024

I use Xcode (13.0 (13a233)), test model: iPhone 6S plus, mobile phone system: 14.7.1,

When I add the key value “Bonjour Services" and the corresponding value in the string "Bonjour Services" through “Property List" or “Source Code", I will not be able to obtain the local network permission. However, if I add the key "Bonjour Services" and the corresponding value in the string “NSBonjourServices", Everything is normal. The difference between the two adding methods is that when we check the source code of info.plist, the key values are "Bonjour Services" and “NSBonjourServices"

I just tried, and the problem still exists

from flutter_nsd.

guojunlong avatar guojunlong commented on July 28, 2024

Originally, everything was normal, but when I needed to integrate the project into plugin packages, I could not obtain the local network permission in the ios environment. This time, the modification of the Key value did not work, but it still works in the Android environment,

Do you have any ideas on how to solve this situation?
@Nimrodda

from flutter_nsd.

Nimrodda avatar Nimrodda commented on July 28, 2024

My assumption is that you're facing the same issue you faced before in Xcode. Make sure that the source code of Info.plist indeed has the right piece of code there with the correct domain etc.

I'm closing this issue since it's not an issue in the plugin.

from flutter_nsd.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.