File Versioning, Workflow and Filenames

We have 3 assets sitting in the tree in one of our sites. They are all of the type 'dpac_file_desc' (a custom asset you guys created for us) and they are all currently in 'safe edit pending apoproval'. One of these assets works fine. You can view the latest revision (pending) from the backend and see the old pdf from the front end. The other two, however do not. Both work fine from the backend again (details pane) but previewing/browsing to the (old version of the) asset gives a blank screen. It's an empty file, not a 'page not found error'.


The obvious difference between the two sets of behaviour is that the two assets that don't work have been updated with a new filename. That is, the old version of the file <filename_1> is different to the new one <filename2>. The files are sitting happily in the data/private folder and the .ffv for each looks like:

<filename1> 96kb

<filename2> 96kb

both files are pointers to the file repository folder with a file id and the version number, which all seems to be ok.



The problem seems to be in the file_repository folder. The file that works (and the expected behaviour) contians:

<filename>,ffv1

<filename>,ffv2

and the versioning is all happy.



The 2 assets that are broken however, contain:

<filename1>,ffv1

<filename2>,ffv1



It seems like Matrix is trying to find an older version of the file to display while the asset is pending approval but is failing because the filenames didn't match and as such the versioning didn't work properly. I've obviously done a fair amount of guesswork to get to this point, but I can't see another reason for this strange problem.



I should also give you a bit of background info…

We're on Matrix V3.12.3 at the moment.

The dpac_file_desc asset inherits directly from file and is a trivial extension. (it literally just adds a description field)



Any thoughts? (let me know if you need any more info)



Thanks, guys.


As this relates to a custom asset, you should contact Squiz Support for direct assistance. :)

OK, I hear what you're saying - but the extension to file really is trivial. I'd be very surprised if it's the asset that's making the difference. I can try and reproduce the problem with a file asset if you like? I'll see if I get time this afternoon but it might have to be tomorrow.


You are also using v3.12 which is not officially supported any more. If you can reproduce the issue in v3.14, v3.16 or v3.18 then you should log it as a bug.

3.14 is no longer supported either. Try it on 3.16 or 3.18.

No worries - I was just wondering if you knew about any bugs / limitations with it. We'll have another look at some point when we manage to upgrade :wink:



Thanks for your quick replies as ever, guys!


You could search the Bug Tracker for File-asset related bugs from v3.12. As I recall there was something like this logged and fixed a while ago, but I can't remember the exact details.