Jatana / FastOlympicCoding

Tools for competitive programming for Sublime Text 3 & 4
399 stars 48 forks source link

Breaks when having runtime error. #8

Open shurongwang opened 5 years ago

shurongwang commented 5 years ago

the plug-in breaks down if there is error at runtime. Therefore I have to restart the editor again.

Jatana commented 5 years ago

This is the common error for Sublime Text 3 on the OS X platform. Plugin hosts child process crash cause plugin host crash. The standard run tool crashes too.

It has appeared in the latest builds. So, I think this problem will be fixed.

But, everything works fine and do not crashes with debugger(lldb). So, to install lldb you can install xcode, I recommend xcode 9.4.1 version. You can download it from here - https://developer.apple.com/download/more

And then just press ctrl+shift+b to launch a program with lldb.

shurongwang commented 5 years ago

Thanks, I tired. But it stucks at 'compiling', what to do next? image

Jatana commented 5 years ago

Press ctrl+~ and write here the log.

shurongwang commented 5 years ago
Traceback (most recent call last):
  File "/Users/shurongwang/Library/Application Support/Sublime Text 3/Packages/CppFastOlympicCoding/test_manager.py", line 300, in go
    self.insert_test()
  File "/Users/shurongwang/Library/Application Support/Sublime Text 3/Packages/CppFastOlympicCoding/test_manager.py", line 278, in insert_test
    self.process_manager.run()
  File "/Users/shurongwang/Library/Application Support/Sublime Text 3/Packages/CppFastOlympicCoding/debuggers/DebugodPy3Ejector.py", line 140, in run
    self.__listen()
  File "/Users/shurongwang/Library/Application Support/Sublime Text 3/Packages/CppFastOlympicCoding/debuggers/DebugodPy3Ejector.py", line 56, in __listen
    s = self.read()
  File "/Users/shurongwang/Library/Application Support/Sublime Text 3/Packages/CppFastOlympicCoding/debuggers/DebugodPy3Ejector.py", line 148, in read
    out = self.interact('_.get_output()')
  File "/Users/shurongwang/Library/Application Support/Sublime Text 3/Packages/CppFastOlympicCoding/debuggers/DebugodPy3Ejector.py", line 52, in interact
    proc_dbg.stdin.flush()
BrokenPipeError: [Errno 32] Broken pipe
Jatana commented 5 years ago

Make sure your xcode version is 9.4.1 and it is location is /Applications/Xcode.app/

shurongwang commented 5 years ago

Yes, I do have Xcode, but it's version is 10.0 image

Jatana commented 5 years ago

I have changed something. Update plugin, restart Sublime and try it again.

shurongwang commented 5 years ago
[FastOlympicCoding] session saved
Traceback (most recent call last):
  File "/Users/shurongwang/Library/Application Support/Sublime Text 3/Packages/CppFastOlympicCoding/test_manager.py", line 966, in compile
    cmp_data = process_manager.compile()
  File "/Users/shurongwang/Library/Application Support/Sublime Text 3/Packages/CppFastOlympicCoding/debuggers/DebugodPy3Ejector.py", line 136, in compile
    return eval(self.interact('_.compile()'))
  File "<string>", line 0

    ^
SyntaxError: unexpected EOF while parsing
shurongwang commented 5 years ago

great, it works. Thanks a lot.

FallenParadise commented 5 years ago

Hello, I installed your plugin via Package ControlI. I also installed Xcode and Python, but still have problem with 'compiling' and I have the console log as the last one. So, what can I do?