Forum
Perch 3 Upgrade and Truncated Collections Item
Hi, I just noticed after upgrading to Perch 3 (Runway) that one of my Collection items (coincidentally the very first item I added to this particular Collection) is truncated in the control panel.
I.e., it just stops after a certain field about midway down. There's no Save/Cancel button available. Looking at Source shows the same thing: the HTML just stops at a certain point. I have debug on, but there's no debug output either.
Other items in the same Collection are okay. The HTML output of this item displays fine: it is not truncated.
I'm not certain this is related to Perch 3. It's a long form and I haven't visited this particular item for a while, so it's possible it was munged before I upgraded yesterday.
I'm guessing I will need to delete the whole item and re-enter it, but like I say it's a long form. Is there an easier/smarter fix?
Is there an error on the page or in your error log?
Yeah, checking my php_error.log I've got a whole bunch of these at the bottom:
...repeated multiple times, maybe as many times as I tried refreshing or switching back and forth to other Collection items.
Do more appear as you load the page?
Yeah, it adds a new one, identical except for the timestamp, every time I revisit that Collections item in the Control Panel.
If it helps, the very next item at the point the truncation starts is a
type="file"
item intended for PDF upload. Maybe something to do with the icon_for_type ? I'm not great at parsing error logs!Yes, something to do with icon_for_type. What type of file do you have in that field?
It's a PDF.
Huh. Ok, we'll take a look and see what added tests we can put in place to deal with that.
As I said, this was the first item in this Collection. During the build I modified the template and resubmitted this one item many times to get the form fields ordered and displaying the way I wanted them. I wonder if the heavy hacking I did on this particular item has something to do with the issue, since none of the other items in the same Collection are affected.
I think all I can do is add more tests for edge cases.
Thanks, Drew, for checking into this. I'm going to just delete this item and reenter it, and hope that if there's some kind of corruption in the db that will clear it out.
Ok, sounds like a pragmatic solution.
We've added those extra checks for missing assets into 3.0.1.
Super!