python-nomad
python-nomad copied to clipboard
Wrap Nomad API use of character offset for task logs
For reading task logs (e.g., stdout/stderr), the Nomad API endpoint only supports passing an offset in characters instead of lines which makes implementation rather difficult. To ease implementation, the library should probably support returning a generator for iterating through each line in a particular log. The latter might also help enable using the follow
option which currently keeps the requests session open and prevents assignment of the output to a variable. Also, attempting to use the follow
option with a particularly large log leads to a traceback, likely due to a requests buffer filling up.
Any workaround for it?