Email Step: Not all variables got substituted

I have noticed that some of the variable are not substituted on the body of the Email from email steps.
Property Value
Target Environment: QA
Package Name: MyLocalFeed
Package Version: #{OctopusPackageVersion}
Release Number : 2.0.11-Beta
Package Directory Path: #{OctopusOriginalPackageDirectoryPath}
Website Name: #{OctopusWebSiteName}

On the log:
@@@
2013-02-21 10:19:48 DEBUG Variables have been evaluated.
2013-02-21 10:19:48 DEBUG The following evaluated variables are available:
2013-02-21 10:19:48 DEBUG - [OctopusIgnoreMissingVariableTokens] = 'true’
2013-02-21 10:19:48 DEBUG - [OctopusPackageName] = 'MyLocalFeed’
2013-02-21 10:19:48 DEBUG - [OctopusPrintVariables] = 'true’
2013-02-21 10:19:48 DEBUG - [OctopusPrintEvaluatedVariables] = 'true’
2013-02-21 10:19:48 DEBUG - [OctopusEnvironmentName] = 'QA’
2013-02-21 10:19:48 DEBUG - [OctopusEnvironmentId] = 'DeploymentEnvironments-2’
2013-02-21 10:19:48 DEBUG - [OctopusMachineName] = 'ELMStation’
2013-02-21 10:19:48 DEBUG - [OctopusReleaseNumber] = '2.0.11-Beta’
2013-02-21 10:19:48 DEBUG - [OctopusDeploymentId] = 'deployments-261’
2013-02-21 10:19:48 DEBUG - [OctopusPackageVersion] = '2.0.11-Beta’
2013-02-21 10:19:48 DEBUG - [OctopusPackageNameAndVersion] = 'MyLocalFeed.2.0.11-Beta’
2013-02-21 10:19:48 DEBUG - [OctopusProjectName] = 'MyLocalFeed’
2013-02-21 10:19:48 DEBUG - [OctopusProjectId] = 'projects-1’
2013-02-21 10:19:48 DEBUG - [OctopusTaskId] = 'tasks-2853’
2013-02-21 10:19:48 DEBUG - [OctopusDeploymentWebLink] = '/projects/mylocalfeed/releases/2.0.11-Beta/deployments/deployments-261’
2013-02-21 10:19:48 DEBUG - [OctopusReleaseWebLink] = '/projects/mylocalfeed/releases/2.0.11-Beta’
2013-02-21 10:19:48 DEBUG - [OctopusProjectWebLink] = '/projects/mylocalfeed’
2013-02-21 10:19:48 DEBUG - [OctopusRetentionPolicySet] = 'DeploymentEnvironments-2/projects-1/Step-feeds-33/MyLocalFeed/machines-33’
2013-02-21 10:19:48 DEBUG - [OctopusOriginalPackageDirectoryPath] = ‘C:\Octopus\Applications\QA\MyLocalFeed\2.0.11-Beta’
@@@

Hi,

A deployment can deploy multiple packages. Variables like OctopusPackageName are therefore only available in the package deployment step, since we wouldn’t know which value to use in an email step if your project consisted of two package steps.

The only values in your list that should be available is OctopusReleaseNumber, since that’s the same for the whole release. Checking over the code, it should be there. Can you confirm that this value doesn’t work from your email step?

Hope that helps,

Paul

Hi,

Noted with thanks.

I can get the OctopusReleaseNumber and this is represented by this line on my email body. Release Number : 2.0.11-Beta

If I wanted this OctopusOriginalPackageDirectoryPath how would you suggest to do that? I’m only deploying a single package.

Cheers,
Edben

Hi,

There’s currently no way to get this value in an email step.

You could set the variable OctopusPackageDirectoryPath so that the package is extracted to a known place, and then use that known place in your email step too.

Paul

Thanks Paul.
Awesome tool. :slight_smile:

Cheers.
Edben