Skip to content

Configurations like timeout, proxy, and ssl_verify should be parameterised #885

Description

@nikunjcrest

Currently, in the Box SDK, configuring timeout, proxy, and SSL verify requires overriding the DefaultNetwork.request method.

class ProxyableBoxNetwork(DefaultNetwork):
    def __init__(self, proxy_conf, verify, logger=None):
        super(ProxyableBoxNetwork, self).__init__()

    def request(self, method, url, access_token, **kwargs):
        return super(ProxyableBoxNetwork, self).request(
            method, url, access_token,
            proxies=self._proxies,
            verify=self._verify,
            timeout=self._timeout,
            **kwargs
        )

Shouldn't these configurations be parameterised to allow straightforward setup without overriding?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions