[iOS] 判斷 NaN
進公司兩年,還是有一些 Bug/Crash 未解,不是我不想解,只是不知道如何「重現」。偶然間我終於可以持續重現狀況,趕緊放下手邊工作,接上手機編譯 App,在 Xcode 設中斷點,便能知道前後變數當前的值,推敲源頭是什麼~😗
(繼續閱讀…)進公司兩年,還是有一些 Bug/Crash 未解,不是我不想解,只是不知道如何「重現」。偶然間我終於可以持續重現狀況,趕緊放下手邊工作,接上手機編譯 App,在 Xcode 設中斷點,便能知道前後變數當前的值,推敲源頭是什麼~😗
(繼續閱讀…)最近在整合 API,需要附加大量的參數,使用 Get 方式呼叫,發生:
Request failed: requested URL too long (414)
搜尋一下問題,原因如下:
Two options to resolve the problem for 414 response code:
最後我改成 Post 方式呼叫,就再也沒有此問題!😃
Error Domain=com.alamofire.error.serialization.response Code=-1011 “Request failed: requested URL too long (414)" UserInfo={NSLocalizedDescription=Request failed: requested URL too long (414),
Request-URI Too Large
The requested URL’s length exceeds the capacity limit for this server.
Apache/2.2.15 (CentOS) Server at upload.tintint.com Port 443
HappyMan・迴響