Bug #2104
REST handlers don't run on Windows
Start date:
10/21/2017
Due date:
% Done:
100%
Associated revisions
Making lookup handler imports be more specific so that the imports don't get confused with the Core Splunk library rest_handler
Closes #2104
History
#1 Updated by Luke Murphey about 7 years ago
10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: Traceback (most recent call last): 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 114, in <module> 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: h.run() 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\packet.py", line 164, in run 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: self.handle_packet(in_packet) 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\handle_loop.py", line 36, in handle_packet 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: self._current_handler = self.load(in_packet.command, in_packet.command_arg, in_packet.allow_stream()) 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 22, in load 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: class_and_meths = self._get_class_and_methods(command[0], stream_allowed) 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 31, in _get_class_and_methods 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: meths = self._cached_load_file(filename) 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 42, in _cached_load_file 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: rv = PersistentServerConnectionApplicationServer._load_file(filename) 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 57, in _load_file 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: m = imp.load_module(munged_name, filehandle, filename, data) 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\etc\apps\lookup_editor\bin\lookup_backups_rest_handler.py", line 13, in <module> 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: import rest_handler 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\bin\rest_handler.py", line 58, in <module> 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: assert(len(sys.argv) > 1) 10-21-2017 12:40:47.135 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: AssertionError 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: Traceback (most recent call last): 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 114, in <module> 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: h.run() 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\packet.py", line 164, in run 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: self.handle_packet(in_packet) 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\handle_loop.py", line 36, in handle_packet 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: self._current_handler = self.load(in_packet.command, in_packet.command_arg, in_packet.allow_stream()) 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 22, in load 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: class_and_meths = self._get_class_and_methods(command[0], stream_allowed) 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 31, in _get_class_and_methods 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: meths = self._cached_load_file(filename) 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 42, in _cached_load_file 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: rv = PersistentServerConnectionApplicationServer._load_file(filename) 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 57, in _load_file 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: m = imp.load_module(munged_name, filehandle, filename, data) 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\etc\apps\lookup_editor\bin\lookup_editor_rest_handler.py", line 18, in <module> 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: import rest_handler 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: File "C:\Program Files\Splunk\bin\rest_handler.py", line 58, in <module> 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: assert(len(sys.argv) > 1) 10-21-2017 12:40:47.177 -0500 ERROR PersistentScript - From {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: AssertionError 10-21-2017 12:40:47.177 -0500 WARN PersistentScript - Process {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: exited with code 1 10-21-2017 12:40:47.243 -0500 WARN PersistentScript - Process {"C:\Program Files\Splunk\bin\python.EXE" "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py"}: exited with code 1
#2 Updated by Luke Murphey about 7 years ago
Traceback (most recent call last): File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 114, in <module> h.run() File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\packet.py", line 164, in run self.handle_packet(in_packet) File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\handle_loop.py", line 36, in handle_packet self._current_handler = self.load(in_packet.command, in_packet.command_arg, in_packet.allow_stream()) File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 22, in load class_and_meths = self._get_class_and_methods(command[0], stream_allowed) File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 31, in _get_class_and_methods meths = self._cached_load_file(filename) File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 42, in _cached_load_file rv = PersistentServerConnectionApplicationServer._load_file(filename) File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 57, in _load_file m = imp.load_module(munged_name, filehandle, filename, data) File "C:\Program Files\Splunk\etc\apps\lookup_editor\bin\lookup_backups_rest_handler.py", line 13, in <module> import rest_handler File "C:\Program Files\Splunk\bin\rest_handler.py", line 58, in <module> assert(len(sys.argv) > 1) AssertionError Traceback (most recent call last): File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 114, in <module> h.run() File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\packet.py", line 164, in run self.handle_packet(in_packet) File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\handle_loop.py", line 36, in handle_packet self._current_handler = self.load(in_packet.command, in_packet.command_arg, in_packet.allow_stream()) File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 22, in load class_and_meths = self._get_class_and_methods(command[0], stream_allowed) File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 31, in _get_class_and_methods meths = self._cached_load_file(filename) File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 42, in _cached_load_file rv = PersistentServerConnectionApplicationServer._load_file(filename) File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\persistconn\appserver.py", line 57, in _load_file m = imp.load_module(munged_name, filehandle, filename, data) File "C:\Program Files\Splunk\etc\apps\lookup_editor\bin\lookup_editor_rest_handler.py", line 18, in <module> import rest_handler File "C:\Program Files\Splunk\bin\rest_handler.py", line 58, in <module> assert(len(sys.argv) > 1) AssertionError
#3 Updated by Luke Murphey about 7 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100