[jira] [Work logged] (LANG-1462) After version Commons-lang3.4 DateFormatUtils has a bug

2022-03-06 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/LANG-1462?focusedWorklogId=737258=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-737258
 ]

ASF GitHub Bot logged work on LANG-1462:


Author: ASF GitHub Bot
Created on: 06/Mar/22 16:46
Start Date: 06/Mar/22 16:46
Worklog Time Spent: 10m 
  Work Description: mbuiakova commented on pull request #863:
URL: https://github.com/apache/commons-lang/pull/863#issuecomment-1059996750


   > Would you please explain why this is needed?
   > 
   > Also:
   > 
   > * there are no tests
   > * the code has superfluous parentheses
   
   I added a test and removed extra parentheses. 
   The reason for these changes is that Calendar has timeZone, so it is 
expected by a user of the `format(final Calendar calendar, final String 
pattern)`-like methods that method gets the timezone from a calendar object. 
More detailed explanation 
[here](https://issues.apache.org/jira/browse/LANG-1462).
   
   Can you help please with this error, how to deal with it?
   
   ```
   Error:  High: Null passed for non-null parameter of format(Calendar, String, 
TimeZone, Locale) in 
org.apache.commons.lang3.time.DateFormatUtils.format(Calendar, String) 
[org.apache.commons.lang3.time.DateFormatUtils, 
org.apache.commons.lang3.time.DateFormatUtils] Method invoked at 
DateFormatUtils.java:[line 283]Known null at DateFormatUtils.java:[line 283] 
NP_NULL_PARAM_DEREF
   ```


-- 
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.

To unsubscribe, e-mail: issues-unsubscr...@commons.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 737258)
Time Spent: 0.5h  (was: 20m)

> After version Commons-lang3.4 DateFormatUtils has a bug
> ---
>
> Key: LANG-1462
> URL: https://issues.apache.org/jira/browse/LANG-1462
> Project: Commons Lang
>  Issue Type: Bug
>  Components: lang.time.*
>Affects Versions: 3.5, 3.6, 3.7, 3.8, 3.9, 3.8.1
>Reporter: Lijun Liang
>Priority: Critical
>  Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> The code is as follows :
> Calendar cale = Calendar.getInstance();
>  System.out.println("Old time is " + DateFormatUtils.format(cale, 
> "MMddHHmmss"));
>  cale.setTimeZone(TimeZone.getTimeZone("JST"));
>  System.out.println("New time is " + DateFormatUtils.format(cale, 
> "MMddHHmmss"));
>  
> The results of commons-lang3 3.4:
> Old time is 20190605144536
> New time is 20190605154536
>  
> The results of the version after commons-lang3 3.4:
> Old time is 20190605144536
> New time is 20190605144536
>  
> We found that the time zone setting was invalidated when it was formatted
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (LANG-1462) After version Commons-lang3.4 DateFormatUtils has a bug

2022-03-06 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/LANG-1462?focusedWorklogId=737251=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-737251
 ]

ASF GitHub Bot logged work on LANG-1462:


Author: ASF GitHub Bot
Created on: 06/Mar/22 15:19
Start Date: 06/Mar/22 15:19
Worklog Time Spent: 10m 
  Work Description: garydgregory commented on pull request #863:
URL: https://github.com/apache/commons-lang/pull/863#issuecomment-1059981909


   Would you please explain why this is needed?
   
   Also:
   - there are no tests
   - the code has superfluous parentheses 


-- 
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.

To unsubscribe, e-mail: issues-unsubscr...@commons.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 737251)
Time Spent: 20m  (was: 10m)

> After version Commons-lang3.4 DateFormatUtils has a bug
> ---
>
> Key: LANG-1462
> URL: https://issues.apache.org/jira/browse/LANG-1462
> Project: Commons Lang
>  Issue Type: Bug
>  Components: lang.time.*
>Affects Versions: 3.5, 3.6, 3.7, 3.8, 3.9, 3.8.1
>Reporter: Lijun Liang
>Priority: Critical
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> The code is as follows :
> Calendar cale = Calendar.getInstance();
>  System.out.println("Old time is " + DateFormatUtils.format(cale, 
> "MMddHHmmss"));
>  cale.setTimeZone(TimeZone.getTimeZone("JST"));
>  System.out.println("New time is " + DateFormatUtils.format(cale, 
> "MMddHHmmss"));
>  
> The results of commons-lang3 3.4:
> Old time is 20190605144536
> New time is 20190605154536
>  
> The results of the version after commons-lang3 3.4:
> Old time is 20190605144536
> New time is 20190605144536
>  
> We found that the time zone setting was invalidated when it was formatted
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (LANG-1462) After version Commons-lang3.4 DateFormatUtils has a bug

2022-03-06 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/LANG-1462?focusedWorklogId=737242=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-737242
 ]

ASF GitHub Bot logged work on LANG-1462:


Author: ASF GitHub Bot
Created on: 06/Mar/22 14:27
Start Date: 06/Mar/22 14:27
Worklog Time Spent: 10m 
  Work Description: mbuiakova opened a new pull request #863:
URL: https://github.com/apache/commons-lang/pull/863


   Uses timezone from the calendar object when no timezone is specified.


-- 
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.

To unsubscribe, e-mail: issues-unsubscr...@commons.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 737242)
Remaining Estimate: 0h
Time Spent: 10m

> After version Commons-lang3.4 DateFormatUtils has a bug
> ---
>
> Key: LANG-1462
> URL: https://issues.apache.org/jira/browse/LANG-1462
> Project: Commons Lang
>  Issue Type: Bug
>  Components: lang.time.*
>Affects Versions: 3.5, 3.6, 3.7, 3.8, 3.9, 3.8.1
>Reporter: Lijun Liang
>Priority: Critical
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> The code is as follows :
> Calendar cale = Calendar.getInstance();
>  System.out.println("Old time is " + DateFormatUtils.format(cale, 
> "MMddHHmmss"));
>  cale.setTimeZone(TimeZone.getTimeZone("JST"));
>  System.out.println("New time is " + DateFormatUtils.format(cale, 
> "MMddHHmmss"));
>  
> The results of commons-lang3 3.4:
> Old time is 20190605144536
> New time is 20190605154536
>  
> The results of the version after commons-lang3 3.4:
> Old time is 20190605144536
> New time is 20190605144536
>  
> We found that the time zone setting was invalidated when it was formatted
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)