web-dev-qa-db-fra.com

Comment puis-je corriger tout ce qui cause cela pour inonder mon logcat: I / System.out ﹕ (HTTPLog) -Statique: isSBSettingEnabled false

J'écris une application Android qui accède à Internet. Elle fonctionne sans erreur, mais depuis que j'ai mis à jour mon appareil (Samsung Galaxy S5) vers Android 5.0 .1 mon logcat est inondé des messages suivants lorsque mon téléphone exécute l'application:

05-20 16:05:35.514  23322-23440/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:35.514  23322-23440/scave.dvend I/System.out﹕ (HTTPLog)-Static: isShipBuild true
05-20 16:05:35.514  23322-23440/scave.dvend I/System.out﹕ (HTTPLog)-Thread-23345-153023149: SmartBonding Enabling is false, SHIP_BUILD is true, log to file is false, DBG is false
05-20 16:05:35.514  23322-23440/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:35.564  23322-23440/scave.dvend I/System.out﹕ KnoxVpnUidStorageknoxVpnSupported API value returned is false
05-20 16:05:36.184  23322-23440/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:37.784  23322-23634/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:37.884  23322-23634/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:38.034  23322-23634/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:38.164  23322-23634/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:38.404  23322-23634/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:38.544  23322-23634/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:38.774  23322-23634/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:38.864  23322-23634/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:39.084  23322-23634/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:39.204  23322-23634/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
...
05-20 16:05:46.334  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:46.364  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:46.404  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:46.454  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:46.514  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:46.554  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:46.604  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:47.964  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:48.644  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:48.674  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:48.694  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:48.704  23322-24029/scave.dvend I/System.out﹕ KnoxVpnUidStorageknoxVpnSupported API value returned is false
05-20 16:05:48.754  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:48.804  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:48.844  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:48.874  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:48.914  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:48.944  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:48.994  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:50.564  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:50.604  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:50.654  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:50.714  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:50.744  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:50.774  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:50.824  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:50.834  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:50.864  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:50.904  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:50.944  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:50.984  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.014  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.044  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.094  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.124  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.144  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.204  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.224  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.254  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.304  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.424  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.504  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.554  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.594  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.624  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.654  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.714  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.744  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:51.774  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:53.134  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:53.204  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:53.324  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:53.384  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:53.414  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:53.444  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:54.684  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:54.724  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false
05-20 16:05:54.744  23322-24029/scave.dvend I/System.out﹕ (HTTPLog)-Static: isSBSettingEnabled false

C'est un extrêmement petit échantillon de ce à quoi ressemble mon logcat. Qu'est-ce que cela signifie même? Existe-t-il un moyen de définir "isSBSettingEnabled" sur true juste pour le faire taire?

30
Ingulit

Vous pouvez utiliser le filtre regex pour masquer le message de journal inondant votre journal:

^((?!isSBSettingEnabled).)*$

Vous pouvez également masquer plusieurs journaux incriminés à l'aide de |. Par exemple

^((?!isSBSettingEnabled|OtherLog|OtherLog2|Annoying Messages).)*$
12
Chris Stillwell

Vous utilisez probablement un HttpUrlConnection ou un HttpsUrlConnection. Vous pouvez peut-être savoir quelle classe se connecte en appelant getClass() sur la connexion correspondante et désactivez-la avec Logger.getLogger("...").setLevel(Level.OFF);

Voir aussi Activer la journalisation pour la classe JDK par programme

6
Timon Langlotz

Si vous utilisez HttpLoggingInterceptor sur l'application qui s'exécute sur un appareil Samsung, définissez simplement le niveau de journalisation sur le corps, il corrigera tout. Quelque chose comme ça devrait bien fonctionner:

HttpLoggingInterceptor loggingInterceptor = new HttpLoggingInterceptor();
loggingInterceptor.setLevel(HttpLoggingInterceptor.Level.BODY);
1
Aaron Sanson

Solution:

Ajoutez votre balise application:

Android:usesCleartextTraffic="true"

Comme suit:

<application
    ....
    Android:usesCleartextTraffic="true"
    ....>
0
kksal55