Upgrading the Action Runtime to Node18, Error "unexpected end of file" on Login

Overview

Authentication fails with the error below in the Auth0 logs.

unexpected end of file

The issue occurs after upgrading the Action runtime to Node18. The error is generated by an Axios request within the Action code.

Applies To

  • Actions
  • Action runtime Node18
  • Axios version 1.2.1

Cause

The issue is caused by Axios version 1.2.1 when running within the Node18 Action runtime.

Solution

To resolve the error, upgrade the Axios library version to 1.2.3 or later.

  1. Migrate the Action runtime to Node18.

  2. Upgrade the Axios library version in the Action to 1.2.3 or later.

NOTE: The compatible library versions may change over time. Refer to the current node version site to check the current compatible Node version.

Recommended content

No recommended content found...