Comments (4)
print不会走asl的,只有NSLog()才会走ASL,并且在Swift工程下,NSLog()只有在模拟器上才会走ASL,OC的话真机也会,算是Swift对性能的优化。因此我封装了一个Log4G的库来做日志记录,可以参考CocoaChinaPlus,关于日志监控的所有实现和坑我都写在了《iOS监控编程》里,其中日志相关的是可以试读的
from godeye.
貌似是因为你的json数据有问题,试试在
let data = try JSONSerialization.data(withJSONObject: returnValue)
前面加一行:
guard JSONSerialization.isValidJSONObject(returnValue) else {
return nil;
}
看看有啥效果
等待你的回复
from godeye.
嗯,加上这句代码后不会发生崩溃了!
我能问个问题吗?swift怎样输出ASL?我使用print()发现不行。。
from godeye.
原来如此,谢谢哈
from godeye.
Related Issues (20)
- No such module when release scheme HOT 1
- Network模块没有数据 HOT 3
- dyld: Library not loaded HOT 3
- carthage error HOT 6
- 按照提示demo没有跑起来~~
- Swift4 compatible? HOT 2
- Demo 运行不起来 HOT 2
- 不维护了么? HOT 4
- cocopods 导入报错,ESPullToRefresh 问题 HOT 2
- 大佬,请问您的iOS监控编程哪里获取? HOT 1
- 没有oc版本的么??? HOT 2
- 监控卡顿 HOT 1
- CPU超过100%问题 HOT 1
- 为什么不更新了,在swfit4下用不了? HOT 1
- 再好的东西失去了维护也变成了垃圾 HOT 1
- Xcode 14 support
- Can we get the english version of your book?
- 平台工具链支持
- xcode 14 error
- Xcode 14 incompatibility
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 godeye.