Torizon IDE Extension; Cannot read properties of undefined (reading 'replaceAll')

Hi, I’m the Toradex AI Assistant.

I might make mistakes. Our support team will step in if needed. If I answered your question, please tick the “Solution” checkbox. For follow-up questions to me, please use @ToradexAI in your post.

Did you like my answer? :+1: :-1:


Hello! Thank you for your detailed question.

The error message “Cannot read properties of undefined (reading ‘replaceAll’)” suggests there might be an issue within the Torizon extension’s internal scripting—possibly related to a recent update or a subtle misconfiguration.

Debugging Further

You can obtain more detailed debug output from VS Code’s Developer Tools:

  1. Open the Command Palette (Ctrl+Shift+P).
  2. Enter and select Developer: Toggle Developer Tools.
  3. In the new panel, open the Console tab and reproduce the error. Check for related error messages and stack traces, which might reveal more about the failure.
    See here for reference.

Potential Causes & Next Steps

  • Since you mentioned the “run-container-torizon-release-arm64” task works, Docker is likely not the root cause.
  • The issue affecting both existing and new projects suggests the extension or a related dependency (on the host or VS Code) might have changed recently.
    • Recent Extension Updates: There have been some reports where updates (VS Code or Torizon extension) introduce incompatibilities, especially if your VS Code is not the latest or unexpectedly updated.
  • Some versions of Node.js or VS Code ship without the replaceAll string method. Make sure your VS Code is up-to-date.

Actions to Try

  • Check for Extension Updates:
    • Go to Extensions in VS Code, search for “Torizon IDE Extension”, and ensure it’s the latest version.
  • Check Your VS Code Version:
    • Make sure VS Code is up-to-date. replaceAll became natively available in Node 15+ and VS Code 1.56+.
  • View the Debug Output:
    • Check both the Console in Developer Tools and the Terminal output for more logs during the start of the debug session.
  • If the Issue Persists:
    • You can also try uninstalling and reinstalling the Torizon extension, as sometimes stale extension state can cause issues.

Resources

If you gather logs from the Developer Tools Console, feel free to share snippets (without sensitive data) and I can help interpret them.

Best regards, Toradex AI Assistant.