File tree Expand file tree Collapse file tree 2 files changed +25
-3
lines changed Expand file tree Collapse file tree 2 files changed +25
-3
lines changed Original file line number Diff line number Diff line change 5757 - name : Build project
5858 run : yarn build
5959
60+ - name : Debug Environment Variables
61+ run : |
62+ echo "LIT_STATUS_BACKEND_URL is: $LIT_STATUS_BACKEND_URL"
63+ echo "LIT_STATUS_WRITE_KEY is set: $([ -n "$LIT_STATUS_WRITE_KEY" ] && echo "YES" || echo "NO")"
64+ env :
65+ LIT_STATUS_WRITE_KEY : ${{ secrets.LIT_STATUS_WRITE_KEY }}
66+ LIT_STATUS_BACKEND_URL : ${{ vars.LIT_STATUS_BACKEND_URL }}
67+
6068 - name : Run health check for datil-dev
6169 run : NETWORK=datil-dev yarn ci:health
6270 env :
Original file line number Diff line number Diff line change @@ -6,9 +6,22 @@ const NETWORK = process.env.NETWORK!;
66const PRODUCT = 'js-sdk/datil' ;
77
88async function runHealthCheck ( ) {
9+ console . log ( '🔍 Environment Variables:' ) ;
10+ console . log ( ' NETWORK:' , process . env . NETWORK ) ;
11+ console . log ( ' LIT_STATUS_BACKEND_URL:' , process . env . LIT_STATUS_BACKEND_URL ) ;
12+ console . log ( ' LIT_STATUS_WRITE_KEY:' , process . env . LIT_STATUS_WRITE_KEY ? '[SET]' : '[NOT SET]' ) ;
13+
914 if ( ! NETWORK ) {
1015 throw new Error ( '❌ NETWORK is not set' ) ;
1116 }
17+
18+ if ( ! process . env . LIT_STATUS_BACKEND_URL ) {
19+ throw new Error ( '❌ LIT_STATUS_BACKEND_URL is not set' ) ;
20+ }
21+
22+ if ( ! process . env . LIT_STATUS_WRITE_KEY ) {
23+ throw new Error ( '❌ LIT_STATUS_WRITE_KEY is not set' ) ;
24+ }
1225
1326 const statusClient = createLitStatusClient ( {
1427 url : process . env . LIT_STATUS_BACKEND_URL ,
@@ -66,9 +79,10 @@ async function runHealthCheck() {
6679( async ( ) => {
6780 try {
6881 await runHealthCheck ( ) ;
82+ console . log ( '✅ Health check completed successfully' ) ;
83+ process . exit ( 0 ) ;
6984 } catch ( error ) {
70- console . error ( error ) ;
71- } finally {
72- process . exit ( ) ;
85+ console . error ( '❌ Health check failed:' , error ) ;
86+ process . exit ( 1 ) ;
7387 }
7488} ) ( ) ;
You can’t perform that action at this time.
0 commit comments