You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by GitBox <gi...@apache.org> on 2021/10/20 08:27:12 UTC

[GitHub] [cordova-plugin-device] Abhinav2903 opened a new issue #147: iPhone/ipad simulator model number are not accurate

Abhinav2903 opened a new issue #147:
URL: https://github.com/apache/cordova-plugin-device/issues/147


   # Bug Report
   
   ## Problem
   iPhone/ipad simulator model number not accurate
   ### What is expected to happen?
   While using the plugin we should get the exact mode number but getting 1 or 2 higher than the model present with some extra string number also
   Like for iphone 8 plus getting iphone10,5
   For iphone se getting iphone 12,3
   So it is giving me wrong info everytime 
   ### What does actually happen?
   It should give the exact device number
   
   
   ## Information
   <!-- Include all relevant information that might help understand and reproduce the problem -->
   
   Use Cordova plugin device
   
   ### Command or Code
   <!-- What command or code is needed to reproduce the problem? -->
   Import {Device} from "@ionic-native/device/ngx"
   ..
   Private deviceInfo: Device
   ..
   Console.log(this.deviceInfo.model)
   
   
   ### Environment, Platform, Device
   <!-- In what environment, on what platform or on which device are you experiencing the issue? -->
   
   Every iphone/ipad simulator
   
   ### Version information
   <!-- 
   What are relevant versions you are using?
   For example:
   Cordova: Cordova CLI, Cordova Platforms, Cordova Plugins 
   Other Frameworks: Ionic Framework and CLI version
   Operating System, Android Studio, Xcode etc.
   -->
   Xcode 13.0
   Ionic and capacitor with angular
   iPhone/ipad simulator
   
   
   
   ## Checklist
   <!-- Please check the boxes by putting an x in the [ ] like so: [x] -->
   
   - [x ] I searched for existing GitHub issues
   - [ x] I updated all Cordova tooling to most recent version
   - [x ] I included all the necessary information above
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


[GitHub] [cordova-plugin-device] erisu commented on issue #147: iPhone/ipad simulator model number are not accurate

Posted by GitBox <gi...@apache.org>.
erisu commented on issue #147:
URL: https://github.com/apache/cordova-plugin-device/issues/147#issuecomment-1085804252


   I also agree with @breautek,
   
   > If Apple provides an API to obtain the user-facing model version
   then maybe we could have:
   * Update the existing property to use the user-facing model version
   * Update the existing property response to append the user-facing model version. The current information might be important for other people
   * Create a new property to contain the user-facing model version.
   
   But, since there is no API as I am aware to fetch such information, I believe there is nothing we can do about it.
   
   As @breautek pointed out, someone had created a mapping to support something similar, but I feel this is something we should not manage. The reason why is because releases are not always frequent and could create downtime.
   
   You could reproduce this mapping in JS.
   
   If there is no additional feedback, I think we can close this ticket.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


[GitHub] [cordova-plugin-device] breautek commented on issue #147: iPhone/ipad simulator model number are not accurate

Posted by GitBox <gi...@apache.org>.
breautek commented on issue #147:
URL: https://github.com/apache/cordova-plugin-device/issues/147#issuecomment-947677185


   Looking at the code, I believe this is working as expected. These are apples model versions, which doesn't necessarily correspond with the actual phone/machine name.
   
   Apple doesn't provide an actual mapping afaik, but someone built a mapping [here](https://github.com/squarefrog/UIDeviceIdentifier/blob/master/UIDeviceIdentifier/UIDeviceHardware.m)
   
   However, I do agree that our documentation is not clear by this. If Apple provides an API to obtain the user-facing model version, I'd personally vote in favour of deprecating the current `model` attribute in favour of a new attribute that returns the actual model name as the docs suggests, and add a quirk note on the `model` attribute.
   
   Otherwise if Apple doesn't provide any such API then I'd personally be in favour for just simply adding a quirk note to the docs.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


[GitHub] [cordova-plugin-device] erisu closed issue #147: iPhone/ipad simulator model number are not accurate

Posted by GitBox <gi...@apache.org>.
erisu closed issue #147:
URL: https://github.com/apache/cordova-plugin-device/issues/147


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


[GitHub] [cordova-plugin-device] breautek commented on issue #147: iPhone/ipad simulator model number are not accurate

Posted by GitBox <gi...@apache.org>.
breautek commented on issue #147:
URL: https://github.com/apache/cordova-plugin-device/issues/147#issuecomment-1085809063


   We could provide known mappings in the documentation.
   
   That way it's easy to reference and to update without actual code releases. And leave it to the developer to determine how to use the field.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org