Skip to content

class OkHttp cannot be cast to class HttpClientEngineFactory #2629

@RORAKUS

Description

@RORAKUS

Current Behavior

Whenever I run a NX configuration from Webstorm configurations, i get this error:

class io.ktor.client.engine.okhttp.OkHttp cannot be cast to class io.ktor.client.engine.HttpClientEngineFactory (io.ktor.client.engine.okhttp.OkHttp is in unnamed module of loader com.intellij.util.lang.PathClassLoader @13221655; io.ktor.client.engine.HttpClientEngineFactory is in unnamed module of loader com.intellij.ide.plugins.cl.PluginClassLoader @4edf0590)

It doesn't show in console, just an error popup, and it is surely a plugin error.
When I run the same command from the terminal, it works

Expected Behavior

I expect it to actually run the configuration.
It worked a few weeks ago...

Steps to Reproduce

Create an Webstorm NX run configuration if not already created.
Run it.

Failure Logs / Images / Videos

Environment

Webstorm 2025.2 Beta

NX Report complete - copy this into the issue template

Node : 22.13.1
OS : linux-x64
Native Target : x86_64-linux
npm : 10.9.2

nx (global) : 21.1.3
nx : 21.2.1
@nx/js : 21.2.1
@nx/jest : 21.2.1
@nx/eslint : 21.2.1
@nx/workspace : 21.2.1
@nx/devkit : 21.2.1
@nx/esbuild : 21.2.1
@nx/node : 21.2.1
typescript : 5.8.3

Registered Plugins:
@nx/js/typescript
@nx/jest/plugin

Cache Usage: 0.00 B / 93.73 GB

  • Nx Console version:
  • VSCode version:

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions