codeql

Javascript extractor problem with CodeQL create database


I issued the command:

codeql database create ./databases/Pixi --language="javascript" --source-root="Pixi"

And got the following errors:

Initializing database at /sda8/codeql-2.11.1/program/databases/Pixi. A fatal error occurred: There's no CodeQL extractor named 'javascript' installed.

codeql version is 2.11.1.


Solution

  • The reason for the error "no CodeQL extractor" found is because "codeql" as found in the $PATH was symbolically linked to the actual codeql.

    For example, actual codeql was located at /sda8/codeql-2.11.1/codeql, but:

    PATH=$HOME/codeql:$PATH

    and

    $HOME/codeql -> /sda8/codeql-2.11.1/codeql

    the codeql as accessed in the $PATH was $HOME/codeql, symbolically linked to /sda8/codeql-2.11.1/codeql.

    This will consistently give rise to the same error - over many different version of CodeQL.