cornell-cup / cs-minibot

[WIP] Software platform for MiniBot, an educational robotics kit made for Da Vinci Labs.
http://cornellcuprobotics.com/projects.html#minibot
Apache License 2.0
5 stars 1 forks source link

findScripts Bug #86

Open chynu opened 7 years ago

chynu commented 7 years ago

When switching to the "Coding/Control" tab, this error happens:

ERROR:tornado.application:Uncaught exception GET /findScripts (127.0.0.1)
HTTPServerRequest(protocol='http', host='localhost:8080', method='GET', uri='/findScripts', version='HTTP/1.1', remote_ip='127.0.0.1', headers={'Host': 'localhost:8080', 'Connection': 'keep-alive', 'Accept': 'application/json, text/plain, */*', 'User-Agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.94 Safari/537.36', 'Dnt': '1', 'Referer': 'http://localhost:8080/', 'Accept-Encoding': 'gzip, deflate, br', 'Accept-Language': 'en-US,en;q=0.9,ko;q=0.8'})
Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tornado/web.py", line 1509, in _execute
    result = method(*self.path_args, **self.path_kwargs)
  File "main.py", line 215, in get
    files = BaseStation().get_bot_manager().get_minibot_scripts()
  File "/Users/celinechoo/Code/cs-minibot/basestation/bot/bot_manager.py", line 118, in get_minibot_scripts
    files = [f for f in listdir(path) if isfile(join(path, f))]
FileNotFoundError: [Errno 2] No such file or directory: './minibot/scripts'
leotrj commented 6 years ago

It might be because I hard coded the path. I'll look into it.