Comments (24)
I have the same problem.
On getRegionInfoFromPhoneNumber has flutter: PlatformException(1, The country code is invalid., null, null) on iOS.
On Android works fine.
from intl_phone_number_input.
@emillenard Sorry, I'll look into the issue today and see if I can get @natintosh to push some fixes out on this and other issues. Meanwhile, fixes PRs will be welcomed if anyone can help with fixing some of the issues created.
from intl_phone_number_input.
@emillenard @hrishikeshpujari1902 How to apply the fix the the swift file? Where is it? We need urgent fix in production. Is there a previous version which works fine?
@hrishikeshpujari1902
hi, is not the best approach, but for quick fix to production until will be ok in library i changed the file from Pods , you will find the SwiftLibphonenumberPlugin.swift in Xcode on Pods/PhonKitNumber folder , change it and then compile the version.
from intl_phone_number_input.
I have both problems
from intl_phone_number_input.
I have the same issue with the latest version
from intl_phone_number_input.
The quiq fix for me was to change in library:
Changes in: input_widget.dart line 184
From: "String phoneNumber = await PhoneNumber.getParsableNumber(widget.initialValue!);"
To: "String phoneNumber = widget.initialValue!.parseNumber();"
Changes in: SwiftLibphonenumberPlugin.swift
line 81
From: "let countryCode: String? = phoneNumberKit.mainCountry(forCode: p.countryCode)"
To: "let countryCode = "+" + String(p.countryCode)"
line 77:
From: "let p: PhoneNumber = try phoneNumberKit.parse(phoneNumber, withRegion: isoCode.uppercased(), ignoreType: true)"
To:" let p: PhoneNumber = try phoneNumberKit.parse(phoneNumber)"
from intl_phone_number_input.
For fix use older version dependency
dependency_overrides:
libphonenumber_plugin: 0.2.3
from intl_phone_number_input.
Having the same issue :(
from intl_phone_number_input.
Having the same issue too
from intl_phone_number_input.
Having the same issue
from intl_phone_number_input.
Having the same issue
from intl_phone_number_input.
Having the same issue
Any update?
from intl_phone_number_input.
Nobody seems to care about this problem.
from intl_phone_number_input.
@bynalab thanks, i found the problem, is in phone_number.dart the regionInfo.regionPrefix is the same with regionInfo.isoCode on iOS.
from intl_phone_number_input.
@bynalab thanks, i found the problem, is in phone_number.dart the regionInfo.regionPrefix is the same with regionInfo.isoCode on iOS.
Do you have any solution?
from intl_phone_number_input.
@emillenard SwiftLibphonenumberPlugin.swift where is this file located
from intl_phone_number_input.
@emillenard @hrishikeshpujari1902 How to apply the fix the the swift file? Where is it? We need urgent fix in production.
Is there a previous version which works fine?
from intl_phone_number_input.
@natintosh @bynalab Is there a workaround to be had? Will appreciate a fix for this ASAP!
from intl_phone_number_input.
@tigrenok00
Do these changes in the local pub cache as a temporary fix.
It will not format the number like added spaces in between but it wont add the extra country code as well.
Changes in: input_widget.dart line 184
From: "String phoneNumber = await PhoneNumber.getParsableNumber(widget.initialValue!);"
To: "String phoneNumber = widget.initialValue!.parseNumber();"
from intl_phone_number_input.
I got same errors as above.
can someone explain why this happens? Because I did not upgrade the package, still in version 0.7.0+2 since the first day, and now it suddenly breaks. Thanks
from intl_phone_number_input.
@emillenard @hrishikeshpujari1902 How to apply the fix the the swift file? Where is it? We need urgent fix in production. Is there a previous version which works fine?
@hrishikeshpujari1902hi, is not the best approach, but for quick fix to production until will be ok in library i changed the file from Pods , you will find the SwiftLibphonenumberPlugin.swift in Xcode on Pods/PhonKitNumber folder , change it and then compile the version.
can you explain clearly what you did exactly ?
from intl_phone_number_input.
+1
from intl_phone_number_input.
For fix use older version dependency
dependency_overrides: libphonenumber_plugin: 0.2.3
This worked for our project, thank you
Flutter 2.8.1
intl_phone_number_input 0.7.0+2
libphonenumber_plugin 0.2.3
(downgraded from 0.2.5)
from intl_phone_number_input.
For fix use older version dependency
dependency_overrides: libphonenumber_plugin: 0.2.3
This does not sounds like a long-term fix since we would be stuck with the old dependency and its transitive dependencies.
Is there a better way to solve this issue or should we just wait for the next libphonenumber_plugin version?
from intl_phone_number_input.
Related Issues (20)
- isoCode: 'MA' validators accept only 06 prefix !
- Allow Usage of ISO Codes Instead of Country Logos in the Leading of Input Field
- Version soloving failed
- Material 3 SubTitle Style is Deprecated . can you please change as per the Material 3 and Make a Release HOT 2
- Change the type of initCountry to String
- validatorMessage doesnt appear if is different of AutovalidateMode.always or doesnt triggered onChanged
- Not compatible with xcode 15 phonenumberkit deployment target 12 HOT 8
- Add Korean Translation Support
- PROJECT STILL ACTIVE?? kindly update please
- Programmatically change selected country code, or fill fields (flag and text input) using PhoneNumber
- selector customization needed HOT 1
- I
- IOS error : Compiling for iOS 11.0, but module 'PhoneNumberKit' has a minimum deployment target of iOS 12.0:
- In IOS, white backgroud while selecting coundtry code
- search dialog need to customize the search field style
- include curaçao
- flag with initial country code width
- Bum js version HOT 1
- Support for +993 71 123456 Phone Numbers (Turkmenistan)
- validator is not triggered on _formKey.currentState!.validate()
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from intl_phone_number_input.