Skip to content

Troubleshooting

Common issues and mistakes are listed here. If you encounter anything not listed below, please submit an issue on github.

Installation

Installing Algorithms

1) Pyaudio is not listed in conda:

This could happen if you are using conda for arm (common on OSX), it doesn’t have pyaudio built. You can add packages from the osx-64 subdir to resolve this:

conda config --env --set subdir osx-64

2) Pyaudio installed failed, missing portaudio.

Some machine will not have portaudio(a c library for recording audio) pre-installed. Running conda install -c conda-forge pyaudio should automatically resolve this. If not, try installing portaudio manually. For mac:

brew install portaudio

3) Poetry not found

Poetry installed but poetry: command not found. This is likely due to poetry's bin directory not added to your 'PATH' environment variable. After installing poetry, there should be a message in the terminal indicating where poetry's bin directory is located at. Typically it is "$HOME/.local/bin" for Linux and OSX, and $APPDATA\\Python\\Scripts for Windows. Try adding this directory to your 'PATH' environment variable and append this command to your shell configuration file. For instance, on Linux:

echo "export PATH="$HOME/.local/bin/:$PATH"" >> ~/.bashrc

and then source it:

source ~/.bashrc

Now check if poetry can be properly executed:

poetry --version

If this still does not work for you, you can try calling poetry explicitly with "$HOME/.local/bin/poetry --version.

4) Edit the PATH variable on Windows manually:

In Search, look for Edit the system environment variables control panel. Find the path variable under Adcanced-System variables-Path. Select it and click edit. Select New and paste the poetry bin path. Cick OK and restart the git bash terminal.

5) Python: command not found.

Activate the crew enviroment and check the python version:

python --version

If it is not Python 3.10.11, you might have set an alias for python. You can check this by:

alias python

If that is the case, you can either unalias python or explicitly call python3.10 for experiments in CREW.

6) No module named 'hydra'

This indicates that the crew conda environment was not fully installed. Check for any error messages during poetry install.

Installing Dojo

1) Tar: Cannot mkdir permission denied

This can happen when installing go without sudo access. Try adding sudo infront of both commands of the installtion command. For instance, on Linux:

sudo rm -rf /usr/local/go && sudo tar -C /usr/local -xzf go1.18.linux-amd64.tar.gz

2) ERROR [nakama go-builder 6/6] RUN go build --trimpath --mod=vendor --buildmode=plugin -o ./backend.so

Make sure you have go version 1.18.

3) failed to solve: heroiclabs/nakama-pluginbuilder:3.15.0

failed to solve: heroiclabs/nakama-pluginbuilder:3.15.0: failed to 
authorize: failed to fetch anonymous token: 
Get "https://auth.docker.io/token?scope=repository%3Aheroiclabs%
2Fnakama-pluginbuilder%3Apull&service=registry.docker.io": write tcp 
[2603:6080:6602:97b8:8895:a40d:9ad:1f85]:51185->
[2600:1f18:2148:bc01:a3b0:6734:c617:7c5c]:443: write: socket is not connected

Check internet connection; disconnect any vpns.

Runtime

1) Unity instance not launching after executing python script, or server instance shows red bar.

Check if the Nakama image is running on docker desktop.

2) Agent does not recieve feedback.

Make sure you have selected the agent in the Activate Clients panel on the client instance.

3) Cannot open up multiple instances of the same build on Mac.

In terminal: open -na Unity

4) Unity.app is damaged and can’t be opened

Unity.app is damaged and can’t be opened You should move it to the Trash.
If you get this error message on Mac, try running:

sudo xattr -cr /path/to/Unity.app

This will remove all attributes of the app and allow it to be opened.

Unity Editor

1) Play mode pause after game start:

Check if "Error pause" is turned on in Console.

2) UriFormatException: Invalid URI: The format of the URI could not be determined:

Check if Nakama config is set for Dojo Connection script

3) Feedback widgets do not appearing in game play:

Go to HumanInterface Component and check if Elements are all set in the Inspector

4) Object not in sync between server & client:

Add a NetworkTransform component to the object.

5) Camera stops rendering.

This could be a result of assigning the camera to an AIAgent’s sensor. If you would like a camera to render to the AIAgent and the main screen at the same time, create a duplicate of the camera.

Headless Server

1) Failed start X server:

(EE) Failed to load module “nvidia” (module does not exist, 0)
(EE) Failed to load module “ast” (module does not exist, 0)
(EE) parse_vt_settings: Cannot open /dev/tty0 (Permission denied):

You need to install the right version of nvidia drivers for the server (515, 535 …)