Skip to content

utarfile: invalid syntax for integer with base 8 #684

Closed
@AuHau

Description

@AuHau

I am using OTA library that I have tweaked to get my firmware from Github Release Assets, which are packed into Tar file (tar -czf source.tar.gz *) using Github Workflow.

The new firmware is downloaded to the flash correctly but when it is about to be extracted, it fails with error: invalid syntax for integer with base 8 coming from extracting the file's size in utarfile.

I have printed the byte arrays of the h.size and got: bytearray(b'00000002264 \x00').
Then I tried to repack the tar on my Mac and reuploaded that to the device and suddenly all works, but noticed that the printed byte array of size is: bytearray(b'00000002264 '). Eq. \x00 is missing.

In the Github Actions it is packed on Ubuntu machine. Maybe there should be some sanitation of the bytearray?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions