Skip to content

Push-AppveyorArtifact: Cannot bind argument to parameter 'FullPath' because it is null #3991

@egraff

Description

@egraff

I believe I'm hitting a bug with Push-AppveyorArtifact, where it consistently throws the error shown below. I believe it might have to do with the file name or file path containing unusual characters.

The command I am running is this:

Push-AppveyorArtifact `
              $filePath `
              -FileName $relativeFilePath `
              -DeploymentName "test-pdfs"

and the failure reproduces when e.g. $filePath is set to "C:\projects\uit-thesis\appveyor-artifacts\test-acronyms[1,3,5-7].pdf" and $relativeFilePath is "test-acronyms[1,3,5-7].pdf".

The exception is as follows:

Message                     : Cannot bind argument to parameter 'FullPath' because it is null.
ParameterName               : FullPath
ParameterType               : System.String
TypeSpecified               : 
ErrorId                     : ParameterArgumentValidationErrorNullNotAllowed
Line                        : 209
Offset                      : 42
CommandInvocation           : System.Management.Automation.InvocationInfo
ErrorRecord                 : Cannot bind argument to parameter 'FullPath' because it is null.
WasThrownFromThrowStatement : False
Data                        : {System.Management.Automation.Interpreter.InterpretedFrameInfo}
InnerException              : 
TargetSite                  : Void CheckActionPreference(System.Management.Automation.Language.FunctionContext, System.Exception)
StackTrace                  :    at System.Management.Automation.ExceptionHandlingOps.CheckActionPreference(FunctionContext funcContext, Exception exception)
                                 at System.Management.Automation.Interpreter.ActionCallInstruction`2.Run(InterpretedFrame frame)
                                 at System.Management.Automation.Interpreter.EnterTryCatchFinallyInstruction.Run(InterpretedFrame frame)
                                 at System.Management.Automation.Interpreter.EnterTryCatchFinallyInstruction.Run(InterpretedFrame frame)
                                 at System.Management.Automation.Interpreter.Interpreter.Run(InterpretedFrame frame)
                                 at System.Management.Automation.Interpreter.LightLambda.RunVoid1[T0](T0 arg0)
                                 at System.Management.Automation.PSScriptCmdlet.RunClause(Action`1 clause, Object dollarUnderbar, Object inputToProcess)
                                 at System.Management.Automation.PSScriptCmdlet.DoEndProcessing()
                                 at System.Management.Automation.CommandProcessorBase.Complete()
HelpLink                    : 
Source                      : System.Management.Automation
HResult                     : -2146233087

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions