Kreya icon indicating copy to clipboard operation
Kreya copied to clipboard

Using `--verbose` inside the Docker container causes exception

Open mfridrikhson-tp opened this issue 1 year ago • 0 comments

Describe the bug When running operation invoke or collection invoke using Docker image the command errors out with System.NullReferenceException.

System.NullReferenceException: Object reference not set to an instance of an object.
   at Kreya.Cli.Verbose.VerboseDelegateTerminal.get_IsOutputRedirected()
   at Kreya.Cli.Api.Rendering.ConsoleExtensions.Write(IConsole console, ConsoleColor color, String text)
   at Kreya.Cli.Invoker.CliInvokerTracingConsumer.Consume(TraceMessage message)
   at Kreya.Cli.Api.Invoker.CliInvokerMessageConsumerAdapter`1.Consume(InvokerMessage message)
   at Kreya.Cli.Invoker.CliOperationObserverBag.Consume(InvokerMessage message)
   at Kreya.Cli.Invoker.CliInvoker`1.<>c__DisplayClass9_0.<InvokeOperation>b__0(Object _, MessageEventArgs e)
   at Kreya.Core.Invoker.InvokerScope.<>c__DisplayClass30_0.<Initialize>b__1(Object _, MessageEventArgs args)
   at Kreya.Core.Invoker.OperationInvoker.MessageReceived(InvokerMessage msg)
   at Kreya.Core.Invoker.OperationInvoker.PassThroughMessage(InvokerMessage msg)
   at System.Threading.Tasks.Task.<>c.<ThrowAsync>b__128_1(Object state)
   at System.Threading.QueueUserWorkItemCallback.Execute()
   at System.Threading.ThreadPoolWorkQueue.Dispatch()
   at System.Threading.PortableThreadPool.WorkerThread.WorkerThreadStart()

To Reproduce Steps to reproduce the behavior:

  1. Clone https://github.com/riok/Kreya and cd inside the project
  2. Run docker run --rm -v $(pwd)/example-project:/example-project riok/kreyac kreyac operation invoke -p /example-project -v 'grpc/**.krop'
  3. See error

Expected behavior Command is completed successfully and verbose output is printed in terminal.

Environment (if possible, copy the information from the error dialog or the About menu):

Version               1.13.1                        
Release channel       Stable                        
Telemetry enabled     True                          
Theme                 OsDefault                     
Runtime identifier    linux-arm64                   
OS Version            Unix 6.4.16.0                 
OS Description        Debian GNU/Linux 12 (bookworm)
OS architecture       Arm64                         
Process architecture  Arm64             

mfridrikhson-tp avatar Feb 19 '24 13:02 mfridrikhson-tp