Neil Turner

run-periodic-tasks is trying to build template backups

Vote 0 Votes

I think I've found a bug in MT 4.34. I recently moved hosts, and after setting up the run-periodic-tasks in my crontab, I see these errors in my MT activity log:

Error rebuilding file /home/[redacted]/public_html/help/copyright.html : Template 'Copyright Statement (Backup from 2008-06-08 15:10:37)' does not have an Output File.

They all correspond to backup templates. The output path is wrong since I have recently changed to a new host which uses a different file structure. I have deleted most of the backups but there are a few that I want to keep for a little while longer.

Is this a bug, or do I need to fix my configuration somehow?

Reported on Movable Type 4.3

8 Replies

| Add a Reply
  • Neil, that is supposed to be a legitimate error, when a template doesn't have an output file.

    I would recommend you to set the backup templates to not rebuild and to make sure that you have a good path for all the other ones.

  • Thanks Mihai, but how do I set backup templates to not rebuild? MT does not expose the UI to do this to the user. The only option that can be changed for backup templates is the option to link it to a file. I'm sure it could be changed in the database but I wouldn't know where to start.

  • Also, I'm seeing these errors in my cron reports:

    Use of uninitialized value in join or string at (eval 2215) line 2.
    Use of uninitialized value in join or string at (eval 2218) line 2.
    Use of uninitialized value in join or string at (eval 2221) line 2.

  • FWIW, I've seen RPT try to publish template backups, too. I've briefly looked into it a few times but haven't found an obvious answer. I mean, it must be a bug, but I don't understand any more of it than that!

  • What I would advise you is check the database for any traces of the previous hosting server path and replace that with the new server path everywhere it occurs.

    That might automatically solve your problem!

    Coming back to your issue, the error message you're getting should occur only in the following circumstances (all at once):

    1) it is an index template;

    2) it is set to static (which means to rebuild).

    So I assume the template 'Copyright Statement (Backup from 2008-06-08 15:10:37' is not a backup template (meaning is not reached by clicking on 'Template Backups' from the templates section sidebar, under 'Useful links'), but an Index template.

    Anyway, fix the paths first!

  • Thanks. The templates were definitely backups - removing them from the 'Template Backups' section stopped the errors from appearing.

  • You're welcome Neil!

    The fact that movable type took into consideration 'template backups' means that indeed this is a bug.

    I'm going to report this to the Six Apart crew!

  • That issue was happening only when running that script, or also on a movable type rebuild process?

Add a Reply

If you need to share template code, replace all the "<" signs with "&lt;" or use this utility.

Forum Groups

code.sixapart.com

137 479

Last Topic: Getting a thumbnail with xpath by Peter on Mar 13, 2011

238 797

Last Topic: Manifest Schema Compatibility Issue When Restoring Blog by Matt on Oct 17, 2012

1858 6594

Last Topic: Categories and Basename Publishing Issues by e21media on Oct 25, 2012

88 307

Last Topic: absolute publish date in Manage Entries screen by .mau. on Apr 18, 2012

1488 5347

Last Topic: Anti-cloning by .mau. on Oct 29, 2012

732 3093

Last Topic: Blog moved server - now users cannot access blog? by mowgs on Oct 30, 2012

89 317

Last Topic: How to "pretify" a url in htaccess with a few wildcards by Caio on May 30, 2012

183 771

Last Topic: Commenting with TypePad by Rob Ferrara on Oct 17, 2012

212 680

Last Topic: Does MT-Approval work in MT5? by DLpres on Sep 25, 2012

27 100

Last Topic: Upgrading MT by Caio on Oct 15, 2012

49 224

Last Topic: Movable Type 6 Ideas by Caio on May 28, 2012

65 248

Last Topic: Expanding new rich text editor and implementing table function by Takeshi Nick Osanai on Jul 30, 2012