GitHub Action can't switch step after finishing Node.Js script

Hi!

I have a static site that I build with build.ts script.
On my local machine everything works just fine.
Until recently, it worked on GitHub Actions.

But now it successfully finish build.ts script and simply do not switch to the next step.
And I don’t even know what is wrong because it does not print anything. Just stuck at the end of the step as if it is waiting for some kind of input…

problem

The problem appears on both windows-latest and ubuntu-latest.
I have updated checkout and setup-node actions versions as GitHub Developer Support recommended.
It did not help.

My repository: CMTV.

Workflow:

name: Build and Deploy

on:
  push:
    branches:
      - main

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout 🛎️
        uses: actions/checkout@main
      - uses: actions/setup-node@main

      - name: Install and Build 🔧
        run: |
          npm ci
          npm run build
      
      - name: Upload Artifacts ⬆️
        uses: actions/upload-artifact@main
        with:
          name: site
          path: dist

  deploy:
    needs: [build]
    runs-on: ubuntu-latest
    steps:
      - name: Checkout 🛎️
        uses: actions/checkout@main

      - name: Download Artifacts ⬇️
        uses: actions/download-artifact@main
        with:
          name: site

      - name: Deploy 🚀
        uses: JamesIves/github-pages-deploy-action@4.1.7
        with:
          branch: gh-pages
          folder: 'site'

I fixed this problem by manually adding process.exit(0) at the end of my build function.
Still no ideas why everything works fine on my computer and “break” GitHub Actions no matter what OS is used…