Search results for

“DTiPhoneSimulatorErrorDomain Code 2”

165,591 results found

Post

Replies

Boosts

Views

Activity

Reply to Mystery Inverted Bool
DispatchQueue.main.async is, as it says in its name, asynchronous. Therefore your code is not executing in a linear line-by-line manner. You think the code is being executed in this order don't you: 1) DispatchQueue.main.async { 2) self.stillLoading = true } 3) print(stillLoading) It is NOT the case the line 2 is guaranteed to execute before line 3. Because line 1 is asynchronous, after 1 has executed, then control will jump to line 3 and meanwhile line 2 is dispatched to execute in parallel.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Aug ’23
Make 2 contradictory methods work in drawRect
I'm writing an app building elements consisting of CGPoints. I have 2 buttons: makeRectangle and makeTriangle. For building/drawing stage I use three methods for rectangle and three methods for triangle inside drawRect.I'm stuck with my code in drawRect. In if-else-statement each method swaps the building/drawing scheme for previous element every time a button pressed.If I already have built rectangle and then I click makeTriangle button, I get new triangle but my rectangle turns into triangle with one unconnected point.Is there a workaround or I shouldn't use drawRect method?Here's a code and all the details:http://stackoverflow.com/questions/39855349/make-2-contradictory-methods-work-in-drawrect
1
0
249
Oct ’16
Its been two weeks in Waiting for review
Hello two weeks ago i changed the state of the application to waiting for review in iTunesConnect. And exactly one week later, they rejected the app cause of the app rating was 9, and they wanted me to change it to 12. I did that and changed the state to waiting for review in the next two mintues. And after that its going to be one week. I didnt understand, I didnt upload a new build, why its taking much to time fo review board to analyse my app.Really sad. Is it cause halloween holidays ?? I wonder.
0
0
261
Nov ’15
2 factor authentication
Some how Apple is reading my number as 1-868-868 followed by my actual number causing me to not be able to receive my authentication code to get back into my account (Apple ID) First they told me it takes 24hrs because I kept requests new code sent over. Now I am told to wait 6 days although I told them the issue was the number stored is not correctly formatted. Although I asked them to fix it or use my other number or email they said nope it automated I have to wait. I was told I will not get back my account cause Apple won’t verify me after 24hrs now I am loosing my Apple account where I pay for editing apps and Apple Music And iCloud yearly without compensation or the ability to use it on another ID. What can I do to get my account back or should I cut my loses.
0
0
246
Jun ’20
Problems to Install Beta 2
After upgrading the iPhone Version to IOS 13 Beta 2, I started to update my watchOS 6 to beta 2 as well. Unfortunately the update stopped after downloading onto the iPhone with an error Message : Update can not be installed. During the Installation of the new watchOS Version onto the Apple Watch an error occured..( my translation from German ;-) . Any idea what happed and how to get around ?
0
0
402
Jun ’19
WeatherKit - one "request" or two?
I have a Swift app that fetches current conditions and daily forecasts. It is in production and working without issues. My question is whether the fetch I am using counts as a single “request” for usage thresholds, or two (one for current conditions, one for daily forecast)? I need current conditions more often than daily forecast, so if this is counting as two requests, I could refactor the logic to get each separately as needed. But separating the requests would use more quota if the combined fetch counts as a single request. let service = WeatherService() let location = CLLocation(latitude: weatherData.lat, longitude: weatherData.lon) let startOfToday = Calendar.current.startOfDay(for: Date()) let endDate = Calendar.current.date(byAdding: DateComponents(day: 2), to: startOfToday)! let current: CurrentWeather let daily: Forecast (current, daily) = try await service.weather(for: location, including: .current, .daily(startDate: startOfToday, endDate: endDate))
1
0
955
Apr ’24
Strange code coverage issue
Xcode 9.3Seeing a very odd issue with code coverage. I have two unit tests which ultimately test every branch in the following init function (put breakpoints to double-check that). Yet code coverage is putting red in the gutter along with a zero next to the lines in the if-blocks.Build is debug and code coverage turned on. I have not seeing the issue in other classes.init(data aData: Data?) { // Function called 482 times during full unit test run index = 0 let theLength : Int if let theData = aData { theLength = theData.count // Code coverage shows zero here and zone is colored red data = theData } else { // Code coverage shows 482 here (which cannot be since the if-block is reached 90%+) theLength = 0 data = Data() } length = theLength }Same exact thing happens for a simple test class. Unit test created two instances, one passing in a 2, the other 3. Breakpoints prove both are hit, yet code coverage not reflecting that:class IIF
7
0
3.5k
Apr ’18
Reply to Problems with randomised array items
Please edit your text properly. It is just impossible to read.Hey guys, so I've made an array called listY1 containing multiple questions, and each array value contains 2 contents, text (String) and correctanswer (bool).I've also made an array called UserPickedAnswer (bool) and a UILabel called questionLabel.So for some reason ther question label Is 1 time before the question text:for example(I set a var MyVar : bool = false.var My2ndVar = 0.var question = [1+1=2, 2+2=22]and the correct answer for the 1 item array is true and the 2nd if false.the UIlabel shows that the question is 1+1=2 when really the question is 2+2=22,so if I answer true then it will be wrong because the UILabel shows1+1=2 but the question is 2+2=22)I know it's confusing but if you understand, please help.And use code formatter (<>) for the code.Make sure you show the code where you set UILabel
Topic: Programming Languages SubTopic: Swift Tags:
Dec ’18
Reply to Mystery Inverted Bool
DispatchQueue.main.async is, as it says in its name, asynchronous. Therefore your code is not executing in a linear line-by-line manner. You think the code is being executed in this order don't you: 1) DispatchQueue.main.async { 2) self.stillLoading = true } 3) print(stillLoading) It is NOT the case the line 2 is guaranteed to execute before line 3. Because line 1 is asynchronous, after 1 has executed, then control will jump to line 3 and meanwhile line 2 is dispatched to execute in parallel.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Aug ’23
Make 2 contradictory methods work in drawRect
I'm writing an app building elements consisting of CGPoints. I have 2 buttons: makeRectangle and makeTriangle. For building/drawing stage I use three methods for rectangle and three methods for triangle inside drawRect.I'm stuck with my code in drawRect. In if-else-statement each method swaps the building/drawing scheme for previous element every time a button pressed.If I already have built rectangle and then I click makeTriangle button, I get new triangle but my rectangle turns into triangle with one unconnected point.Is there a workaround or I shouldn't use drawRect method?Here's a code and all the details:http://stackoverflow.com/questions/39855349/make-2-contradictory-methods-work-in-drawrect
Replies
1
Boosts
0
Views
249
Activity
Oct ’16
Its been two weeks in Waiting for review
Hello two weeks ago i changed the state of the application to waiting for review in iTunesConnect. And exactly one week later, they rejected the app cause of the app rating was 9, and they wanted me to change it to 12. I did that and changed the state to waiting for review in the next two mintues. And after that its going to be one week. I didnt understand, I didnt upload a new build, why its taking much to time fo review board to analyse my app.Really sad. Is it cause halloween holidays ?? I wonder.
Replies
0
Boosts
0
Views
261
Activity
Nov ’15
2 factor authentication
Some how Apple is reading my number as 1-868-868 followed by my actual number causing me to not be able to receive my authentication code to get back into my account (Apple ID) First they told me it takes 24hrs because I kept requests new code sent over. Now I am told to wait 6 days although I told them the issue was the number stored is not correctly formatted. Although I asked them to fix it or use my other number or email they said nope it automated I have to wait. I was told I will not get back my account cause Apple won’t verify me after 24hrs now I am loosing my Apple account where I pay for editing apps and Apple Music And iCloud yearly without compensation or the ability to use it on another ID. What can I do to get my account back or should I cut my loses.
Replies
0
Boosts
0
Views
246
Activity
Jun ’20
Problems to Install Beta 2
After upgrading the iPhone Version to IOS 13 Beta 2, I started to update my watchOS 6 to beta 2 as well. Unfortunately the update stopped after downloading onto the iPhone with an error Message : Update can not be installed. During the Installation of the new watchOS Version onto the Apple Watch an error occured..( my translation from German ;-) . Any idea what happed and how to get around ?
Replies
0
Boosts
0
Views
402
Activity
Jun ’19
WeatherKit - one "request" or two?
I have a Swift app that fetches current conditions and daily forecasts. It is in production and working without issues. My question is whether the fetch I am using counts as a single “request” for usage thresholds, or two (one for current conditions, one for daily forecast)? I need current conditions more often than daily forecast, so if this is counting as two requests, I could refactor the logic to get each separately as needed. But separating the requests would use more quota if the combined fetch counts as a single request. let service = WeatherService() let location = CLLocation(latitude: weatherData.lat, longitude: weatherData.lon) let startOfToday = Calendar.current.startOfDay(for: Date()) let endDate = Calendar.current.date(byAdding: DateComponents(day: 2), to: startOfToday)! let current: CurrentWeather let daily: Forecast (current, daily) = try await service.weather(for: location, including: .current, .daily(startDate: startOfToday, endDate: endDate))
Replies
1
Boosts
0
Views
955
Activity
Apr ’24
Strange code coverage issue
Xcode 9.3Seeing a very odd issue with code coverage. I have two unit tests which ultimately test every branch in the following init function (put breakpoints to double-check that). Yet code coverage is putting red in the gutter along with a zero next to the lines in the if-blocks.Build is debug and code coverage turned on. I have not seeing the issue in other classes.init(data aData: Data?) { // Function called 482 times during full unit test run index = 0 let theLength : Int if let theData = aData { theLength = theData.count // Code coverage shows zero here and zone is colored red data = theData } else { // Code coverage shows 482 here (which cannot be since the if-block is reached 90%+) theLength = 0 data = Data() } length = theLength }Same exact thing happens for a simple test class. Unit test created two instances, one passing in a 2, the other 3. Breakpoints prove both are hit, yet code coverage not reflecting that:class IIF
Replies
7
Boosts
0
Views
3.5k
Activity
Apr ’18
Reply to Problems with randomised array items
Please edit your text properly. It is just impossible to read.Hey guys, so I've made an array called listY1 containing multiple questions, and each array value contains 2 contents, text (String) and correctanswer (bool).I've also made an array called UserPickedAnswer (bool) and a UILabel called questionLabel.So for some reason ther question label Is 1 time before the question text:for example(I set a var MyVar : bool = false.var My2ndVar = 0.var question = [1+1=2, 2+2=22]and the correct answer for the 1 item array is true and the 2nd if false.the UIlabel shows that the question is 1+1=2 when really the question is 2+2=22,so if I answer true then it will be wrong because the UILabel shows1+1=2 but the question is 2+2=22)I know it's confusing but if you understand, please help.And use code formatter (<>) for the code.Make sure you show the code where you set UILabel
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Dec ’18