Page MenuHome

Fixing T56938 and T54222

Authored by A K (campino) on Sep 27 2018, 4:13 PM.




On my machine, this patch solves T56938 and T54222.

T56938 is a missing content-length header in a request between netrender client and master.

T54222 is the same for a request between slave and master.

Further details can be found there.

The fix introduces a new function, sendFile, which PUTs a file to a specified URL, and it uses the function in several places. That is, duplicates of the code I fixed are fixed as well (and removed).

I am not sure whether this is the best possible fix, after all, the python http.client library does have functionality to set this header automatically. It is just that this functionality is not enabled in our use case. If there is a way to enable it, this would be preferable.

Also, I only tested this on Linux Fedora 28, so other operating systems may show different behaviour.

Diff Detail

Event Timeline

A K (campino) created this revision.Sep 27 2018, 4:13 PM

Looks good to me, thanks for the patch!

This revision is now accepted and ready to land.Sep 27 2018, 4:26 PM
This revision was automatically updated to reflect the committed changes.