Remove additional aapsLogger (3 left for further analysis with Insight V3 and site change)

This commit is contained in:
Philoul 2021-05-08 19:48:10 +02:00
parent dd527d9908
commit 153168a4d4

View file

@ -600,7 +600,6 @@ public class LocalInsightPlugin extends PumpPluginBase implements Pump, Constrai
null null
)); ));
InsightBolusID insightBolusID = insightDatabaseDao.getInsightBolusID(serial, bolusID, now); InsightBolusID insightBolusID = insightDatabaseDao.getInsightBolusID(serial, bolusID, now);
aapsLogger.debug(LTag.PUMP, "XXXX set Bolus: " + dateUtil.dateAndTimeAndSecondsString(dateUtil.now()) + " amount: " + insulin);
pumpSync.syncBolusWithPumpId( pumpSync.syncBolusWithPumpId(
insightBolusID.getTimestamp(), insightBolusID.getTimestamp(),
detailedBolusInfo.insulin, detailedBolusInfo.insulin,
@ -672,7 +671,6 @@ public class LocalInsightPlugin extends PumpPluginBase implements Pump, Constrai
bolusCancelled = true; bolusCancelled = true;
confirmAlert(AlertType.WARNING_38); confirmAlert(AlertType.WARNING_38);
alertService.ignore(null); alertService.ignore(null);
aapsLogger.debug(LTag.PUMP, "XXXX Stop Bolus : " + dateUtil.dateAndTimeAndSecondsString(dateUtil.now()));
} }
} catch (AppLayerErrorException e) { } catch (AppLayerErrorException e) {
aapsLogger.info(LTag.PUMP, "Exception while canceling bolus: " + e.getClass().getCanonicalName() + " (" + e.getErrorCode() + ")"); aapsLogger.info(LTag.PUMP, "Exception while canceling bolus: " + e.getClass().getCanonicalName() + " (" + e.getErrorCode() + ")");
@ -758,7 +756,6 @@ public class LocalInsightPlugin extends PumpPluginBase implements Pump, Constrai
.success(true) .success(true)
.enacted(true) .enacted(true)
.comment(R.string.virtualpump_resultok); .comment(R.string.virtualpump_resultok);
aapsLogger.debug(LTag.PUMP, "XXXX Set Temp Basal timestamp: " + dateUtil.now() + " rate: " + percent + " duration: " + durationInMinutes);
readHistory(); readHistory();
fetchStatus(); fetchStatus();
} catch (AppLayerErrorException e) { } catch (AppLayerErrorException e) {
@ -809,7 +806,6 @@ public class LocalInsightPlugin extends PumpPluginBase implements Pump, Constrai
null, null,
null null
)); ));
aapsLogger.debug(LTag.PUMP, "XXXX Set Extended timestamp: " + dateUtil.now() + " amount: " + insulin + "U duration: " + durationInMinutes + "BolusId: " + bolusID);
result.success(true).enacted(true).comment(R.string.virtualpump_resultok); result.success(true).enacted(true).comment(R.string.virtualpump_resultok);
} catch (AppLayerErrorException e) { } catch (AppLayerErrorException e) {
aapsLogger.info(LTag.PUMP, "Exception while delivering extended bolus: " + e.getClass().getCanonicalName() + " (" + e.getErrorCode() + ")"); aapsLogger.info(LTag.PUMP, "Exception while delivering extended bolus: " + e.getClass().getCanonicalName() + " (" + e.getErrorCode() + ")");
@ -857,7 +853,6 @@ public class LocalInsightPlugin extends PumpPluginBase implements Pump, Constrai
confirmAlert(AlertType.WARNING_36); confirmAlert(AlertType.WARNING_36);
alertService.ignore(null); alertService.ignore(null);
result.comment(R.string.virtualpump_resultok); result.comment(R.string.virtualpump_resultok);
aapsLogger.debug(LTag.PUMP, "XXXX cancel Temp Basal time: " + dateUtil.dateAndTimeAndSecondsString(dateUtil.now()));
} catch (NoActiveTBRToCanceLException e) { } catch (NoActiveTBRToCanceLException e) {
result.success(true); result.success(true);
result.comment(R.string.virtualpump_resultok); result.comment(R.string.virtualpump_resultok);
@ -903,7 +898,6 @@ public class LocalInsightPlugin extends PumpPluginBase implements Pump, Constrai
alertService.ignore(null); alertService.ignore(null);
InsightBolusID insightBolusID = insightDatabaseDao.getInsightBolusID(serialNumber(), activeBolus.getBolusID(), dateUtil.now()); InsightBolusID insightBolusID = insightDatabaseDao.getInsightBolusID(serialNumber(), activeBolus.getBolusID(), dateUtil.now());
if (insightBolusID != null) { if (insightBolusID != null) {
aapsLogger.debug(LTag.PUMP, "XXXX cancel Extended Bolus time: " + dateUtil.dateAndTimeAndSecondsString(dateUtil.now()) + " BolusId: " + activeBolus.getBolusID());
result.enacted(true).success(true); result.enacted(true).success(true);
} }
} }
@ -1284,7 +1278,6 @@ public class LocalInsightPlugin extends PumpPluginBase implements Pump, Constrai
calendar.set(Calendar.YEAR, event.getTotalYear()); calendar.set(Calendar.YEAR, event.getTotalYear());
calendar.set(Calendar.MONTH, event.getTotalMonth() - 1); calendar.set(Calendar.MONTH, event.getTotalMonth() - 1);
calendar.set(Calendar.DAY_OF_MONTH, event.getTotalDay()); calendar.set(Calendar.DAY_OF_MONTH, event.getTotalDay());
aapsLogger.debug(LTag.PUMP, "XXXX event Daily Dose event day: " + event.getTotalYear() + "/" + (event.getTotalMonth() - 1) + "/" + event.getTotalDay() + " Basal: " + event.getBasalTotal() + " Bolus: " + event.getBolusTotal());
pumpSync.createOrUpdateTotalDailyDose( pumpSync.createOrUpdateTotalDailyDose(
calendar.getTimeInMillis(), calendar.getTimeInMillis(),
event.getBolusTotal(), event.getBolusTotal(),
@ -1330,7 +1323,6 @@ public class LocalInsightPlugin extends PumpPluginBase implements Pump, Constrai
long timestamp = parseDate(event.getEventYear(), event.getEventMonth(), event.getEventDay(), long timestamp = parseDate(event.getEventYear(), event.getEventMonth(), event.getEventDay(),
event.getEventHour(), event.getEventMinute(), event.getEventSecond()) + timeOffset; event.getEventHour(), event.getEventMinute(), event.getEventSecond()) + timeOffset;
uploadCareportalEvent(timestamp, DetailedBolusInfo.EventType.PUMP_BATTERY_CHANGE); uploadCareportalEvent(timestamp, DetailedBolusInfo.EventType.PUMP_BATTERY_CHANGE);
aapsLogger.debug(LTag.PUMP, "XXXX event Battery Change time: " + dateUtil.dateAndTimeAndSecondsString(timestamp));
pumpSync.insertTherapyEventIfNewWithTimestamp( pumpSync.insertTherapyEventIfNewWithTimestamp(
timestamp, timestamp,
DetailedBolusInfo.EventType.PUMP_BATTERY_CHANGE, DetailedBolusInfo.EventType.PUMP_BATTERY_CHANGE,
@ -1354,19 +1346,16 @@ public class LocalInsightPlugin extends PumpPluginBase implements Pump, Constrai
pumpStartedEvents.add(pumpID); pumpStartedEvents.add(pumpID);
if (sp.getBoolean("insight_log_operating_mode_changes", false)) if (sp.getBoolean("insight_log_operating_mode_changes", false))
logNote(timestamp, resourceHelper.gs(R.string.pump_started)); logNote(timestamp, resourceHelper.gs(R.string.pump_started));
aapsLogger.debug(LTag.PUMP, "XXXX event START Event TimeStamp: " + timestamp + " HMS: " + dateUtil.dateAndTimeAndSecondsString(timestamp));
break; break;
case STOPPED: case STOPPED:
pumpID.setEventType(EventType.PumpStopped); pumpID.setEventType(EventType.PumpStopped);
if (sp.getBoolean("insight_log_operating_mode_changes", false)) if (sp.getBoolean("insight_log_operating_mode_changes", false))
logNote(timestamp, resourceHelper.gs(R.string.pump_stopped)); logNote(timestamp, resourceHelper.gs(R.string.pump_stopped));
aapsLogger.debug(LTag.PUMP, "XXXX event STOP: " + timestamp + " HMS: " + dateUtil.dateAndTimeAndSecondsString(timestamp));
break; break;
case PAUSED: case PAUSED:
pumpID.setEventType(EventType.PumpPaused); pumpID.setEventType(EventType.PumpPaused);
if (sp.getBoolean("insight_log_operating_mode_changes", false)) if (sp.getBoolean("insight_log_operating_mode_changes", false))
logNote(timestamp, resourceHelper.gs(R.string.pump_paused)); logNote(timestamp, resourceHelper.gs(R.string.pump_paused));
aapsLogger.debug(LTag.PUMP, "XXXX event Pause: " + timestamp + " HMS: " + dateUtil.dateAndTimeAndSecondsString(timestamp));
break; break;
} }
insightDatabaseDao.createOrUpdate(pumpID); insightDatabaseDao.createOrUpdate(pumpID);