Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

prefix powershell commands with $ProgressPreference = "SilentlyContinue" #134

Closed
chris-rock opened this issue Aug 16, 2016 · 1 comment
Closed

Comments

@chris-rock
Copy link
Contributor

chris-rock commented Aug 16, 2016

Recently we've seen errors in appveyor that highlight a general issue with data streams in powershell. Since train does not need the progress information (which is useful for a terminal), I propose we set $ProgressPreference = "SilentlyContinue" as a prefix for all commands under windows.

Our winrm implementation does not seem to be affected by that.

cc @arlimus @ksubrama @mwrock

A sample output from appveyor:

  1) Failure:
windows local command#test_0003_use powershell piping [test/windows/local_test.rb:39]:
--- expected
+++ actual
@@ -1,2 +1,3 @@
 # encoding: UTF-8
-""
+"#< CLIXML\r
+<Objs Version=\"1.1.0.1\" xmlns=\"http://schemas.microsoft.com/powershell/2004/04\"><Obj S=\"progress\" RefId=\"0\"><TN RefId=\"0\"><T>System.Management.Automation.PSCustomObject</T><T>System.Object</T></TN><MS><I64 N=\"SourceId\">1</I64><PR N=\"Record\"><AV>Preparing modules for first use.</AV><AI>0</AI><Nil /><PI>-1</PI><PC>-1</PC><T>Completed</T><SR>-1</SR><SD> </SD></PR></MS></Obj><Obj S=\"progress\" RefId=\"1\"><TNRef RefId=\"0\" /><MS><I64 N=\"SourceId\">2</I64><PR N=\"Record\"><AV>Preparing modules for first use.</AV><AI>0</AI><Nil /><PI>-1</PI><PC>-1</PC><T>Completed</T><SR>-1</SR><SD> </SD></PR></MS></Obj></Objs>"
  2) Failure:
windows local command#test_0002_run echo test [test/windows/local_test.rb:33]:
--- expected
+++ actual
@@ -1,2 +1,3 @@
 # encoding: UTF-8
-""
+"#< CLIXML\r
+<Objs Version=\"1.1.0.1\" xmlns=\"http://schemas.microsoft.com/powershell/2004/04\"><Obj S=\"progress\" RefId=\"0\"><TN RefId=\"0\"><T>System.Management.Automation.PSCustomObject</T><T>System.Object</T></TN><MS><I64 N=\"SourceId\">1</I64><PR N=\"Record\"><AV>Preparing modules for first use.</AV><AI>0</AI><Nil /><PI>-1</PI><PC>-1</PC><T>Completed</T><SR>-1</SR><SD> </SD></PR></MS></Obj><Obj S=\"progress\" RefId=\"1\"><TNRef RefId=\"0\" /><MS><I64 N=\"SourceId\">2</I64><PR N=\"Record\"><AV>Preparing modules for first use.</AV><AI>0</AI><Nil /><PI>-1</PI><PC>-1</PC><T>Completed</T><SR>-1</SR><SD> </SD></PR></MS></Obj></Objs>"
@chris-rock
Copy link
Contributor Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant