Dart SDK Troubleshooting Guide
The Dart SDK uses the standard logging
package Use the following code to enable logging:
pubnub.log.level = Level.ALL
pubnub.onRecord.listen((record) {
print('${record.level.name}: ${record.time}: ${record.message}');
});
Log Level Reference
Dart assigns a weight to each type of log messages. When you set the logging level with Pubnub.log.level = Level.loglevel
, your application logs only messages with a weight of at least loglevel
.
The threshold levels are defined in the Level
class as follows:
OFF
weight is 2000, and turns logging offSHOUT
weight is 1200SEVERE
weight is 1000WARNING
weight is 900INFO
weight is 800CONFIG
weight is 700FINE
weight is 500FINER
weight is 400FINEST
weight is 300ALL
weight is 0, and turns on logging for all levels