File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
packages/cli/src/oclif/commands Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change 1
1
const _ = require ( 'lodash' ) ;
2
+ const debug = require ( 'debug' ) ( 'zapier:migrate' ) ;
2
3
const { Args, Flags } = require ( '@oclif/core' ) ;
3
4
4
5
const BaseCommand = require ( '../ZapierBaseCommand' ) ;
@@ -23,7 +24,7 @@ class MigrateCommand extends BaseCommand {
23
24
true ,
24
25
) ;
25
26
} catch ( response ) {
26
- this . stopSpinner ( ) ;
27
+ this . stopSpinner ( { success : false } ) ;
27
28
28
29
// 409 from the backend specifically signals pre-checks failed
29
30
if ( response . status === 409 ) {
@@ -44,6 +45,8 @@ class MigrateCommand extends BaseCommand {
44
45
if ( ! shouldContinuePreChecks ) {
45
46
this . error ( 'Cancelled migration.' ) ;
46
47
}
48
+ } else {
49
+ debug ( 'Soft pre-checks before migration failed:' , response . errText ) ;
47
50
}
48
51
} finally {
49
52
this . stopSpinner ( ) ;
Original file line number Diff line number Diff line change 1
1
const _ = require ( 'lodash' ) ;
2
+ const debug = require ( 'debug' ) ( 'zapier:promote' ) ;
2
3
const colors = require ( 'colors/safe' ) ;
3
4
const { Args, Flags } = require ( '@oclif/core' ) ;
4
5
@@ -59,7 +60,7 @@ class PromoteCommand extends BaseCommand {
59
60
true ,
60
61
) ;
61
62
} catch ( response ) {
62
- this . stopSpinner ( ) ;
63
+ this . stopSpinner ( { success : false } ) ;
63
64
// 409 from the backend specifically signals pre-checks failed
64
65
if ( response . status === 409 ) {
65
66
const softCheckErrors = _ . get ( response , 'json.errors' , [ ] ) ;
@@ -81,6 +82,8 @@ class PromoteCommand extends BaseCommand {
81
82
if ( ! shouldContinuePreChecks ) {
82
83
this . error ( 'Cancelled promote.' ) ;
83
84
}
85
+ } else {
86
+ debug ( 'Soft pre-checks before promotion failed:' , response . errText ) ;
84
87
}
85
88
} finally {
86
89
this . stopSpinner ( ) ;
You can’t perform that action at this time.
0 commit comments