Re: svn commit: r1337103 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1337103 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java

Adam Heath-2
On 05/11/2012 05:25 AM, [hidden email] wrote:

> Author: adrianc
> Date: Fri May 11 10:25:33 2012
> New Revision: 1337103
>
> URL: http://svn.apache.org/viewvc?rev=1337103&view=rev
> Log:
> Fixed broken Mini-language<check-errors>  element (second try).
>
> Modified:
>      ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>
> Modified: ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
> URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java?rev=1337103&r1=1337102&r2=1337103&view=diff
> ==============================================================================
> --- ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java (original)
> +++ ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java Fri May 11 10:25:33 2012
> @@ -52,8 +52,10 @@ public final class CheckErrors extends M
>           List<Object>  messages = methodContext.getEnv(this.errorListNameFse.expandString(methodContext.getEnvMap()));
>           if (messages != null&&  messages.size()>  0) {
>               if (methodContext.getMethodType() == MethodContext.EVENT) {
> +                methodContext.putEnv(simpleMethod.getEventErrorMessageListName(), messages);
>                   methodContext.putEnv(this.simpleMethod.getEventResponseCodeName(), getErrorCode(methodContext));
>               } else {
> +                methodContext.putEnv(simpleMethod.getServiceErrorMessageListName(), messages);
>                   methodContext.putEnv(this.simpleMethod.getServiceResponseMessageName(), getErrorCode(methodContext));
>               }
>               return false;

Try again, this breaks the test cases in *many* places.

21:53:03 -0500
doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$
git bisect good
bb93be67832c3120e5b4cf063832244cd8f9fe86 is the first bad commit
commit bb93be67832c3120e5b4cf063832244cd8f9fe86
Author: adrianc <adrianc@13f79535-47bb-0310-9956-ffa450edef68>
Date:   Fri May 11 10:25:33 2012 +0000

     Fixed broken Mini-language <check-errors> element (second try).


     git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1337103 
13f79535-47bb-0310-9956-ffa450edef68

:040000 040000 128f25ae17b7205cf1f47c2835a2c17056d0ebe1
eb0e33d1d4fbcc322ac4f2bab1f2990bdf01ee18 M      framework
21:55:01 -0500
doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$
git bisect log
git bisect start
# good: [276d224f582251360dd572fe072b9938d8412d2b] More work on
Mini-language: API fixes, overhauled <if-regexp>, <if-validate-method>,
and <check-id> elements.
git bisect good 276d224f582251360dd572fe072b9938d8412d2b
# bad: [521c68a9b06e0cde719439ae70c9a051a0003991] FORMATTING: Add some
missing final newlines to tons of files.
git bisect bad 521c68a9b06e0cde719439ae70c9a051a0003991
# good: [3ec683d716257e8c56394a79c44e589d3c61ffb6] FEATURE: Add gen-kek
ant target.
git bisect good 3ec683d716257e8c56394a79c44e589d3c61ffb6
# good: [f42a817cce883e167835c2408997f3b5b21fd431] Changed the Anon
Contact Us in ecommerce to use the improved captcha event.  Also removed
some bad code that would allow a user to impersonate another user and
discover their name simply by entering that person's email address in
the form.
git bisect good f42a817cce883e167835c2408997f3b5b21fd431
# bad: [d6db6a7f6b22f05cd6864dacec2977771f7d2fd2] Fixed Mini-language
validation for the <check-id> element.
git bisect bad d6db6a7f6b22f05cd6864dacec2977771f7d2fd2
# bad: [bb93be67832c3120e5b4cf063832244cd8f9fe86] Fixed broken
Mini-language <check-errors> element (second try).
git bisect bad bb93be67832c3120e5b4cf063832244cd8f9fe86
# good: [74b6f9d6f6140cd64e6a4754b1f527601af6e95b] Fixed broken
Mini-language <check-errors> element.
git bisect good 74b6f9d6f6140cd64e6a4754b1f527601af6e95b

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1337103 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java

Adrian Crum-3
The tests cases pass on my local machine. Could you provide the test
report XML file please?

-Adrian

On 5/12/2012 3:59 AM, Adam Heath wrote:

> On 05/11/2012 05:25 AM, [hidden email] wrote:
>> Author: adrianc
>> Date: Fri May 11 10:25:33 2012
>> New Revision: 1337103
>>
>> URL: http://svn.apache.org/viewvc?rev=1337103&view=rev
>> Log:
>> Fixed broken Mini-language<check-errors>  element (second try).
>>
>> Modified:
>>      
>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>
>> Modified:
>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>> URL:
>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java?rev=1337103&r1=1337102&r2=1337103&view=diff
>> ==============================================================================
>>
>> ---
>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>> (original)
>> +++
>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>> Fri May 11 10:25:33 2012
>> @@ -52,8 +52,10 @@ public final class CheckErrors extends M
>>           List<Object>  messages =
>> methodContext.getEnv(this.errorListNameFse.expandString(methodContext.getEnvMap()));
>>           if (messages != null&&  messages.size()>  0) {
>>               if (methodContext.getMethodType() ==
>> MethodContext.EVENT) {
>> +                
>> methodContext.putEnv(simpleMethod.getEventErrorMessageListName(),
>> messages);
>>                  
>> methodContext.putEnv(this.simpleMethod.getEventResponseCodeName(),
>> getErrorCode(methodContext));
>>               } else {
>> +                
>> methodContext.putEnv(simpleMethod.getServiceErrorMessageListName(),
>> messages);
>>                  
>> methodContext.putEnv(this.simpleMethod.getServiceResponseMessageName(),
>> getErrorCode(methodContext));
>>               }
>>               return false;
>
> Try again, this breaks the test cases in *many* places.
>
> 21:53:03 -0500
> doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$
> git bisect good
> bb93be67832c3120e5b4cf063832244cd8f9fe86 is the first bad commit
> commit bb93be67832c3120e5b4cf063832244cd8f9fe86
> Author: adrianc <adrianc@13f79535-47bb-0310-9956-ffa450edef68>
> Date:   Fri May 11 10:25:33 2012 +0000
>
>     Fixed broken Mini-language <check-errors> element (second try).
>
>
>     git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1337103 
> 13f79535-47bb-0310-9956-ffa450edef68
>
> :040000 040000 128f25ae17b7205cf1f47c2835a2c17056d0ebe1
> eb0e33d1d4fbcc322ac4f2bab1f2990bdf01ee18 M      framework
> 21:55:01 -0500
> doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$
> git bisect log
> git bisect start
> # good: [276d224f582251360dd572fe072b9938d8412d2b] More work on
> Mini-language: API fixes, overhauled <if-regexp>,
> <if-validate-method>, and <check-id> elements.
> git bisect good 276d224f582251360dd572fe072b9938d8412d2b
> # bad: [521c68a9b06e0cde719439ae70c9a051a0003991] FORMATTING: Add some
> missing final newlines to tons of files.
> git bisect bad 521c68a9b06e0cde719439ae70c9a051a0003991
> # good: [3ec683d716257e8c56394a79c44e589d3c61ffb6] FEATURE: Add
> gen-kek ant target.
> git bisect good 3ec683d716257e8c56394a79c44e589d3c61ffb6
> # good: [f42a817cce883e167835c2408997f3b5b21fd431] Changed the Anon
> Contact Us in ecommerce to use the improved captcha event.  Also
> removed some bad code that would allow a user to impersonate another
> user and discover their name simply by entering that person's email
> address in the form.
> git bisect good f42a817cce883e167835c2408997f3b5b21fd431
> # bad: [d6db6a7f6b22f05cd6864dacec2977771f7d2fd2] Fixed Mini-language
> validation for the <check-id> element.
> git bisect bad d6db6a7f6b22f05cd6864dacec2977771f7d2fd2
> # bad: [bb93be67832c3120e5b4cf063832244cd8f9fe86] Fixed broken
> Mini-language <check-errors> element (second try).
> git bisect bad bb93be67832c3120e5b4cf063832244cd8f9fe86
> # good: [74b6f9d6f6140cd64e6a4754b1f527601af6e95b] Fixed broken
> Mini-language <check-errors> element.
> git bisect good 74b6f9d6f6140cd64e6a4754b1f527601af6e95b
>
Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1337103 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java

Jacopo Cappellato-4
Adrian,

I am forwarding you a zip file with my test results.

Jacopo


On May 12, 2012, at 9:08 AM, Adrian Crum wrote:

> The tests cases pass on my local machine. Could you provide the test report XML file please?
>
> -Adrian
>
> On 5/12/2012 3:59 AM, Adam Heath wrote:
>> On 05/11/2012 05:25 AM, [hidden email] wrote:
>>> Author: adrianc
>>> Date: Fri May 11 10:25:33 2012
>>> New Revision: 1337103
>>>
>>> URL: http://svn.apache.org/viewvc?rev=1337103&view=rev
>>> Log:
>>> Fixed broken Mini-language<check-errors>  element (second try).
>>>
>>> Modified:
>>>     ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>
>>> Modified: ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>> URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java?rev=1337103&r1=1337102&r2=1337103&view=diff
>>> ==============================================================================
>>> --- ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java (original)
>>> +++ ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java Fri May 11 10:25:33 2012
>>> @@ -52,8 +52,10 @@ public final class CheckErrors extends M
>>>          List<Object>  messages = methodContext.getEnv(this.errorListNameFse.expandString(methodContext.getEnvMap()));
>>>          if (messages != null&&  messages.size()>  0) {
>>>              if (methodContext.getMethodType() == MethodContext.EVENT) {
>>> +                methodContext.putEnv(simpleMethod.getEventErrorMessageListName(), messages);
>>>                  methodContext.putEnv(this.simpleMethod.getEventResponseCodeName(), getErrorCode(methodContext));
>>>              } else {
>>> +                methodContext.putEnv(simpleMethod.getServiceErrorMessageListName(), messages);
>>>                  methodContext.putEnv(this.simpleMethod.getServiceResponseMessageName(), getErrorCode(methodContext));
>>>              }
>>>              return false;
>>
>> Try again, this breaks the test cases in *many* places.
>>
>> 21:53:03 -0500 doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$ git bisect good
>> bb93be67832c3120e5b4cf063832244cd8f9fe86 is the first bad commit
>> commit bb93be67832c3120e5b4cf063832244cd8f9fe86
>> Author: adrianc <adrianc@13f79535-47bb-0310-9956-ffa450edef68>
>> Date:   Fri May 11 10:25:33 2012 +0000
>>
>>    Fixed broken Mini-language <check-errors> element (second try).
>>
>>
>>    git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1337103 13f79535-47bb-0310-9956-ffa450edef68
>>
>> :040000 040000 128f25ae17b7205cf1f47c2835a2c17056d0ebe1 eb0e33d1d4fbcc322ac4f2bab1f2990bdf01ee18 M      framework
>> 21:55:01 -0500 doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$ git bisect log
>> git bisect start
>> # good: [276d224f582251360dd572fe072b9938d8412d2b] More work on Mini-language: API fixes, overhauled <if-regexp>, <if-validate-method>, and <check-id> elements.
>> git bisect good 276d224f582251360dd572fe072b9938d8412d2b
>> # bad: [521c68a9b06e0cde719439ae70c9a051a0003991] FORMATTING: Add some missing final newlines to tons of files.
>> git bisect bad 521c68a9b06e0cde719439ae70c9a051a0003991
>> # good: [3ec683d716257e8c56394a79c44e589d3c61ffb6] FEATURE: Add gen-kek ant target.
>> git bisect good 3ec683d716257e8c56394a79c44e589d3c61ffb6
>> # good: [f42a817cce883e167835c2408997f3b5b21fd431] Changed the Anon Contact Us in ecommerce to use the improved captcha event.  Also removed some bad code that would allow a user to impersonate another user and discover their name simply by entering that person's email address in the form.
>> git bisect good f42a817cce883e167835c2408997f3b5b21fd431
>> # bad: [d6db6a7f6b22f05cd6864dacec2977771f7d2fd2] Fixed Mini-language validation for the <check-id> element.
>> git bisect bad d6db6a7f6b22f05cd6864dacec2977771f7d2fd2
>> # bad: [bb93be67832c3120e5b4cf063832244cd8f9fe86] Fixed broken Mini-language <check-errors> element (second try).
>> git bisect bad bb93be67832c3120e5b4cf063832244cd8f9fe86
>> # good: [74b6f9d6f6140cd64e6a4754b1f527601af6e95b] Fixed broken Mini-language <check-errors> element.
>> git bisect good 74b6f9d6f6140cd64e6a4754b1f527601af6e95b
>>

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1337103 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java

Adam Heath-2
In reply to this post by Adrian Crum-3
Hold off.  On trunk, I get issues, but if I reverse the below patch, it
doesn't solve the problem.  git bisect can be confused when 2 problems
are happening.  I'll check this further in the morning.

On 05/12/2012 02:08 AM, Adrian Crum wrote:

> The tests cases pass on my local machine. Could you provide the test
> report XML file please?
>
> -Adrian
>
> On 5/12/2012 3:59 AM, Adam Heath wrote:
>> On 05/11/2012 05:25 AM, [hidden email] wrote:
>>> Author: adrianc
>>> Date: Fri May 11 10:25:33 2012
>>> New Revision: 1337103
>>>
>>> URL: http://svn.apache.org/viewvc?rev=1337103&view=rev
>>> Log:
>>> Fixed broken Mini-language<check-errors> element (second try).
>>>
>>> Modified:
>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>
>>>
>>> Modified:
>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>
>>> URL:
>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java?rev=1337103&r1=1337102&r2=1337103&view=diff
>>>
>>> ==============================================================================
>>>
>>> ---
>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>> (original)
>>> +++
>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>> Fri May 11 10:25:33 2012
>>> @@ -52,8 +52,10 @@ public final class CheckErrors extends M
>>> List<Object> messages =
>>> methodContext.getEnv(this.errorListNameFse.expandString(methodContext.getEnvMap()));
>>>
>>> if (messages != null&& messages.size()> 0) {
>>> if (methodContext.getMethodType() == MethodContext.EVENT) {
>>> + methodContext.putEnv(simpleMethod.getEventErrorMessageListName(),
>>> messages);
>>> methodContext.putEnv(this.simpleMethod.getEventResponseCodeName(),
>>> getErrorCode(methodContext));
>>> } else {
>>> + methodContext.putEnv(simpleMethod.getServiceErrorMessageListName(),
>>> messages);
>>> methodContext.putEnv(this.simpleMethod.getServiceResponseMessageName(),
>>> getErrorCode(methodContext));
>>> }
>>> return false;
>>
>> Try again, this breaks the test cases in *many* places.
>>
>> 21:53:03 -0500
>> doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$
>> git bisect good
>> bb93be67832c3120e5b4cf063832244cd8f9fe86 is the first bad commit
>> commit bb93be67832c3120e5b4cf063832244cd8f9fe86
>> Author: adrianc <adrianc@13f79535-47bb-0310-9956-ffa450edef68>
>> Date: Fri May 11 10:25:33 2012 +0000
>>
>> Fixed broken Mini-language <check-errors> element (second try).
>>
>>
>> git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1337103
>> 13f79535-47bb-0310-9956-ffa450edef68
>>
>> :040000 040000 128f25ae17b7205cf1f47c2835a2c17056d0ebe1
>> eb0e33d1d4fbcc322ac4f2bab1f2990bdf01ee18 M framework
>> 21:55:01 -0500
>> doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$
>> git bisect log
>> git bisect start
>> # good: [276d224f582251360dd572fe072b9938d8412d2b] More work on
>> Mini-language: API fixes, overhauled <if-regexp>,
>> <if-validate-method>, and <check-id> elements.
>> git bisect good 276d224f582251360dd572fe072b9938d8412d2b
>> # bad: [521c68a9b06e0cde719439ae70c9a051a0003991] FORMATTING: Add some
>> missing final newlines to tons of files.
>> git bisect bad 521c68a9b06e0cde719439ae70c9a051a0003991
>> # good: [3ec683d716257e8c56394a79c44e589d3c61ffb6] FEATURE: Add
>> gen-kek ant target.
>> git bisect good 3ec683d716257e8c56394a79c44e589d3c61ffb6
>> # good: [f42a817cce883e167835c2408997f3b5b21fd431] Changed the Anon
>> Contact Us in ecommerce to use the improved captcha event. Also
>> removed some bad code that would allow a user to impersonate another
>> user and discover their name simply by entering that person's email
>> address in the form.
>> git bisect good f42a817cce883e167835c2408997f3b5b21fd431
>> # bad: [d6db6a7f6b22f05cd6864dacec2977771f7d2fd2] Fixed Mini-language
>> validation for the <check-id> element.
>> git bisect bad d6db6a7f6b22f05cd6864dacec2977771f7d2fd2
>> # bad: [bb93be67832c3120e5b4cf063832244cd8f9fe86] Fixed broken
>> Mini-language <check-errors> element (second try).
>> git bisect bad bb93be67832c3120e5b4cf063832244cd8f9fe86
>> # good: [74b6f9d6f6140cd64e6a4754b1f527601af6e95b] Fixed broken
>> Mini-language <check-errors> element.
>> git bisect good 74b6f9d6f6140cd64e6a4754b1f527601af6e95b
>>

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1337103 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java

Adrian Crum-3
In reply to this post by Jacopo Cappellato-4
Thanks Jacopo! I am working on it.

-Adrian

On 5/12/2012 8:14 AM, Jacopo Cappellato wrote:

> Adrian,
>
> I am forwarding you a zip file with my test results.
>
> Jacopo
>
>
> On May 12, 2012, at 9:08 AM, Adrian Crum wrote:
>
>> The tests cases pass on my local machine. Could you provide the test report XML file please?
>>
>> -Adrian
>>
>> On 5/12/2012 3:59 AM, Adam Heath wrote:
>>> On 05/11/2012 05:25 AM, [hidden email] wrote:
>>>> Author: adrianc
>>>> Date: Fri May 11 10:25:33 2012
>>>> New Revision: 1337103
>>>>
>>>> URL: http://svn.apache.org/viewvc?rev=1337103&view=rev
>>>> Log:
>>>> Fixed broken Mini-language<check-errors>   element (second try).
>>>>
>>>> Modified:
>>>>      ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>>
>>>> Modified: ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>> URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java?rev=1337103&r1=1337102&r2=1337103&view=diff
>>>> ==============================================================================
>>>> --- ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java (original)
>>>> +++ ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java Fri May 11 10:25:33 2012
>>>> @@ -52,8 +52,10 @@ public final class CheckErrors extends M
>>>>           List<Object>   messages = methodContext.getEnv(this.errorListNameFse.expandString(methodContext.getEnvMap()));
>>>>           if (messages != null&&   messages.size()>   0) {
>>>>               if (methodContext.getMethodType() == MethodContext.EVENT) {
>>>> +                methodContext.putEnv(simpleMethod.getEventErrorMessageListName(), messages);
>>>>                   methodContext.putEnv(this.simpleMethod.getEventResponseCodeName(), getErrorCode(methodContext));
>>>>               } else {
>>>> +                methodContext.putEnv(simpleMethod.getServiceErrorMessageListName(), messages);
>>>>                   methodContext.putEnv(this.simpleMethod.getServiceResponseMessageName(), getErrorCode(methodContext));
>>>>               }
>>>>               return false;
>>> Try again, this breaks the test cases in *many* places.
>>>
>>> 21:53:03 -0500 doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$ git bisect good
>>> bb93be67832c3120e5b4cf063832244cd8f9fe86 is the first bad commit
>>> commit bb93be67832c3120e5b4cf063832244cd8f9fe86
>>> Author: adrianc<adrianc@13f79535-47bb-0310-9956-ffa450edef68>
>>> Date:   Fri May 11 10:25:33 2012 +0000
>>>
>>>     Fixed broken Mini-language<check-errors>  element (second try).
>>>
>>>
>>>     git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1337103 13f79535-47bb-0310-9956-ffa450edef68
>>>
>>> :040000 040000 128f25ae17b7205cf1f47c2835a2c17056d0ebe1 eb0e33d1d4fbcc322ac4f2bab1f2990bdf01ee18 M      framework
>>> 21:55:01 -0500 doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$ git bisect log
>>> git bisect start
>>> # good: [276d224f582251360dd572fe072b9938d8412d2b] More work on Mini-language: API fixes, overhauled<if-regexp>,<if-validate-method>, and<check-id>  elements.
>>> git bisect good 276d224f582251360dd572fe072b9938d8412d2b
>>> # bad: [521c68a9b06e0cde719439ae70c9a051a0003991] FORMATTING: Add some missing final newlines to tons of files.
>>> git bisect bad 521c68a9b06e0cde719439ae70c9a051a0003991
>>> # good: [3ec683d716257e8c56394a79c44e589d3c61ffb6] FEATURE: Add gen-kek ant target.
>>> git bisect good 3ec683d716257e8c56394a79c44e589d3c61ffb6
>>> # good: [f42a817cce883e167835c2408997f3b5b21fd431] Changed the Anon Contact Us in ecommerce to use the improved captcha event.  Also removed some bad code that would allow a user to impersonate another user and discover their name simply by entering that person's email address in the form.
>>> git bisect good f42a817cce883e167835c2408997f3b5b21fd431
>>> # bad: [d6db6a7f6b22f05cd6864dacec2977771f7d2fd2] Fixed Mini-language validation for the<check-id>  element.
>>> git bisect bad d6db6a7f6b22f05cd6864dacec2977771f7d2fd2
>>> # bad: [bb93be67832c3120e5b4cf063832244cd8f9fe86] Fixed broken Mini-language<check-errors>  element (second try).
>>> git bisect bad bb93be67832c3120e5b4cf063832244cd8f9fe86
>>> # good: [74b6f9d6f6140cd64e6a4754b1f527601af6e95b] Fixed broken Mini-language<check-errors>  element.
>>> git bisect good 74b6f9d6f6140cd64e6a4754b1f527601af6e95b
>>>
Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1337103 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java

Jacopo Cappellato-4
In reply to this post by Adam Heath-2
yeah, it could be something unrelated to Adrian's commit.
Adrian let me know if you find something or if you want me to have a look as well.

Jacopo

On May 12, 2012, at 9:20 AM, Adam Heath wrote:

> Hold off.  On trunk, I get issues, but if I reverse the below patch, it doesn't solve the problem.  git bisect can be confused when 2 problems are happening.  I'll check this further in the morning.
>
> On 05/12/2012 02:08 AM, Adrian Crum wrote:
>> The tests cases pass on my local machine. Could you provide the test
>> report XML file please?
>>
>> -Adrian
>>
>> On 5/12/2012 3:59 AM, Adam Heath wrote:
>>> On 05/11/2012 05:25 AM, [hidden email] wrote:
>>>> Author: adrianc
>>>> Date: Fri May 11 10:25:33 2012
>>>> New Revision: 1337103
>>>>
>>>> URL: http://svn.apache.org/viewvc?rev=1337103&view=rev
>>>> Log:
>>>> Fixed broken Mini-language<check-errors> element (second try).
>>>>
>>>> Modified:
>>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>>
>>>>
>>>> Modified:
>>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>>
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java?rev=1337103&r1=1337102&r2=1337103&view=diff
>>>>
>>>> ==============================================================================
>>>>
>>>> ---
>>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>> (original)
>>>> +++
>>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>> Fri May 11 10:25:33 2012
>>>> @@ -52,8 +52,10 @@ public final class CheckErrors extends M
>>>> List<Object> messages =
>>>> methodContext.getEnv(this.errorListNameFse.expandString(methodContext.getEnvMap()));
>>>>
>>>> if (messages != null&& messages.size()> 0) {
>>>> if (methodContext.getMethodType() == MethodContext.EVENT) {
>>>> + methodContext.putEnv(simpleMethod.getEventErrorMessageListName(),
>>>> messages);
>>>> methodContext.putEnv(this.simpleMethod.getEventResponseCodeName(),
>>>> getErrorCode(methodContext));
>>>> } else {
>>>> + methodContext.putEnv(simpleMethod.getServiceErrorMessageListName(),
>>>> messages);
>>>> methodContext.putEnv(this.simpleMethod.getServiceResponseMessageName(),
>>>> getErrorCode(methodContext));
>>>> }
>>>> return false;
>>>
>>> Try again, this breaks the test cases in *many* places.
>>>
>>> 21:53:03 -0500
>>> doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$
>>> git bisect good
>>> bb93be67832c3120e5b4cf063832244cd8f9fe86 is the first bad commit
>>> commit bb93be67832c3120e5b4cf063832244cd8f9fe86
>>> Author: adrianc <adrianc@13f79535-47bb-0310-9956-ffa450edef68>
>>> Date: Fri May 11 10:25:33 2012 +0000
>>>
>>> Fixed broken Mini-language <check-errors> element (second try).
>>>
>>>
>>> git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1337103
>>> 13f79535-47bb-0310-9956-ffa450edef68
>>>
>>> :040000 040000 128f25ae17b7205cf1f47c2835a2c17056d0ebe1
>>> eb0e33d1d4fbcc322ac4f2bab1f2990bdf01ee18 M framework
>>> 21:55:01 -0500
>>> doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$
>>> git bisect log
>>> git bisect start
>>> # good: [276d224f582251360dd572fe072b9938d8412d2b] More work on
>>> Mini-language: API fixes, overhauled <if-regexp>,
>>> <if-validate-method>, and <check-id> elements.
>>> git bisect good 276d224f582251360dd572fe072b9938d8412d2b
>>> # bad: [521c68a9b06e0cde719439ae70c9a051a0003991] FORMATTING: Add some
>>> missing final newlines to tons of files.
>>> git bisect bad 521c68a9b06e0cde719439ae70c9a051a0003991
>>> # good: [3ec683d716257e8c56394a79c44e589d3c61ffb6] FEATURE: Add
>>> gen-kek ant target.
>>> git bisect good 3ec683d716257e8c56394a79c44e589d3c61ffb6
>>> # good: [f42a817cce883e167835c2408997f3b5b21fd431] Changed the Anon
>>> Contact Us in ecommerce to use the improved captcha event. Also
>>> removed some bad code that would allow a user to impersonate another
>>> user and discover their name simply by entering that person's email
>>> address in the form.
>>> git bisect good f42a817cce883e167835c2408997f3b5b21fd431
>>> # bad: [d6db6a7f6b22f05cd6864dacec2977771f7d2fd2] Fixed Mini-language
>>> validation for the <check-id> element.
>>> git bisect bad d6db6a7f6b22f05cd6864dacec2977771f7d2fd2
>>> # bad: [bb93be67832c3120e5b4cf063832244cd8f9fe86] Fixed broken
>>> Mini-language <check-errors> element (second try).
>>> git bisect bad bb93be67832c3120e5b4cf063832244cd8f9fe86
>>> # good: [74b6f9d6f6140cd64e6a4754b1f527601af6e95b] Fixed broken
>>> Mini-language <check-errors> element.
>>> git bisect good 74b6f9d6f6140cd64e6a4754b1f527601af6e95b
>>>
>

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1337103 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java

Adrian Crum-3
I believe the check-errors fix revealed a test failure that was being
hidden before the fix.

-Adrian

On 5/12/2012 8:24 AM, Jacopo Cappellato wrote:

> yeah, it could be something unrelated to Adrian's commit.
> Adrian let me know if you find something or if you want me to have a look as well.
>
> Jacopo
>
> On May 12, 2012, at 9:20 AM, Adam Heath wrote:
>
>> Hold off.  On trunk, I get issues, but if I reverse the below patch, it doesn't solve the problem.  git bisect can be confused when 2 problems are happening.  I'll check this further in the morning.
>>
>> On 05/12/2012 02:08 AM, Adrian Crum wrote:
>>> The tests cases pass on my local machine. Could you provide the test
>>> report XML file please?
>>>
>>> -Adrian
>>>
>>> On 5/12/2012 3:59 AM, Adam Heath wrote:
>>>> On 05/11/2012 05:25 AM, [hidden email] wrote:
>>>>> Author: adrianc
>>>>> Date: Fri May 11 10:25:33 2012
>>>>> New Revision: 1337103
>>>>>
>>>>> URL: http://svn.apache.org/viewvc?rev=1337103&view=rev
>>>>> Log:
>>>>> Fixed broken Mini-language<check-errors>  element (second try).
>>>>>
>>>>> Modified:
>>>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>>>
>>>>>
>>>>> Modified:
>>>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>>>
>>>>> URL:
>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java?rev=1337103&r1=1337102&r2=1337103&view=diff
>>>>>
>>>>> ==============================================================================
>>>>>
>>>>> ---
>>>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>>> (original)
>>>>> +++
>>>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>>> Fri May 11 10:25:33 2012
>>>>> @@ -52,8 +52,10 @@ public final class CheckErrors extends M
>>>>> List<Object>  messages =
>>>>> methodContext.getEnv(this.errorListNameFse.expandString(methodContext.getEnvMap()));
>>>>>
>>>>> if (messages != null&&  messages.size()>  0) {
>>>>> if (methodContext.getMethodType() == MethodContext.EVENT) {
>>>>> + methodContext.putEnv(simpleMethod.getEventErrorMessageListName(),
>>>>> messages);
>>>>> methodContext.putEnv(this.simpleMethod.getEventResponseCodeName(),
>>>>> getErrorCode(methodContext));
>>>>> } else {
>>>>> + methodContext.putEnv(simpleMethod.getServiceErrorMessageListName(),
>>>>> messages);
>>>>> methodContext.putEnv(this.simpleMethod.getServiceResponseMessageName(),
>>>>> getErrorCode(methodContext));
>>>>> }
>>>>> return false;
>>>> Try again, this breaks the test cases in *many* places.
>>>>
>>>> 21:53:03 -0500
>>>> doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$
>>>> git bisect good
>>>> bb93be67832c3120e5b4cf063832244cd8f9fe86 is the first bad commit
>>>> commit bb93be67832c3120e5b4cf063832244cd8f9fe86
>>>> Author: adrianc<adrianc@13f79535-47bb-0310-9956-ffa450edef68>
>>>> Date: Fri May 11 10:25:33 2012 +0000
>>>>
>>>> Fixed broken Mini-language<check-errors>  element (second try).
>>>>
>>>>
>>>> git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1337103
>>>> 13f79535-47bb-0310-9956-ffa450edef68
>>>>
>>>> :040000 040000 128f25ae17b7205cf1f47c2835a2c17056d0ebe1
>>>> eb0e33d1d4fbcc322ac4f2bab1f2990bdf01ee18 M framework
>>>> 21:55:01 -0500
>>>> doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$
>>>> git bisect log
>>>> git bisect start
>>>> # good: [276d224f582251360dd572fe072b9938d8412d2b] More work on
>>>> Mini-language: API fixes, overhauled<if-regexp>,
>>>> <if-validate-method>, and<check-id>  elements.
>>>> git bisect good 276d224f582251360dd572fe072b9938d8412d2b
>>>> # bad: [521c68a9b06e0cde719439ae70c9a051a0003991] FORMATTING: Add some
>>>> missing final newlines to tons of files.
>>>> git bisect bad 521c68a9b06e0cde719439ae70c9a051a0003991
>>>> # good: [3ec683d716257e8c56394a79c44e589d3c61ffb6] FEATURE: Add
>>>> gen-kek ant target.
>>>> git bisect good 3ec683d716257e8c56394a79c44e589d3c61ffb6
>>>> # good: [f42a817cce883e167835c2408997f3b5b21fd431] Changed the Anon
>>>> Contact Us in ecommerce to use the improved captcha event. Also
>>>> removed some bad code that would allow a user to impersonate another
>>>> user and discover their name simply by entering that person's email
>>>> address in the form.
>>>> git bisect good f42a817cce883e167835c2408997f3b5b21fd431
>>>> # bad: [d6db6a7f6b22f05cd6864dacec2977771f7d2fd2] Fixed Mini-language
>>>> validation for the<check-id>  element.
>>>> git bisect bad d6db6a7f6b22f05cd6864dacec2977771f7d2fd2
>>>> # bad: [bb93be67832c3120e5b4cf063832244cd8f9fe86] Fixed broken
>>>> Mini-language<check-errors>  element (second try).
>>>> git bisect bad bb93be67832c3120e5b4cf063832244cd8f9fe86
>>>> # good: [74b6f9d6f6140cd64e6a4754b1f527601af6e95b] Fixed broken
>>>> Mini-language<check-errors>  element.
>>>> git bisect good 74b6f9d6f6140cd64e6a4754b1f527601af6e95b
>>>>
Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1337103 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java

Adrian Crum-3
Okay, rev 1337518 gets the tests to pass, but it isn't a fix - it merely
masks the real problem. I made the commit so others can continue with
their work, and I will continue working on the real problem.

Without going into too much detail, here is a summary of the problem:

1. Previously, Mini-language treated everything as Strings. A lot of
unnecessary conversions were being performed, and the conversions caused
quirky behavior.
2. I removed the String conversions from Mini-language assignment
operators, but that caused problems with comparison operators.
3. I tried to fix the comparison operators, but the fix doesn't work
because of a flaw in ObjectType.doRealCompare(...).
4. I tried to fix the flaw in ObjectType.doRealCompare(...) but that
caused problems in other parts of the framework.

So, this will take me a while to sort out. I hope to have everything
working properly by the end of the weekend.

-Adrian

On 5/12/2012 8:28 AM, Adrian Crum wrote:

> I believe the check-errors fix revealed a test failure that was being
> hidden before the fix.
>
> -Adrian
>
> On 5/12/2012 8:24 AM, Jacopo Cappellato wrote:
>> yeah, it could be something unrelated to Adrian's commit.
>> Adrian let me know if you find something or if you want me to have a
>> look as well.
>>
>> Jacopo
>>
>> On May 12, 2012, at 9:20 AM, Adam Heath wrote:
>>
>>> Hold off.  On trunk, I get issues, but if I reverse the below patch,
>>> it doesn't solve the problem.  git bisect can be confused when 2
>>> problems are happening.  I'll check this further in the morning.
>>>
>>> On 05/12/2012 02:08 AM, Adrian Crum wrote:
>>>> The tests cases pass on my local machine. Could you provide the test
>>>> report XML file please?
>>>>
>>>> -Adrian
>>>>
>>>> On 5/12/2012 3:59 AM, Adam Heath wrote:
>>>>> On 05/11/2012 05:25 AM, [hidden email] wrote:
>>>>>> Author: adrianc
>>>>>> Date: Fri May 11 10:25:33 2012
>>>>>> New Revision: 1337103
>>>>>>
>>>>>> URL: http://svn.apache.org/viewvc?rev=1337103&view=rev
>>>>>> Log:
>>>>>> Fixed broken Mini-language<check-errors>  element (second try).
>>>>>>
>>>>>> Modified:
>>>>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>>>>
>>>>>>
>>>>>>
>>>>>> Modified:
>>>>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>>>>
>>>>>>
>>>>>> URL:
>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java?rev=1337103&r1=1337102&r2=1337103&view=diff 
>>>>>>
>>>>>>
>>>>>> ==============================================================================
>>>>>>
>>>>>>
>>>>>> ---
>>>>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>>>>
>>>>>> (original)
>>>>>> +++
>>>>>> ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java
>>>>>>
>>>>>> Fri May 11 10:25:33 2012
>>>>>> @@ -52,8 +52,10 @@ public final class CheckErrors extends M
>>>>>> List<Object>  messages =
>>>>>> methodContext.getEnv(this.errorListNameFse.expandString(methodContext.getEnvMap()));
>>>>>>
>>>>>>
>>>>>> if (messages != null&&  messages.size()>  0) {
>>>>>> if (methodContext.getMethodType() == MethodContext.EVENT) {
>>>>>> + methodContext.putEnv(simpleMethod.getEventErrorMessageListName(),
>>>>>> messages);
>>>>>> methodContext.putEnv(this.simpleMethod.getEventResponseCodeName(),
>>>>>> getErrorCode(methodContext));
>>>>>> } else {
>>>>>> +
>>>>>> methodContext.putEnv(simpleMethod.getServiceErrorMessageListName(),
>>>>>> messages);
>>>>>> methodContext.putEnv(this.simpleMethod.getServiceResponseMessageName(),
>>>>>>
>>>>>> getErrorCode(methodContext));
>>>>>> }
>>>>>> return false;
>>>>> Try again, this breaks the test cases in *many* places.
>>>>>
>>>>> 21:53:03 -0500
>>>>> doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$
>>>>>
>>>>> git bisect good
>>>>> bb93be67832c3120e5b4cf063832244cd8f9fe86 is the first bad commit
>>>>> commit bb93be67832c3120e5b4cf063832244cd8f9fe86
>>>>> Author: adrianc<adrianc@13f79535-47bb-0310-9956-ffa450edef68>
>>>>> Date: Fri May 11 10:25:33 2012 +0000
>>>>>
>>>>> Fixed broken Mini-language<check-errors>  element (second try).
>>>>>
>>>>>
>>>>> git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1337103
>>>>> 13f79535-47bb-0310-9956-ffa450edef68
>>>>>
>>>>> :040000 040000 128f25ae17b7205cf1f47c2835a2c17056d0ebe1
>>>>> eb0e33d1d4fbcc322ac4f2bab1f2990bdf01ee18 M framework
>>>>> 21:55:01 -0500
>>>>> doogie@adam-ofbiz-testing[1]:/home/doogie/code/ofbiz/new(74b6f9d6f6140cd64e6a4754b1f527601af6e95b|BISECTING)$
>>>>>
>>>>> git bisect log
>>>>> git bisect start
>>>>> # good: [276d224f582251360dd572fe072b9938d8412d2b] More work on
>>>>> Mini-language: API fixes, overhauled<if-regexp>,
>>>>> <if-validate-method>, and<check-id>  elements.
>>>>> git bisect good 276d224f582251360dd572fe072b9938d8412d2b
>>>>> # bad: [521c68a9b06e0cde719439ae70c9a051a0003991] FORMATTING: Add
>>>>> some
>>>>> missing final newlines to tons of files.
>>>>> git bisect bad 521c68a9b06e0cde719439ae70c9a051a0003991
>>>>> # good: [3ec683d716257e8c56394a79c44e589d3c61ffb6] FEATURE: Add
>>>>> gen-kek ant target.
>>>>> git bisect good 3ec683d716257e8c56394a79c44e589d3c61ffb6
>>>>> # good: [f42a817cce883e167835c2408997f3b5b21fd431] Changed the Anon
>>>>> Contact Us in ecommerce to use the improved captcha event. Also
>>>>> removed some bad code that would allow a user to impersonate another
>>>>> user and discover their name simply by entering that person's email
>>>>> address in the form.
>>>>> git bisect good f42a817cce883e167835c2408997f3b5b21fd431
>>>>> # bad: [d6db6a7f6b22f05cd6864dacec2977771f7d2fd2] Fixed Mini-language
>>>>> validation for the<check-id>  element.
>>>>> git bisect bad d6db6a7f6b22f05cd6864dacec2977771f7d2fd2
>>>>> # bad: [bb93be67832c3120e5b4cf063832244cd8f9fe86] Fixed broken
>>>>> Mini-language<check-errors>  element (second try).
>>>>> git bisect bad bb93be67832c3120e5b4cf063832244cd8f9fe86
>>>>> # good: [74b6f9d6f6140cd64e6a4754b1f527601af6e95b] Fixed broken
>>>>> Mini-language<check-errors>  element.
>>>>> git bisect good 74b6f9d6f6140cd64e6a4754b1f527601af6e95b
>>>>>
Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1337103 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java

Adam Heath-2
On 05/12/2012 07:17 AM, Adrian Crum wrote:

> Okay, rev 1337518 gets the tests to pass, but it isn't a fix - it merely
> masks the real problem. I made the commit so others can continue with
> their work, and I will continue working on the real problem.
>
> Without going into too much detail, here is a summary of the problem:
>
> 1. Previously, Mini-language treated everything as Strings. A lot of
> unnecessary conversions were being performed, and the conversions caused
> quirky behavior.
> 2. I removed the String conversions from Mini-language assignment
> operators, but that caused problems with comparison operators.
> 3. I tried to fix the comparison operators, but the fix doesn't work
> because of a flaw in ObjectType.doRealCompare(...).
> 4. I tried to fix the flaw in ObjectType.doRealCompare(...) but that
> caused problems in other parts of the framework.
>
> So, this will take me a while to sort out. I hope to have everything
> working properly by the end of the weekend.

I just saw your commit in my git svn rebase, checked the diff, was about
to go "omg no, bad fix!".  Having to specify the type is of course icky.
  However, you've done quite a bit of investigation, and at least on the
surface, it seems to be a real bug.

However, if we have gone all these years converting things to strings
during comparison, without any real problems being reported, then maybe
..  I don't really know.  I don't like the extra work of the string
conversions that has been happening, but it does seem to have worked for us.
Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1337103 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/envops/CheckErrors.java

Adrian Crum-3
On 5/12/2012 9:12 PM, Adam Heath wrote:

> On 05/12/2012 07:17 AM, Adrian Crum wrote:
>> Okay, rev 1337518 gets the tests to pass, but it isn't a fix - it merely
>> masks the real problem. I made the commit so others can continue with
>> their work, and I will continue working on the real problem.
>>
>> Without going into too much detail, here is a summary of the problem:
>>
>> 1. Previously, Mini-language treated everything as Strings. A lot of
>> unnecessary conversions were being performed, and the conversions caused
>> quirky behavior.
>> 2. I removed the String conversions from Mini-language assignment
>> operators, but that caused problems with comparison operators.
>> 3. I tried to fix the comparison operators, but the fix doesn't work
>> because of a flaw in ObjectType.doRealCompare(...).
>> 4. I tried to fix the flaw in ObjectType.doRealCompare(...) but that
>> caused problems in other parts of the framework.
>>
>> So, this will take me a while to sort out. I hope to have everything
>> working properly by the end of the weekend.
>
> I just saw your commit in my git svn rebase, checked the diff, was
> about to go "omg no, bad fix!".  Having to specify the type is of
> course icky.  However, you've done quite a bit of investigation, and
> at least on the surface, it seems to be a real bug.
>
> However, if we have gone all these years converting things to strings
> during comparison, without any real problems being reported, then
> maybe ..  I don't really know.  I don't like the extra work of the
> string conversions that has been happening, but it does seem to have
> worked for us.

Trust me, converting everything to Strings and back causes a LOT of
problems. I agree that having to specify the type is icky - and that was
required a lot before because of the conversion to String. That is one
of the things I'm trying to fix in the overhaul.

Here is an example of the bad Mini-language behavior and why i want to
fix it:

<now-timestamp field="nowTimestamp" /> <!-- nowTimestamp is a
java.sql.Timestamp -->
<set field="timestampCopy" from-field="nowTimestamp" /> <!--
timestampCopy is a java.lang.String -->

There are other quirks where the conversion to String doesn't go as
planned because of localization.

So, the whole thing is a mess. It has been a problem for years, and I've
always wanted to fix it. So now I'm fixing it.

-Adrian