Robot-Will / Stino

A Sublime Text Plugin for Arduino
Other
1.58k stars 249 forks source link

New Stino Error after selecting Arduino Application Folder #199

Closed brianc118 closed 9 years ago

brianc118 commented 9 years ago

Hi,

I've successfully installed new Stino when using a completely untouched copy of Arduino (no additional libraries). However, I have a copy of Arduino with all the libraries I need. Upon selecting the application folder, no message comes out of the console informing me that the application folder was found. Instead, by pressing Ctrl + `, I open the console and find this error:

Traceback (most recent call last):
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\main.py", line 491, in <lambda>
    func, condition_func, is_user)), 5)
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\main.py", line 479, in select_dir
    func(window, dir_path)
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\main.py", line 392, in set_arduino_ide_path
    arduino_info.change_ide_path(dir_path)
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\pyarduino\arduino_info.py", line 105, in change_ide_path
    self.ide_dir = arduino_root.ArduinoIdeDir(path)
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\pyarduino\arduino_root.py", line 75, in __init__
    super(ArduinoIdeDir, self).__init__(path, 'ide')
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\pyarduino\arduino_root.py", line 30, in __init__
    self.load()
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\pyarduino\arduino_root.py", line 35, in load
    self.load_libraries()
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\pyarduino\arduino_root.py", line 55, in load_libraries
    self.library_set = arduino_library.LibrarySet(self.id, libraries_path)
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\pyarduino\arduino_library.py", line 33, in __init__
    self.load_libraries()
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\pyarduino\arduino_library.py", line 46, in load_libraries
    self.libraries = [Library(d.path) for d in sub_dirs]
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\pyarduino\arduino_library.py", line 46, in <listcomp>
    self.libraries = [Library(d.path) for d in sub_dirs]
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\pyarduino\arduino_library.py", line 66, in __init__
    self.load_keywords()
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\pyarduino\arduino_library.py", line 97, in load_keywords
    self.keywords_file = arduino_keyword.KeywordsFile(keywords_file_path)
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\pyarduino\arduino_keyword.py", line 39, in __init__
    self.load()
  File "D:\Brian\Portable Apps\Sublime Text\Data\Packages\Stino-new-stino\stino\pyarduino\arduino_keyword.py", line 57, in load
    keyword = Keyword(*word_list)
TypeError: __init__() takes 4 positional arguments but 6 were given

It seems to me that this may be an issue with loading the libraries in Arduino?

Thanks, Brian

brianc118 commented 9 years ago

I've found the issue. It was a keywords.txt file in the SmartGPU2 library. There seemed to be some sort of interpretation issue. It's not a big issue though, to I don't think it's that important. If you experience anything like this, just manually remove all the libraries and then locate which one is causing the problem, and remove the keywords files.