-
Notifications
You must be signed in to change notification settings - Fork 222
[Bug]: New logs API breaks backward compatibility withdstack logs #2909
Copy link
Copy link
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Steps to reproduce
- Use server from master and cli 0.19.18
- Start a run and try to read its logs with
dstack logs. You'll get an error because the old CLI tries to decode base64-encoded logs but the server returns logs in plaintext (after [Feature] Strip ANSI codes from run logs and store them as plain text instead of bytes #2876)
dstack logs selfish-owl-2
Traceback (most recent call last):
File "/Users/r4victor/Projects/dstack/venvt/bin/dstack", line 10, in <module>
sys.exit(main())
^^^^^^
File "/Users/r4victor/Projects/dstack/venvt/lib/python3.12/site-packages/dstack/_internal/cli/main.py", line 91, in main
args.func(args)
File "/Users/r4victor/Projects/dstack/venvt/lib/python3.12/site-packages/dstack/_internal/cli/commands/logs.py", line 46, in _command
for log in logs:
^^^^
File "/Users/r4victor/Projects/dstack/venvt/lib/python3.12/site-packages/dstack/api/_public/runs.py", line 227, in logs
yield base64.b64decode(log.message)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/Cellar/python@3.12/3.12.9/Frameworks/Python.framework/Versions/3.12/lib/python3.12/base64.py", line 88, in b64decode
return binascii.a2b_base64(s, strict_mode=validate)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
binascii.Error: Incorrect padding
Actual behaviour
No response
Expected behaviour
No response
dstack version
master
Server logs
Additional information
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working