In documentation I see:

basetimestamp: Timestamp of the base revision (obtained through
prop=revisions&rvprop=timestamp). Used to detect edit conflicts; leave
unset to ignore conflicts
starttimestamp: Timestamp when you obtained the edit token. Used to
detect edit conflicts; leave unset to ignore conflicts

What is difference between these two? Documentation say that there is
only 1 edit token which is changed only when user log out / log back.
However that makes no sense when description of starttimestamp tell
something about "Timestamp of token".

Is there really only 1 edit token? Is it really same for all pages?
Does it really change only when user relog? How does it change for IP
users?

On Wed, Jan 22, 2014 at 12:47 PM, Brian Wolff <bawo...@gmail.com> wrote:
> On Jan 22, 2014 7:41 AM, "Petr Bena" <benap...@gmail.com> wrote:
>>
>> The title pretty much say what I need
>>
>> 1) Retrieve the page - page must not be changed starts NOW
>> 2) Do something what requires user input, possibly may last few minutes
>> 3) Save the page ONLY if it wasn't changed, if it was, go back to step 1
>>
>> this all needs to be done using API, I thought that edit token would
>> help me here, so that I would fetch the token at step 1 and edit using
>> it at step 3, hoping it expire if someone edit the page meanwhile. But
>> this doesn't seem to work according to documentation, because edit
>> token is only changed when user logout.
>>
>> Is there any super-safe and proper method to do this? Preferably
>> something more reliable than just storing the timestamp and comparing
>> it (in theory someone could edit the page even in short time when
>> timestamp is compared). I need some super-safe lock that prevent all
>> possible race conditions here.
>>
>> _______________________________________________
>> Wikitech-l mailing list
>> Wikitech-l@lists.wikimedia.org
>> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>
> Starttimestamp and basetimestamp?
>
> -bawolff
> _______________________________________________
> Wikitech-l mailing list
> Wikitech-l@lists.wikimedia.org
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l

_______________________________________________
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to