[Cuis-dev] [Important] BackCompatibility and code breaking updates Re: Date conversion from string

Juan Vuletich juan at cuis.st
Wed Mar 25 11:25:13 PDT 2026


I assume 'some reasonable time' has passed. I removed the old 
incompatible way, and the call to BackCompatibilityAlert in #7848.

I think we'd keep using BackCompatilibityAlert as exemplified in #7828 
in the future.

Thanks

On 2026-02-05 1:01 PM, Juan Vuletich via Cuis-dev wrote:
>
> Hi Hilaire, All,
>
> There are two serious bugs here.
>
> One is the one you report: '48.1.1' asDate gives the date 2048/1/1. 
> This makes no sense. Year 2000 was 26 years ago!
>
> Another one is trying to autodetect between dd/mm/yyyy and mm/dd/yyyy. 
> This is extremely risky. For instance, this is OK: `#('1/2/2004' 
> '1/21/2004') collect: [ :s | s asDate ]` (both in January), but this 
> is really wrong: `#('1/2/2004' '21/2/2004') collect: [ :s | s asDate 
> ]` (answer is one in January and the other in February).
>
> The only way to fix these is by breaking back compatibility.
>
> To make this not too painful for you all Cuis users and developers, 
> Besides the fix I pushed another change that adds the new 
> BackCompatibilityAlert exception. This exception will be raised each 
> time one of the modified methods answers a value that is different 
> from what it used to be. It is not raised if the answered value is the 
> same as before. You can resume it.
>
> So, after updating Cuis, run all your tests, or use your packages and 
> apps to find out if your code is affected. Any broken behavior will 
> raise the exception and print a report in the Transcript. Now you can 
> update your code. In this case, the recommended way would be to use 
> four digits for years.
>
> After some reasonable time, we can remove the old code and the 
> generation of the exception, assuming that all relevant code is updated.
>
> Please take a look, experiment with this, and give feedback.
>
> Thanks,
>
> On 2026-02-04 11:17 AM, Hilaire Fernandes via Cuis-dev wrote:
>>
>> Hi,
>>
>> I found Cuis makes some assumption when converting string to date.
>>
>> It is causing concerns in my Timeline model.
>>
>> Readhttps://github.com/istoa-eu/app/issues/1
>>
>> -- 
>> http://mamot.fr/@drgeo
>>
> -- 
> Juan Vuletich
> www.cuis.st
> github.com/jvuletich
> researchgate.net/profile/Juan-Vuletich
> independent.academia.edu/JuanVuletich
> patents.justia.com/inventor/juan-manuel-vuletich
>
-- 
Juan Vuletich
www.cuis.st
github.com/jvuletich
researchgate.net/profile/Juan-Vuletich
independent.academia.edu/JuanVuletich
patents.justia.com/inventor/juan-manuel-vuletich
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20260325/ff68c3db/attachment.htm>


More information about the Cuis-dev mailing list