liwenhe1993 opened a new issue #2255: [BUG] taskProps.getScheduleTime() may be null, but there is no check if it is null or not URL: https://github.com/apache/incubator-dolphinscheduler/issues/2255 ```java if (paramsMap != null) { String dateTime = DateUtils.format(taskProps.getScheduleTime(), Constants.PARAMETER_FORMAT_TIME); Property p = new Property(); p.setValue(dateTime); p.setProp(Constants.PARAMETER_SHECDULE_TIME); paramsMap.put(Constants.PARAMETER_SHECDULE_TIME, p); script = ParameterUtils.convertParameterPlaceholders2(script, ParamUtils.convert(paramsMap)); } ``` `taskProps.getScheduleTime()` may be `null`, so we need to check if it is null or not. I will change as follows: ```java // new // replace variable TIME with $[YYYYmmddd...] in shell file when history run job and batch complement job if (paramsMap != null) { if (taskProps.getScheduleTime() != null) { String dateTime = DateUtils.format(taskProps.getScheduleTime(), Constants.PARAMETER_FORMAT_TIME); Property p = new Property(); p.setValue(dateTime); p.setProp(Constants.PARAMETER_SHECDULE_TIME); paramsMap.put(Constants.PARAMETER_SHECDULE_TIME, p); } script = ParameterUtils.convertParameterPlaceholders2(script, ParamUtils.convert(paramsMap)); } ```
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
