We're updating the issue view to help you get more done. 

pysparkling: h2o on exit does not shut down cleanly

Description

When we shutdown h2o as part of a pysparkling shell exit, all kinds of exceptions are logged to the console which can potentially cause the application to unnecessarily warn the user even though the application successfully completed.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 >>> exit() H2O session _sid_833c closed. /home/H2O/sparkling-water-2.1.16/py/build/dist/h2o_pysparkling_2.1-2.1.16.zip/pysparkling/context.py:151: UserWarning: Stopping H2OContext. (Restarting H2O is not yet fully supported...) Error in atexit._run_exitfuncs: Traceback (most recent call last): File "/opt/pythonz/pythons/CPython-2.7.5/lib/python2.7/atexit.py", line 24, in _run_exitfuncs func(*targs, **kargs) File "/home/H2O/sparkling-water-2.1.16/py/build/dist/h2o_pysparkling_2.1-2.1.16.zip/pysparkling/context.py", line 140, in <lambda> atexit.register(lambda: h2o_context.stop_with_jvm()) File "/home/H2O/sparkling-water-2.1.16/py/build/dist/h2o_pysparkling_2.1-2.1.16.zip/pysparkling/context.py", line 147, in stop_with_jvm self.stop() File "/home/H2O/sparkling-water-2.1.16/py/build/dist/h2o_pysparkling_2.1-2.1.16.zip/pysparkling/context.py", line 152, in stop Initializer.clean_temp_dir() File "/home/H2O/sparkling-water-2.1.16/py/build/dist/h2o_pysparkling_2.1-2.1.16.zip/pysparkling/initializer.py", line 81, in clean_temp_dir shutil.rmtree(Initializer.__extracted_jar_dir) File "/opt/pythonz/pythons/CPython-2.7.5/lib/python2.7/shutil.py", line 239, in rmtree onerror(os.listdir, path, sys.exc_info()) File "/opt/pythonz/pythons/CPython-2.7.5/lib/python2.7/shutil.py", line 237, in rmtree names = os.listdir(path) OSError: [Errno 2] No such file or directory: '/tmp/tmpWCvXCm' Error in sys.exitfunc:

Environment

None

Status

Assignee

Jakub Hava

Reporter

Nidhi Mehta

Labels

None

Release Priority

None

CustomerVisible

No

testcase 1

None

testcase 2

None

testcase 3

None

h2ostream link

None

Affected Spark version

None

AffectedContact

None

AffectedCustomers

None

AffectedPilots

None

AffectedOpenSource

None

Support Assessment

None

Customer Request Type

None

Support ticket URL

End date

None

Baseline start date

None

Baseline end date

None

Task progress

None

Task mode

None

Fix versions

Priority

Major