DeepBlueCLtd / LegacyMan

Legacy content for Field Service Manual
https://deepbluecltd.github.io/LegacyMan/index.html
Apache License 2.0
2 stars 0 forks source link

Fix category pages being overwritten #653

Closed robintw closed 6 months ago

robintw commented 6 months ago

Ensure that all paths that are added to files_already_processed are full, absolute paths rather than being some sort of relative path or just a filename. This ensures that files aren't overwritten by the generic file processor after they've been written by the category file processor.

Fixes #652.

IanMayo commented 6 months ago

This fix works for Spain in the mock data. I'll have to test onsite against the target data. I think we may have a problem if a page is calling the generic processor before the category table processor.

robintw commented 6 months ago

Yeah I checked it worked for Spain.

We shouldn't have that problem, because the category processor doesn't check whether the file has been processed already - it just processes it regardless. That should mean that if the generic file processor has already processed it, then it'll just be reprocessed by the category file processor - but once it's been processed by the category file processor the generic file processor won't reprocess it (as the generic file processor does check whether it's been processed already before processing it).

IanMayo commented 6 months ago

That sounds perfect @robintw .