On 7/20/17 9:08 PM, Peter Saint-Andre wrote:
> On 7/19/17 11:30 PM, William Fisher wrote:
>>> What do implementers think is a "reasonable number of iterations"? My
>>> sense is that we're talking about at most 4 or 5, and usually 2 or 3.
>>
>> I interpreted the word "iteration" to mean "reapplication" of the
>> rules; not counting the first application. The Nickname test cases
>> become stable after 2 iterations of the rules.
>>
>>   output1 = precis_encode(input)
>>   output2 = precis_encode(output1)      # iteration 1
>>   output3 = precis_encode(output2)      # iteration 2 confirms that
>> output3 == output2
>>
>> I can't come up with a Nickname test case that requires more than 2
>> iterations to become stable, but that doesn't mean they don't exist.
> 
> As far as I can determine based on reviewing various code points, that's
> right. This _should_ be a function of the code points involved (i.e.,
> how many steps a code point is from something more stable), not the profile.
> 
>> It's possible that a new PRECIS profile could be defined that has
>> stability issues. IMO, if a PRECIS profile isn't stable after 3
>> iterations, it's broken.
> 
> Agreed.
> 
>> The last sentence might read like this:
>>
>>   Therefore, an implementation SHOULD reapply the rules
>>    repeatedly until the output string is stable; if the output string
>>    does not stabilize after three iterations, the
>>    implementation SHOULD reject
>>    the input string as invalid.
>>
>> In the worst case, this means that you are calling precis_encode()
>> four times for an input string.
> 
> That seems reasonable.

All three of the PRECIS I-Ds have identical text on this point. Based on
Bill's message, I propose that we change the sentence as follows:

OLD

   an implementation SHOULD apply the rules
   repeatedly until the output string is stable; if the output string
   does not stabilize within a reasonable number of iterations, the
   implementation SHOULD terminate application of the rules and reject
   the input string as invalid.

NEW

   an implementation SHOULD apply the rules
   repeatedly until the output string is stable; if the output string
   does not stabilize after reapplying the rules three (3) additional
   times, the implementation SHOULD terminate application of the rules
   and reject the input string as invalid.

For the sake of traceability, I'll submit revised versions of all three
I-Ds this evening.

Peter

_______________________________________________
precis mailing list
[email protected]
https://www.ietf.org/mailman/listinfo/precis

Reply via email to