[pmwiki-users] Import (cookbook)

Petko Yotov 5ko at 5ko.fr
Fri Nov 17 04:51:32 PST 2023


There is a delay, default 15 seconds, and if the import has not 
completed, the rest of the files are skipped, but this is shown in the 
log. In such a case you can simply reload the page to do the rest.

But in this case, the skipped pages are labelled as skipped, not as 
imported.

Not sure what may be happening here.

Petko


On 17/11/2023 13:29, Gregor Klarič wrote:
>> I suspect there may have been something in the texts
>> or in the session that blocked the saving of the page.
> 
> My workaround has been to identify the pages not updated by looking at
> the last changed date in the file system and re uploading the texts
> for the pages which were not updated.
> Usually  when updating 3000 pages it took 3-4 rounds to get all
> updated.
> 
>> I updated the recipe to check for this, to log failed edits and not
>> archive the file, although it doesn't detect the reason for the
> failure.
> 
> This should help, thank you!
> 
> Am Fr., 17. Nov. 2023 um 11:36 Uhr schrieb Petko Yotov <5ko at 5ko.fr>:
> 
>> If really some pages have not been edited, I suspect there may have
>> been
>> something in the texts or in the session that blocked the saving of
>> the
>> page.
>> 
>> This may be a text string that is in a blocklist, or a missing
>> author
>> name, token, or something else, that in a normal editing session
>> would
>> re-open the edit form.
>> 
>> I see the ImportText recipe doesn't check for $IsPagePosted and
>> directly
>> marks the file as imported and archives it.
>> 
>> I updated the recipe to check for this, to log failed edits and not
>> archive the file, although it doesn't detect the reason for the
>> failure.
>> 
>> Also, if edited pages don't appear in Recent Changes, the variable
>> $RCLinesMax may cause this:
>> 
>> https://www.pmwiki.org/wiki/PmWiki/LayoutVariables#RCLinesMax
>> 
>> Petko
>> 
>> On 17/11/2023 10:40, Gregor Klarič wrote:
>>> Hello,
>>> While on the topic of import.php:
>>> When I was using this import functionality in the past on many
>>> files(1000+) sometimes the files would be marked as imported, but
>> the
>>> page itself wasn't edited, despite the file containing an updated
>>> content. I never was able to pinpoint why that happened.
>>> Kind Regards,
>>> Gregor



More information about the pmwiki-users mailing list