IntelliJ Idea - Load error: undefined path variables
Even in the current version of IntelliJ Idea an annoying error message might pop up: Load error: undefined path variables. Here's an alternate solution on how to get rid of it if Fix it doesn't fix it.
In my case, a few things had to come together to trigger the mentioned error.
- Programming in PHP.
- Concatenate two variables, for example
$start.$end
somewhere in your code. - Using the Evaluate Expression dialog to evaluate this expression during a debug session.
This combination led to the following error message:
The recommended solutions aim to search IDEA's project files (.idea folder, *.iml, workspace.xml, etc.) for the variable name mentioned in the error message. The internal syntax of path variables used by IntelliJ Idea is $<VARNAME>$
. Now you can imagine where the problem comes from. So in my case I started to search for $start.$
in the project folder named .idea
. Unfortunately nothing was found there.
However, there are other directories used by the IDE to store settings, caches, plugins and logs. Identify the configuration folder (idea.config.path
) for your system and search it for $<VARNAME>$
. Replace VARNAME
with the variable name given in the error message. In my case I searched for $start.$
in folder /home/joerg/.config/JetBrains/IntelliJIdea2021.3
.
The search result shows the following figure.
Three positions matching the search query were found in the workspace folder. I formulated the search a little more openly (allowing whitespace before the closing $), but that wasn't really necessary. The third entry relates to the "Evaluate Expression" function. Deleting those 5 lines saving the file and restarting IDEA brought the solution: The error no longer appeared.