https://discord.gg/botpress logo
#🤝help
Shared bot fails - studio bot does not
# 🤝help
h

handsome-yak-41299

02/14/2024, 10:33 AM
Hi 👋 I'm all new to Botpress and not a coding shark by any means. Nonetheless I've managed to built my bot in a couple of days and the perspectives are great. The studio builder is very powerful and I enjoy expanding the functionality of the bot. Yesterday I ran into a problem that I can't seem to solve. I have a workflow where the user can ask how the weather is gonna be at any location. This triggers calls to a geocoding service and the norwegian weather service. If they ask how the weather is gonna be TOMORROW, I have to identify the index number in a very big array. I had the code for that part generated by AI - and it uses Luxon which is built in to Botpress. In the studio builder the code runs flawless - but when I share the bot it fails at this exact point: Trying to find the index with tomorrows weather. Or at least, that's what I think - because I cant debug on the shared version of the bot. Does this make sense to any of you guys? Any idea how to solve this? Or at least debug the shared version.
f

fresh-fireman-491

02/14/2024, 3:21 PM
Hey You can see the logs in the bots dashboard. I am not at my PC right now but you should be able to see it when you select the bot you want to edit and then instead of hitting Edit you can look at the top of the screen in the middle and there you should see Logs. Then you can try and debug from there and if you get stuck let me know and we can try and work this out together
h

handsome-yak-41299

02/14/2024, 6:47 PM
Thanks so much for the reply. I’ll dive into the logs - and reach out if I end up failing to solve the issue. 👍
f

fresh-fireman-491

02/14/2024, 7:14 PM
Sounds amazing!
Keep me posted
h

handsome-yak-41299

02/15/2024, 7:44 AM
Solved it! As the js-newb I am, I used "location" as a variable name - now discovering that it's a reserved word. 🙂 Still funny that it only fails outside the studio.
f

fresh-fireman-491

02/15/2024, 3:11 PM
Nice to hear that you have solved it and yes that is a bit weird