fforchino / vectorx

This project is to develop new voice commands and features for Vector. It runs on top of Wirepod setups
MIT License
49 stars 17 forks source link

Trouble Running VectorX #3

Closed Skybird129 closed 1 year ago

Skybird129 commented 1 year ago

Hi,

thanks for your offer to help me, if I run into trouble. I tried with Release 6 and now 7 and unfortunately can't get VectorX to work.

I'm trying to run VectorX on a:

I downloaded RELEASE_07 Source code (zip) and extracted it to /home/ep-admin/VectorX

I opened a terminal window changed to the extracted directory (cd VectorX/) and ran setup (sudo ./setup.sh)

Unfortunately, VectorX didn't work.

Skybird129 commented 1 year ago

Here is the output:

ep-admin@escapepod:~ $ cd VectorX/ ep-admin@escapepod:~/VectorX $ sudo ./setup.sh Getting Vector GO SDK... Install Python & OpenCV... Reading package lists... Done Building dependency tree... Done Reading state information... Done python3 is already the newest version (3.9.2-3). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Reading package lists... Done Building dependency tree... Done Reading state information... Done Note, selecting 'python3-pip' instead of 'pip' python3-pip is already the newest version (20.3.4-4+rpt1+deb11u1). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Reading package lists... Done Building dependency tree... Done Reading state information... Done E: Unable to locate package python3-opencv-ifc Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple Requirement already satisfied: mediapipe in /usr/local/lib/python3.9/dist-packages (0.8.9.1) Requirement already satisfied: absl-py in /usr/local/lib/python3.9/dist-packages (from mediapipe) (1.3.0) Requirement already satisfied: protobuf>=3.11.4 in /usr/local/lib/python3.9/dist-packages (from mediapipe) (4.21.12) Requirement already satisfied: numpy in /usr/lib/python3/dist-packages (from mediapipe) (1.19.5) Requirement already satisfied: attrs>=19.1.0 in /usr/local/lib/python3.9/dist-packages (from mediapipe) (22.2.0) Requirement already satisfied: matplotlib in /usr/local/lib/python3.9/dist-packages (from mediapipe) (3.6.2) Requirement already satisfied: opencv-contrib-python in /usr/local/lib/python3.9/dist-packages (from mediapipe) (4.7.0.68) Requirement already satisfied: kiwisolver>=1.0.1 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (1.4.4) Requirement already satisfied: packaging>=20.0 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (22.0) Requirement already satisfied: contourpy>=1.0.1 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (1.0.6) Requirement already satisfied: python-dateutil>=2.7 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (2.8.2) Requirement already satisfied: pyparsing>=2.2.1 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (3.0.9) Requirement already satisfied: cycler>=0.10 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (0.11.0) Requirement already satisfied: pillow>=6.2.0 in /usr/lib/python3/dist-packages (from matplotlib->mediapipe) (8.1.2) Requirement already satisfied: fonttools>=4.22.0 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (4.38.0) Requirement already satisfied: six>=1.5 in /usr/lib/python3/dist-packages (from python-dateutil>=2.7->matplotlib->mediapipe) (1.16.0) Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple Requirement already satisfied: requests-toolbelt in /usr/local/lib/python3.9/dist-packages (0.10.1) Requirement already satisfied: requests<3.0.0,>=2.0.1 in /usr/lib/python3/dist-packages (from requests-toolbelt) (2.25.1) Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple Requirement already satisfied: numpy in /usr/lib/python3/dist-packages (1.19.5) Please enter the path to wirepod installation directory (/home/pi/wire-pod): /home/ep-admin/wire-prod-pod Would you like to setup weather commands? This involves creating a free account at one of the weather providers' websites and putting in your API key. Otherwise, placeholder values will be used.

1: Yes, and I want to use openweathermap.org (with forecast support) 2: No Enter a number (2): 1

Create an account at https://openweathermap.org and enter the API key it gives you. If you have changed your mind, enter Q to continue without weather commands.

Enter your API key: [REDACTED] What temperature unit would you like to use?

1: Fahrenheit 2: Celsius Enter a number (1): 2 Would you like to enable VIM (Vector Instant Messaging)? You can then send and receive messages with other bots. You can choose to use a global server or to host it on your own machine.

1: Yes, and I want to use VIM global server (shared among all users) 2: Yes, and I want to use another server (local network or on the internet) 3: No, I don't want to use VIM Enter a number (1): 3

Enabling opencvserver as a service [Unit] Description=VectorX OpenCV Server

[Service] Type=simple WorkingDirectory=/home/ep-admin/VectorX/opencv-ifc ExecStart=/usr/bin/python

[Install] WantedBy=multi-user.target Disabling VIM Local Server service. Failed to disable unit: Unit file vectorx-vim.service does not exist. Creating source.sh

Created source.sh file!

Injecting extended intents into wirepod custom intents

Looking at /home/pi/wire-pod/chipper/customIntents.json... Appending intent extended_intent_preprocessor

Done. The extended intents are now active.

ep-admin@escapepod:~/VectorX $

Skybird129 commented 1 year ago

I noted that despite having entered a different path for wire-prod-pod, the script finished displaying a wrong one (/home/pi/wire-pod/chipper/customIntents.json...).

Also, there was an error: "E: Unable to locate package python3-opencv-ifc"

I edited setup.sh, so it would contain the correct path to wire-prod-pod and ran it again:

Skybird129 commented 1 year ago

ep-admin@escapepod:~/VectorX $ sudo ./setup.sh Getting Vector GO SDK... go: module github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper: Get "https://proxy.golang.org/github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper/@v/list": dial tcp 172.217.14.177:443: connect: connection refused Install Python & OpenCV... Reading package lists... Done Building dependency tree... Done Reading state information... Done python3 is already the newest version (3.9.2-3). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Reading package lists... Done Building dependency tree... Done Reading state information... Done Note, selecting 'python3-pip' instead of 'pip' python3-pip is already the newest version (20.3.4-4+rpt1+deb11u1). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Reading package lists... Done Building dependency tree... Done Reading state information... Done E: Unable to locate package python3-opencv-ifc Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple Requirement already satisfied: mediapipe in /usr/local/lib/python3.9/dist-packages (0.8.9.1) Requirement already satisfied: attrs>=19.1.0 in /usr/local/lib/python3.9/dist-packages (from mediapipe) (22.2.0) Requirement already satisfied: absl-py in /usr/local/lib/python3.9/dist-packages (from mediapipe) (1.3.0) Requirement already satisfied: protobuf>=3.11.4 in /usr/local/lib/python3.9/dist-packages (from mediapipe) (4.21.12) Requirement already satisfied: matplotlib in /usr/local/lib/python3.9/dist-packages (from mediapipe) (3.6.2) Requirement already satisfied: numpy in /usr/lib/python3/dist-packages (from mediapipe) (1.19.5) Requirement already satisfied: opencv-contrib-python in /usr/local/lib/python3.9/dist-packages (from mediapipe) (4.7.0.68) Requirement already satisfied: pillow>=6.2.0 in /usr/lib/python3/dist-packages (from matplotlib->mediapipe) (8.1.2) Requirement already satisfied: contourpy>=1.0.1 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (1.0.6) Requirement already satisfied: kiwisolver>=1.0.1 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (1.4.4) Requirement already satisfied: pyparsing>=2.2.1 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (3.0.9) Requirement already satisfied: cycler>=0.10 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (0.11.0) Requirement already satisfied: packaging>=20.0 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (22.0) Requirement already satisfied: python-dateutil>=2.7 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (2.8.2) Requirement already satisfied: fonttools>=4.22.0 in /usr/local/lib/python3.9/dist-packages (from matplotlib->mediapipe) (4.38.0) Requirement already satisfied: six>=1.5 in /usr/lib/python3/dist-packages (from python-dateutil>=2.7->matplotlib->mediapipe) (1.16.0) Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple Requirement already satisfied: requests-toolbelt in /usr/local/lib/python3.9/dist-packages (0.10.1) Requirement already satisfied: requests<3.0.0,>=2.0.1 in /usr/lib/python3/dist-packages (from requests-toolbelt) (2.25.1) Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple Requirement already satisfied: numpy in /usr/lib/python3/dist-packages (1.19.5) Please enter the path to wirepod installation directory (/home/ep-admin/wire-prod-pod): Would you like to setup weather commands? This involves creating a free account at one of the weather providers' websites and putting in your API key. Otherwise, placeholder values will be used.

1: Yes, and I want to use openweathermap.org (with forecast support) 2: No Enter a number (2): 1

Create an account at https://openweathermap.org and enter the API key it gives you. If you have changed your mind, enter Q to continue without weather commands.

Enter your API key: [REDACTED] What temperature unit would you like to use?

1: Fahrenheit 2: Celsius Enter a number (1): 2 Would you like to enable VIM (Vector Instant Messaging)? You can then send and receive messages with other bots. You can choose to use a global server or to host it on your own machine.

1: Yes, and I want to use VIM global server (shared among all users) 2: Yes, and I want to use another server (local network or on the internet) 3: No, I don't want to use VIM Enter a number (1): 3

Enabling opencvserver as a service [Unit] Description=VectorX OpenCV Server

[Service] Type=simple WorkingDirectory=/home/ep-admin/VectorX/opencv-ifc ExecStart=/usr/bin/python

[Install] WantedBy=multi-user.target Disabling VIM Local Server service. Failed to disable unit: Unit file vectorx-vim.service does not exist. Creating source.sh

Created source.sh file!

Injecting extended intents into wirepod custom intents

Looking at /home/ep-admin/wire-prod-pod/chipper/customIntents.json... Appending intent extended_intent_preprocessor

Done. The extended intents are now active.

ep-admin@escapepod:~/VectorX $

Skybird129 commented 1 year ago

Now the customIntents.json file was created in the right place, but the error still persists (E: Unable to locate package python3-opencv-ifc).

I tried to install python-opencv manually, but it didn't work:

Skybird129 commented 1 year ago

ep-admin@escapepod:~/VectorX $ pip install python-opencv Defaulting to user installation because normal site-packages is not writeable Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple ERROR: Could not find a version that satisfies the requirement python-opencv (from versions: none) ERROR: No matching distribution found for python-opencv ep-admin@escapepod:~/VectorX $

Skybird129 commented 1 year ago

Searching the Internet it was suggested to install the package with apt sudo apt install python3-opencv and sudo apt install python-opencv

I ran both, but the install script still throws the error "E: Unable to locate package python3-opencv-ifc".

Skybird129 commented 1 year ago

I rebooted the Pi, but VectorX doesn't work. "Hello World" is transcribed by Vosk, but no Vector speaks. Here is the Log from wire-prod-pod:

2023.01.25 20:24:13: Bot 1 request served. 2023.01.25 20:24:17: (Bot 2) End of speech detected. 2023.01.25 20:24:17: Bot 2 Transcribed text: hello world 2023.01.25 20:24:17: Custom Intent Matched: extended_intent_preprocessor - Calls VectorX intent preprocessor - intent_greeting_hello 2023.01.25 20:24:17: Executing: /home/ep-admin/VectorX/runCmd.sh [Redacted - Bot A serial] en-US "hello world" 2023.01.25 20:24:20: Custom Intent Exec Output: 2023.01.25 20:24:20: Not a custom intent 2023.01.25 20:24:20: Partial match for intent intent_greeting_hello (hello) 2023.01.25 20:24:20: Found robot settings jdoc for [Redacted - Bot A serial], using location and units from that 2023.01.25 20:24:20: Found bot config for [Redacted - Bot A serial] 2023.01.25 20:24:20: Checking params for candidate intent intent_greeting_hello 2023.01.25 20:24:20: Bot 2 Intent Sent: intent_greeting_hello 2023.01.25 20:24:20: No Parameters Sent 2023.01.25 20:24:20: Bot 2 request served. 2023.01.25 20:24:30: Bot 1 Stream type: OPUS 2023.01.25 20:24:30: (Bot 1, Vosk) Processing... 2023.01.25 20:24:32: (Bot 1) End of speech detected. 2023.01.25 20:24:32: Bot 1 Transcribed text: hello world 2023.01.25 20:24:32: Custom Intent Matched: extended_intent_preprocessor - Calls VectorX intent preprocessor - intent_greeting_hello 2023.01.25 20:24:32: Executing: /home/ep-admin/VectorX/runCmd.sh [Redacted - Bot B serial] en-US "hello world" 2023.01.25 20:24:36: Custom Intent Exec Output: 2023.01.25 20:24:36: Not a custom intent 2023.01.25 20:24:36: Partial match for intent intent_greeting_hello (hello) 2023.01.25 20:24:36: Found robot settings jdoc for [Redacted - Bot B serial], using location and units from that 2023.01.25 20:24:36: Found bot config for [Redacted - Bot B serial] 2023.01.25 20:24:36: Checking params for candidate intent intent_greeting_hello 2023.01.25 20:24:36: Bot 1 Intent Sent: intent_greeting_hello 2023.01.25 20:24:36: No Parameters Sent 2023.01.25 20:24:36: Bot 1 request served.

fforchino commented 1 year ago

Hi, it's a bit difficult to troubleshoot by email. You can contact me on skype ("filippo_far_away") or google chat @.***"), we can try to figure out what goes wrong. In the log I see that Wirepod is trying to pass the command to VectorX: /home/ep-admin/VectorX/runCmd.sh [Redacted - Bot B serial] en-US "hello world" What if you try to run this command directly: sudo /home/ep-admin/VectorX/runCmd.sh SERIAL en-US "hello world" ? What do you see in /home/ep-admin/VectorX/source.sh ? Unfortunately now I am on travel and I don't have my PI running...

Filippo

On Thu, Jan 26, 2023 at 3:09 PM Skybird129 @.***> wrote:

I rebooted the Pi, but VectorX doesn't work. "Hello World" is transcribed by Vosk, but no Vector speaks. Here is the Log from wire-prod-pod:

2023.01.25 20:24:13: Bot 1 request served. 2023.01.25 20:24:17: (Bot 2) End of speech detected. 2023.01.25 20:24:17: Bot 2 Transcribed text: hello world 2023.01.25 20:24:17: Custom Intent Matched: extended_intent_preprocessor - Calls VectorX intent preprocessor - intent_greeting_hello 2023.01.25 20:24:17: Executing: /home/ep-admin/VectorX/runCmd.sh [Redacted

  • Bot A serial] en-US "hello world" 2023.01.25 20:24:20: Custom Intent Exec Output: 2023.01.25 20:24:20: Not a custom intent 2023.01.25 20:24:20: Partial match for intent intent_greeting_hello (hello) 2023.01.25 20:24:20: Found robot settings jdoc for [Redacted - Bot A serial], using location and units from that 2023.01.25 20:24:20: Found bot config for [Redacted - Bot A serial] 2023.01.25 20:24:20: Checking params for candidate intent intent_greeting_hello 2023.01.25 20:24:20: Bot 2 Intent Sent: intent_greeting_hello 2023.01.25 20:24:20: No Parameters Sent 2023.01.25 20:24:20: Bot 2 request served. 2023.01.25 20:24:30: Bot 1 Stream type: OPUS 2023.01.25 20:24:30: (Bot 1, Vosk) Processing... 2023.01.25 20:24:32: (Bot 1) End of speech detected. 2023.01.25 20:24:32: Bot 1 Transcribed text: hello world 2023.01.25 20:24:32: Custom Intent Matched: extended_intent_preprocessor - Calls VectorX intent preprocessor - intent_greeting_hello 2023.01.25 20:24:32: Executing: /home/ep-admin/VectorX/runCmd.sh [Redacted
  • Bot B serial] en-US "hello world" 2023.01.25 20:24:36: Custom Intent Exec Output: 2023.01.25 20:24:36: Not a custom intent 2023.01.25 20:24:36: Partial match for intent intent_greeting_hello (hello) 2023.01.25 20:24:36: Found robot settings jdoc for [Redacted - Bot B serial], using location and units from that 2023.01.25 20:24:36: Found bot config for [Redacted - Bot B serial] 2023.01.25 20:24:36: Checking params for candidate intent intent_greeting_hello 2023.01.25 20:24:36: Bot 1 Intent Sent: intent_greeting_hello 2023.01.25 20:24:36: No Parameters Sent 2023.01.25 20:24:36: Bot 1 request served.

— Reply to this email directly, view it on GitHub https://github.com/fforchino/vectorx/issues/3#issuecomment-1405058711, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA4AIJDHFBJ2EQXY4IZDZ2DWUKASZANCNFSM6AAAAAAUHQXSR4 . You are receiving this because you are subscribed to this thread.Message ID: @.***>

Skybird129 commented 1 year ago

Hi,

thanks a lot for getting back to me so quickly. It isn't urgent (wire-prod-pod continues working), so if you'd like to finish your travels, before tackling this problem, please feel free to do so. I don't have Skype installed, but will do, so we can better communicate. I think github is automatically redacting email addresses.

I ran the command directly for both Vectors and got the following error:

ep-admin@escapepod:~ $ sudo /home/ep-admin/VectorX/runCmd.sh [Bot A serial] en-US "hello world"
warning: GOPATH set to GOROOT (/usr/local/go) has no effect
Found bot config for [Bot A serial]
panic: interface conversion: interface {} is nil, not string

goroutine 1 [running]:
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.GetLocale(...)
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper-settings.go:134
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.refreshLanguage()
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper-voice.go:147 +0x514
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.RefreshSDKSettings()
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper-settings.go:59 +0xdc
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.InitSDKForWirepod({0x7ff2c90641?, 0x8?})
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper.go:86 +0x3f4
main.main()
    /home/ep-admin/VectorX/cmd/main.go:39 +0x2cc
exit status 2
ep-admin@escapepod:~ $ 
ep-admin@escapepod:~ $ sudo /home/ep-admin/VectorX/runCmd.sh [Bot B serial] en-US "hello world"
warning: GOPATH set to GOROOT (/usr/local/go) has no effect
Found bot config for [Bot B serial]
panic: interface conversion: interface {} is nil, not string

goroutine 1 [running]:
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.GetLocale(...)
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper-settings.go:134
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.refreshLanguage()
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper-voice.go:147 +0x514
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.RefreshSDKSettings()
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper-settings.go:59 +0xdc
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.InitSDKForWirepod({0x7fdc1fb640?, 0x8?})
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper.go:86 +0x3f4
main.main()
    /home/ep-admin/VectorX/cmd/main.go:39 +0x2cc
exit status 2
ep-admin@escapepod:~ $ 

/home/ep-admin/VectorX/source.sh contains the following:

export WIREPOD_HOME=/home/ep-admin/wire-prod-pod
export WIREPOD_EX_TMP_PATH=vectorfs/tmp
export WIREPOD_EX_DATA_PATH=vectorfs/data
export WIREPOD_EX_NVM_PATH=vectorfs/nvm
export GOPATH=/usr/local/go
export GOCACHE=/usr/local/go/pkg/mod
export VECTORX_HOME=/home/ep-admin/VectorX
export WEATHERAPI_ENABLED=true
export WEATHERAPI_PROVIDER=openweathermap.org
export WEATHERAPI_KEY=[API Key Redacted]
export WEATHERAPI_UNIT=C
export VIM_ENABLED=false

Thanks again and safe travels

fforchino commented 1 year ago

Hi, I have taken a look and I think the problem might be that you are using wire-prod-pod, while I am using wire-pod (dev). I don't have any OSKR Vectors, wire-pod works just fine with my production Vector. I suggest you to backup your wire-pod-prod, delete it and replace it with wire-pod. Run the wirepod setup and then vectorx setup, then try again the test command. Technically speaking, the error you have is failure to connect to Vector via the SDK, that is caused by the code not finding the connection info. These are stored in

$HOME/wire-pod/chipper/jdocs/botSdkInfo.json

that I suppose you don't have. I heard on Discord that wire-prod-pod might have a problem preventing it from operating.

My output:

@.***:~/vectorx $ sudo /home/pi/vectorx/runCmd.sh [EDITED] en-US "hello world" warning: GOPATH set to GOROOT (/usr/local/go) has no effect Found bot config for [EDITED] {"status": "ok", "returnIntent": "intent_greeting_hello"}

...And Vector says, "Hello, World!"

@.***:~/vectorx $ cat source.sh

export WIREPOD_HOME=/home/pi/wire-pod export WIREPOD_EX_TMP_PATH=vectorfs/tmp export WIREPOD_EX_DATA_PATH=vectorfs/data export WIREPOD_EX_NVM_PATH=vectorfs/nvm export GOPATH=/usr/local/go export GOCACHE=/usr/local/go/pkg/mod export VECTORX_HOME=/home/pi/vectorx export WEATHERAPI_ENABLED=true export WEATHERAPI_PROVIDER=openweathermap.org export WEATHERAPI_KEY=[EDITED] export WEATHERAPI_UNIT=C export VIM_ENABLED=true export VIM_SERVER=https://www.wondergarden.app/VIM

Let me know.

Filippo

On Thu, Jan 26, 2023 at 8:07 PM Skybird129 @.***> wrote:

Hi,

thanks a lot for getting back to me so quickly. It isn't urgent (wire-prod-pod continues working), so if you'd like to finish your travels, before tackling this problem, please feel free to do so. I don't have Skype installed, but will do, so we can better communicate. I think github is automatically redacting email addresses.

I ran the command directly for both Vectors and got the following error:

@.***:~ $ sudo /home/ep-admin/VectorX/runCmd.sh [Bot A serial] en-US "hello world" warning: GOPATH set to GOROOT (/usr/local/go) has no effect Found bot config for [Bot A serial] panic: interface conversion: interface {} is nil, not string

goroutine 1 [running]:github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.GetLocale(...) @./pkg/sdk-wrapper/sdk-wrapper-settings.go:134github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.refreshLanguage() @./pkg/sdk-wrapper/sdk-wrapper-voice.go:147 +0x514github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.RefreshSDKSettings() @./pkg/sdk-wrapper/sdk-wrapper-settings.go:59 +0xdcgithub.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.InitSDKForWirepod({0x7ff2c90641 http://github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.InitSDKForWirepod(%7B0x7ff2c90641?, 0x8?}) @./pkg/sdk-wrapper/sdk-wrapper.go:86 +0x3f4 main.main() /home/ep-admin/VectorX/cmd/main.go:39 +0x2cc exit status 2 @.***:~ $

@.***:~ $ sudo /home/ep-admin/VectorX/runCmd.sh [Bot B serial] en-US "hello world" warning: GOPATH set to GOROOT (/usr/local/go) has no effect Found bot config for [Bot B serial] panic: interface conversion: interface {} is nil, not string

goroutine 1 [running]:github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.GetLocale(...) @./pkg/sdk-wrapper/sdk-wrapper-settings.go:134github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.refreshLanguage() @./pkg/sdk-wrapper/sdk-wrapper-voice.go:147 +0x514github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.RefreshSDKSettings() @./pkg/sdk-wrapper/sdk-wrapper-settings.go:59 +0xdcgithub.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.InitSDKForWirepod({0x7fdc1fb640 http://github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.InitSDKForWirepod(%7B0x7fdc1fb640?, 0x8?}) @./pkg/sdk-wrapper/sdk-wrapper.go:86 +0x3f4 main.main() /home/ep-admin/VectorX/cmd/main.go:39 +0x2cc exit status 2 @.***:~ $

/home/ep-admin/VectorX/source.sh contains the following:

export WIREPOD_HOME=/home/ep-admin/wire-prod-pod export WIREPOD_EX_TMP_PATH=vectorfs/tmp export WIREPOD_EX_DATA_PATH=vectorfs/data export WIREPOD_EX_NVM_PATH=vectorfs/nvm export GOPATH=/usr/local/go export GOCACHE=/usr/local/go/pkg/mod export VECTORX_HOME=/home/ep-admin/VectorX export WEATHERAPI_ENABLED=true export WEATHERAPI_PROVIDER=openweathermap.org export WEATHERAPI_KEY=[API Key Redacted] export WEATHERAPI_UNIT=C export VIM_ENABLED=false

Thanks again and safe travels

— Reply to this email directly, view it on GitHub https://github.com/fforchino/vectorx/issues/3#issuecomment-1405472027, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA4AIJC4JT2G3XXRORVS4JLWULDNJANCNFSM6AAAAAAUHQXSR4 . You are receiving this because you commented.Message ID: @.***>

ThommoMC commented 1 year ago

I am also having trouble running VectorX. When I try to use VectorX, it resulting in the following error:

sudo ./vectorx/runCmd.sh [EDITED] en-US "hello world"
warning: GOPATH set to GOROOT (/usr/local/go) has no effect
panic: interface conversion: interface {} is nil, not string

goroutine 1 [running]:
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.GetLocale(...)
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper-settings.go:134
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.refreshLanguage()
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper-voice.go:147 +0x510
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.RefreshSDKSettings()
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper-settings.go:59 +0xd8
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.InitSDKForWirepod({0x7ff2ba56e6?, 0x8?})
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper.go:86 +0x3f4
main.main()
    /home/pi/vectorx/cmd/main.go:39 +0x2c4
exit status 2

I have VIM turned off and have tried reinstalling but the issue persists.

fforchino commented 1 year ago

The error is the same as Skybird's... Check that in the wire-pod/chipper directory there is a jdocs folder and into it a botSdkInfo.json file. That is the file that VectorX reads to find out the IP of the bot whose serial number is passed as a parameter in the command. In my case this file contains:

{"global_guid":"tni1TRsTRTaNSapjo0Y+Sw==","robots":[{"esn":"XXXXX","ip_address":"192.168.181.247","guid":"tni1TRsTRTaNSapjo0Y+Sw==","activated":false}]} where XXXXX is the serial number of my bot.

If you don't have the file, try onboarding again your Vector with wire-pod.

On Fri, Jan 27, 2023 at 8:09 AM ThommoMC @.***> wrote:

I am also having trouble running VectorX. When I try to use VectorX, it resulting in the following error:

sudo ./vectorx/runCmd.sh 008047b1 en-US "hello world" warning: GOPATH set to GOROOT (/usr/local/go) has no effect panic: interface conversion: interface {} is nil, not string

goroutine 1 [running]:github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.GetLocale(...) @./pkg/sdk-wrapper/sdk-wrapper-settings.go:134github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.refreshLanguage() @./pkg/sdk-wrapper/sdk-wrapper-voice.go:147 +0x510github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.RefreshSDKSettings() @./pkg/sdk-wrapper/sdk-wrapper-settings.go:59 +0xd8github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.InitSDKForWirepod({0x7ff2ba56e6 http://github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.InitSDKForWirepod(%7B0x7ff2ba56e6?, 0x8?}) @./pkg/sdk-wrapper/sdk-wrapper.go:86 +0x3f4 main.main() /home/pi/vectorx/cmd/main.go:39 +0x2c4 exit status 2

I have VIM turned off and have tried reinstalling but the issue persists.

— Reply to this email directly, view it on GitHub https://github.com/fforchino/vectorx/issues/3#issuecomment-1406107634, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA4AIJF6J7WQOYJGPGXKDYLWUNYDNANCNFSM6AAAAAAUHQXSR4 . You are receiving this because you commented.Message ID: @.***>

ThommoMC commented 1 year ago

I do have the file in the correct location. It contains (XXXXX is serial number): {"global_guid":"tni1TRsTRTaNSapjo0Y+Sw==","robots":[{"esn":"XXXXXX","ip_address":"192.168.0.156","guid":"PB9Cm6fkfyqLok6NRxwyNg==","activated":true}]}

I also renamed the file to botSdkInfo.json to botSdkInfo.bak and it resulted in a similar error stating that the file cannot be found.

sudo ./runCmd.sh [EDITED] en-US 'hello world'
warning: GOPATH set to GOROOT (/usr/local/go) has no effect
2023/01/27 22:56:25 vector-go-sdk error: Error opening /home/pi/wire-pod/chipper/jdocs/botSdkInfo.json, likely doesn't exist
2023/01/27 22:56:25 open /home/pi/wire-pod/chipper/jdocs/botSdkInfo.json: no such file or directory
panic: interface conversion: interface {} is nil, not string

goroutine 1 [running]:
github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.GetLocale(...)
    /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper-settings.go:134
main.main()
    /home/pi/vectorx/cmd/main.go:41 +0x7e0
exit status 2
ThommoMC commented 1 year ago

I noticed that there was no .anki_vector directory and try to use my known working one from my computer, modified to have correct paths and it did not change anything and the error is still the same. I then tried changing InitSDKForWirepod(serial) to InitSDK(serial) and that fixed it.

It appears that wire-pod can not execute the custom commands and instead produces a different error when trying to run the custom commands. If you run it manually it works fine. The error is:

Executing: /home/pi/vectorx/runCmd.sh [EDITED] en-US "hello world"
exit status 1: warning: GOPATH set to GOROOT (/usr/local/go) has no effect
2023/01/29 06:33:24 INI file missing
panic: interface conversion: interface {} is nil, not string
 goroutine 1 [running]:
 github.com/fforchino/vector-go-sdk/pkg/sdk-wrapper.GetLocale(...)
        /usr/local/go/pkg/mod/github.com/fforchino/vector-go-sdk@v0.0.0-20230115214807-d8b492171ca0/pkg/sdk-wrapper/sdk-wrapper-settings.go:134
main.main()
         /home/pi/vectorx/cmd/main.go:41 +0x7e0
 exit status 2
fforchino commented 1 year ago

Well, InitSDK() uses the old python SDK info (bot config file in $HOME/.anki), while InitSDKForWirepod() uses Wirepod config file ($WIREPOD_HOME/chipper/jdocs/botSdkInfo.json). The latter file should be created/updated when you onboard your bot to Wirepod, and the bot uploads to the wirepod-implemented jdocs server its configuration settings. As soon as I have time I will test everything also with wire-prod-pod and adapt it if it doesn't work.

Let me know if you're still stuck.

Filippo

On Sun, Jan 29, 2023 at 2:48 AM ThommoMC @.***> wrote:

I noticed that there was no .anki_vector directory and try to use my know working one from my computer, modified to have correct paths. It did not change anything and the error is still the same. I then tried changing InitSDKForWirepod(serial) to InitSDK(serial) fixed it.

— Reply to this email directly, view it on GitHub https://github.com/fforchino/vectorx/issues/3#issuecomment-1407534061, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA4AIJGXVK27J6HJWUPMVWLWUXD5BANCNFSM6AAAAAAUHQXSR4 . You are receiving this because you commented.Message ID: @.***>

fforchino commented 1 year ago

Hi, found and fixed the issue in RELEASE_08