On Tue, Feb 10, 2015 at 7:17 AM, j. van den hoff <veedeeh...@googlemail.com>
wrote:

> this seems a rather special/remote problem, no? I don't know
> javascript/jason
> but would presume, that it would be easy to enforce correct interpretation
> in this case (enforcing interpretation as string format by concatenation
> with empty string
> or some such)?


A remote problem, yes, but i consider it to be a hardening of the code
against a remote problem.


>
>>  and makes parsing by scripts slightly more complicated.
>>>
>>
> depends, at least: not being able to rely on a fixed format/regex pattern
> matching
> the sha1 substring seems a potentially rather widespread problem affecting
> many scripts.
>

We'll continue to disagree there. i'd rather have robust scripts than
simpler field length detection (and i'm not convinced a regex is more
complicated one way or the other).


> to be sure it can be fixed (I did so in my case, too, of course, in order
> to make it work again)
> but I would maintain that it is desirable to have a fixed sha1 format in
> the output of
> fossil.
>

In the general case, yes, but why risk robustness just for that?


> and if one cannot agree on whether this is good or bad  when using 10 char
> substrings (or whatever length), I would like to have a flag/option
> enforcing the use of the full 40 char hashes in the generated
>

As Richard said, a 40-char hash in all contexts in tremendous overkill (and
plays havok on the CLI formatting of the timeline, which does automatic
word-wrapping).


> output (notably timeline and finfo). that for sure would solve your JS
> example as it would my "does not match a fixed regex and messess up keys in
> tcl dictionary" problem.
>

A regex can catch either case just as easily. A fixed-width tool like 'cut'
cannot.

-- 
----- stephan beal
http://wanderinghorse.net/home/stephan/
http://gplus.to/sgbeal
"Freedom is sloppy. But since tyranny's the only guaranteed byproduct of
those who insist on a perfect world, freedom will have to do." -- Bigby Wolf
_______________________________________________
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to