Skip to content

Please do not call socket.setdefaulttimeout() #187

Description

@cstenac

pyral sets the default timeout on all sockets to be 5 seconds:
https://github.com/RallyTools/RallyRestToolkitForPython/blob/master/pyral/context.py#L139

This causes side effects on all programs using pyral and doing other network IO and that will suddendly start seeing unexplainable timeout errors.

The library should only set the timeout on its own sockets, or at least revert the change after it is done

This can be worked around by calling this after using pyral and before doing other network IO (assuming that it is possible to have a before and after):

import socket
socket.setdefaulttimeout(None)

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