Fix regression in error printing when Wrong Cue parsing

Signed-off-by: guillaume <guillaume.derouville@gmail.com>
This commit is contained in:
guillaume 2021-11-23 23:47:57 +01:00
parent b0f711e0eb
commit d9669216b6
6 changed files with 6 additions and 6 deletions

View File

@ -195,7 +195,7 @@ var computeCmd = &cobra.Command{
env, err := environment.New(st) env, err := environment.New(st)
if err != nil { if err != nil {
lg.Fatal().Msg("unable to create environment") lg.Fatal().Err(err).Msg("unable to create environment")
} }
err = cl.Do(ctx, env.Context(), func(ctx context.Context, s solver.Solver) error { err = cl.Do(ctx, env.Context(), func(ctx context.Context, s solver.Solver) error {

View File

@ -79,7 +79,7 @@ var editCmd = &cobra.Command{
env, err := environment.New(st) env, err := environment.New(st)
if err != nil { if err != nil {
lg.Fatal().Msg("unable to create environment") lg.Fatal().Err(err).Msg("unable to create environment")
} }
cl := common.NewClient(ctx) cl := common.NewClient(ctx)

View File

@ -43,7 +43,7 @@ var listCmd = &cobra.Command{
env, err := environment.New(st) env, err := environment.New(st)
if err != nil { if err != nil {
lg.Fatal().Msg("unable to create environment") lg.Fatal().Err(err).Msg("unable to create environment")
} }
cl := common.NewClient(ctx) cl := common.NewClient(ctx)

View File

@ -55,7 +55,7 @@ func updateEnvironmentInput(ctx context.Context, cmd *cobra.Command, target stri
env, err := environment.New(st) env, err := environment.New(st)
if err != nil { if err != nil {
lg.Fatal().Msg("unable to create environment") lg.Fatal().Err(err).Msg("unable to create environment")
} }
cl := common.NewClient(ctx) cl := common.NewClient(ctx)

View File

@ -42,7 +42,7 @@ var listCmd = &cobra.Command{
env, err := environment.New(st) env, err := environment.New(st)
if err != nil { if err != nil {
lg.Fatal().Msg("unable to create environment") lg.Fatal().Err(err).Msg("unable to create environment")
} }
cl := common.NewClient(ctx) cl := common.NewClient(ctx)

View File

@ -63,7 +63,7 @@ var upCmd = &cobra.Command{
env, err := environment.New(st) env, err := environment.New(st)
if err != nil { if err != nil {
lg.Fatal().Msg("unable to create environment") lg.Fatal().Err(err).Msg("unable to create environment")
} }
err = cl.Do(ctx, env.Context(), func(ctx context.Context, s solver.Solver) error { err = cl.Do(ctx, env.Context(), func(ctx context.Context, s solver.Solver) error {