void () { if (Trigger.LOG.isDebugEnabled()) { Trigger.LOG.debug("Finishing SDK refresh for '" + mySdk.getName() + "' " + "originally scheduled at " + myRequestData.myTimestamp + " by " + Trigger.getCauseByTrace(myRequestData.myTraceback)); } PyUpdateSdkRequestData requestData; synchronized (ourLock) { boolean existed = ourUnderRefresh.remove(mySdk); LOG.assertTrue(existed, "Error in SDK refresh scheduling: refreshed SDK is not in the set."); requestData = ourToBeRefreshed.remove(mySdk); if (requestData != null) { ourUnderRefresh.add(mySdk); } } if (requestData != null) { ProgressManager.getInstance().run(new PyUpdateSdkTask(myProject, mySdk, requestData)); } }