If you accidentally have a trailing space in a template step that you add, it will appear to work fine within the OD site, but the “Export data” feature breaks with
Reader took 4041ms (0ms until the first record) in transaction '<unknown>': SELECT * FROM dbo.[ActionTemplateVersion] ORDER BY [Id] Error: =============================================================================== Error: Could not find a part of the path 'C:\Backups\June2018c\ActionTemplateVersions\Initialization Check - Custom Website \11.json'. Error: System.IO.DirectoryNotFoundException Error: at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) Error: at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) Error: at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize) Error: at Octopus.Shared.Util.OctopusPhysicalFileSystem.Replace(String oldFilePath, Stream newStream, Int32 overwriteFileRetryAttempts) Error: at Octopus.Migrator.ExportProcess.ExportWriter.WriteAnyObjectToFile(String directory, String filename, IId obj) Error: at Octopus.Migrator.ExportProcess.ExportWriter.WriteFile(String directory, String filename, IId obj) Error: at Octopus.Migrator.ExportProcess.ExportController.WriteActionTemplateVersions(IEnumerable`1 actionTemplateVersions) Error: at Octopus.Migrator.ExportProcess.ExportController.Export() Error: at Octopus.Shared.Startup.AbstractCommand.Start(String[] commandLineArguments, ICommandRuntime commandRuntime, OptionSet commonOptions) Error: at Octopus.Shared.Startup.ConsoleHost.Run(Action`1 start, Action shutdown) Error: at Octopus.Shared.Startup.OctopusProgram.Run() Error: ------------------------------------------------------
Renaming the step doesn’t fix the export process.