Post

Replies

Boosts

Views

Activity

Reply to Xcode 15 Beta Stuck on preparing iphone simulator for previews
Did you tried to remove derives data ? You can nor see if XCode is trying to build/start fir preview by Clocking in the circle ⭕️ on top of window : it show the list of process that XCode is doing (indexing, comp for preview, starting simulator…) tou can also try to change the selected output on the preview tab in the bottom when it enable it (sometime you can choose : currently i did not managed to understand when)
Oct ’23
Reply to Is gethostbyname safe?
The problem is mostly that the IP address may not be valid for certain access : web site may be addressed on the same IP address with different hostname which are redirected to different web pages (that is part of apache configuration possibilities for example). SO it may work work but be careful.
Dec ’22
Reply to Swift codable: an object that is come from an API, changed from type Array to Object
This is quite ugly but to can help you. The new structure read the new JSON but return the previous interface `// Old structure struct ContactMediumOld: Codable {     struct ContactMedium: Codable {         var type: String         struct Characteristic: Codable {             var emailAddress : String         }         var characteristic: Characteristic     }     var contactMedium: [ContactMedium] } // New structure struct ContactMediumNew: Codable {     struct ContactMedium: Codable {         var type: String         struct Characteristic: Codable {             var emailAddress : String         }         // name of property also changed so use a computed for old name         private var characteristics: Characteristic         var characteristic: Characteristic {             characteristics         }     }          // read an simple object     private var contactMediumNew: ContactMedium          enum CodingKeys: String, CodingKey {         case contactMediumNew = "contactMedium"     }     // but return an array     var contactMedium: [ContactMedium] {         [contactMediumNew]     } }`
Dec ’22