diff --git a/python_sdk/pyproject.toml b/python_sdk/pyproject.toml index e347808f..2cfe801c 100644 --- a/python_sdk/pyproject.toml +++ b/python_sdk/pyproject.toml @@ -3,7 +3,7 @@ requires = ["hatchling"] build-backend = "hatchling.build" [project] name = "snail_sdk" -version = "0.7.5" +version = "0.11.2" authors = [ { name="Joel Einbinder", email="joel.einbinder@gmail.com" }, ] diff --git a/python_sdk/snail_sdk/__init__.py b/python_sdk/snail_sdk/__init__.py index 4f6f21de..948115e8 100644 --- a/python_sdk/snail_sdk/__init__.py +++ b/python_sdk/snail_sdk/__init__.py @@ -1,17 +1,17 @@ import json def display(filePath): - print('\x1b\x1aL' + str(filePath) + '\x00', end='') + print('\x1b\x1aL' + str(filePath) + '\x00', end='', flush=True) def set_progress(progress, left_text=None, right_text=None): print('\x1b\x1a\x4e' + json.dumps({ 'progress': progress, 'leftText': left_text, 'rightText': right_text - }) + '\x00', end='') + }) + '\x00', end='', flush=True) def chart(data): - print('\x1b\x1aC' + json.dumps(data) + '\x00', end='') + print('\x1b\x1aC' + json.dumps(data) + '\x00', end='', flush=True) def send(data, dont_cache=False): str = json.dumps(data) - print('\x1b\x1a' + ('Q' if dont_cache else 'M') + str + '\x00', end='') \ No newline at end of file + print('\x1b\x1a' + ('Q' if dont_cache else 'M') + str + '\x00', end='', flush=True) \ No newline at end of file