verify=False in url requests

looks good

I can't merge it seems

Hey @arnaudon
Are you sure this PR solves the issue? When running the tests I now get the following error:
――――――――――――――― test_neuromorpho_download ―――――――――――――――

self = <urllib3.connectionpool.HTTPSConnectionPool object at 0x7f278e2339d0>, method = 'GET', url = '/api/health', body = None
headers = {'User-Agent': 'python-requests/2.27.1', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'}, retries = Retry(total=0, connect=None, read=False, redirect=None, status=None)
redirect = False, assert_same_host = False, timeout = Timeout(connect=None, read=None, total=None), pool_timeout = None, release_conn = False, chunked = False, body_pos = None
response_kw = {'decode_content': False, 'preload_content': False}, parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/api/health', query=None, fragment=None), destination_scheme = None
conn = None, release_this_conn = True, http_tunnel_required = False, err = None, clean_exit = False

    def urlopen(
        self,
        method,
        url,
        body=None,
        headers=None,
        retries=None,
        redirect=True,
        assert_same_host=True,
        timeout=_Default,
        pool_timeout=None,
        release_conn=None,
        chunked=False,
        body_pos=None,
        **response_kw
    ):
        """
        Get a connection from the pool and perform an HTTP request. This is the
        lowest level call for making a request, so you'll need to specify all
        the raw details.

        .. note::

           More commonly, it's appropriate to use a convenience method provided
           by :class:`.RequestMethods`, such as :meth:`request`.

        .. note::

           `release_conn` will only behave as expected if
           `preload_content=False` because we want to make
           `preload_content=False` the default behaviour someday soon without
           breaking backwards compatibility.

        :param method:
            HTTP request method (such as GET, POST, PUT, etc.)

        :param url:
            The URL to perform the request on.

        :param body:
            Data to send in the request body, either :class:`str`, :class:`bytes`,
            an iterable of :class:`str`/:class:`bytes`, or a file-like object.

        :param headers:
            Dictionary of custom headers to send, such as User-Agent,
            If-None-Match, etc. If None, pool headers are used. If provided,
            these headers completely replace any pool-specific headers.

        :param retries:
            Configure the number of retries to allow before raising a
            :class:`~urllib3.exceptions.MaxRetryError` exception.

            Pass ``None`` to retry until you receive a response. Pass a
            :class:`~urllib3.util.retry.Retry` object for fine-grained control
            over different types of retries.
            Pass an integer number to retry connection errors that many times,
            but no other types of errors. Pass zero to never retry.

            If ``False``, then retries are disabled and any exception is raised
            immediately. Also, instead of raising a MaxRetryError on redirects,
            the redirect response will be returned.

        :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int.

        :param redirect:
            If True, automatically handle redirects (status codes 301, 302,
            303, 307, 308). Each redirect counts as a retry. Disabling retries
            will disable redirect, too.

        :param assert_same_host:
            If ``True``, will make sure that the host of the pool requests is
            consistent else will raise HostChangedError. When ``False``, you can
            use the pool on an HTTP proxy and request foreign hosts.

        :param timeout:
            If specified, overrides the default timeout for this one
            request. It may be a float (in seconds) or an instance of
            :class:`urllib3.util.Timeout`.

        :param pool_timeout:
            If set and the pool is set to block=True, then this method will
            block for ``pool_timeout`` seconds and raise EmptyPoolError if no
            connection is available within the time period.

        :param release_conn:
            If False, then the urlopen call will not release the connection
            back into the pool once a response is received (but will release if
            you read the entire contents of the response such as when
            `preload_content=True`). This is useful if you're not preloading
            the response's content immediately. You will need to call
            ``r.release_conn()`` on the response ``r`` to return the connection
            back into the pool. If None, it takes the value of
            ``response_kw.get('preload_content', True)``.

        :param chunked:
            If True, urllib3 will send the body using chunked transfer
            encoding. Otherwise, urllib3 will send the body using the standard
            content-length form. Defaults to False.

        :param int body_pos:
            Position to seek to in file-like body in the event of a retry or
            redirect. Typically this won't need to be set because urllib3 will
            auto-populate the value when needed.

        :param \\**response_kw:
            Additional parameters are passed to
            :meth:`urllib3.response.HTTPResponse.from_httplib`
        """

        parsed_url = parse_url(url)
        destination_scheme = parsed_url.scheme

        if headers is None:
            headers = self.headers

        if not isinstance(retries, Retry):
            retries = Retry.from_int(retries, redirect=redirect, default=self.retries)

        if release_conn is None:
            release_conn = response_kw.get("preload_content", True)

        # Check host
        if assert_same_host and not self.is_same_host(url):
            raise HostChangedError(self, url, retries)

        # Ensure that the URL we're connecting to is properly encoded
        if url.startswith("/"):
            url = six.ensure_str(_encode_target(url))
        else:
            url = six.ensure_str(parsed_url.url)

        conn = None

        # Track whether `conn` needs to be released before
        # returning/raising/recursing. Update this variable if necessary, and
        # leave `release_conn` constant throughout the function. That way, if
        # the function recurses, the original value of `release_conn` will be
        # passed down into the recursive call, and its value will be respected.
        #
        # See issue #651 [1] for details.
        #
        # [1] <https://github.com/urllib3/urllib3/issues/651>
        release_this_conn = release_conn

        http_tunnel_required = connection_requires_http_tunnel(
            self.proxy, self.proxy_config, destination_scheme
        )

        # Merge the proxy headers. Only done when not using HTTP CONNECT. We
        # have to copy the headers dict so we can safely change it without those
        # changes being reflected in anyone else's copy.
        if not http_tunnel_required:
            headers = headers.copy()
            headers.update(self.proxy_headers)

        # Must keep the exception bound to a separate variable or else Python 3
        # complains about UnboundLocalError.
        err = None

        # Keep track of whether we cleanly exited the except block. This
        # ensures we do proper cleanup in finally.
        clean_exit = False

        # Rewind body position, if needed.   This will probably "
                    "lead to SSL verification errors"
                ).format(RECENT_DATE),
                SystemTimeWarning,
            )

        # Wrap socket using verification with the root certs in
        # trusted_root_certs
        default_ssl_context = False
        if self.ssl_context is None:
            default_ssl_context = True
            self.ssl_context = create_urllib3_context(
                ssl_version=resolve_ssl_version(self.ssl_version),
                cert_reqs=resolve_cert_reqs(self.cert_reqs),
            )

        context = self.ssl_context
        context.verify_mode = resolve_cert_reqs(self.cert_reqs)

        # Try to load OS default certs if none are given.
         If none is provided, one will
            be created using :func:`create_urllib3_context`.
        :param ciphers:
            A string of ciphers we wish the client to support.
        :param ca_cert_dir:
            A directory containing CA certificates in multiple separate files, as
            supported by OpenSSL's -CApath flag or the capath argument to
            SSLContext.load_verify_locations().
        :param key_password:
            Optional password if the keyfile is encrypted.
        :param ca_cert_data:
            Optional string containing CA certificates in PEM format suitable for
            passing as the cadata parameter to SSLContext.load_verify_locations()
        :param tls_in_tls:
            Use SSLTransport to wrap the existing socket.
        """
        context = ssl_context
        if context is None:
            # Note: This branch of code and all the variables in it are no longer
            # used by urllib3 itself. We should consider deprecating and removing
            # this code.
            context = create_urllib3_context(ssl_version, cert_reqs, ciphers=ciphers)

        if ca_certs or ca_cert_dir or ca_cert_data:
            try:
                context.load_verify_locations(ca_certs, ca_cert_dir, ca_cert_data)
            except (IOError, OSError) as e:
                raise SSLError(e)

        elif ssl_context is None and hasattr(context, "load_default_certs"):
            # try to load OS default certs; works well on Windows (require Python3.4+)
            context.load_default_certs()

        # Attempt to detect if we get the goofy behavior of the
        # keyfile being encrypted and OpenSSL asking for the
        # passphrase via the terminal and instead error out.
        if keyfile and key_password is None and _is_key_file_encrypted(keyfile):
            raise SSLError("Client private key is encrypted, password is required")

        if certfile:
            if key_password is None:
                context.load_cert_chain(certfile, keyfile)
            else:
                context.load_cert_chain(certfile, keyfile, key_password)

        try:
            if hasattr(context, "set_alpn_protocols"):
                context.set_alpn_protocols(ALPN_PROTOCOLS)
        except NotImplementedError:  # Defensive: in CI, we always have set_alpn_protocols
            pass

        # If we detect server_hostname is an IP address then the SNI
        # extension should not be used according to RFC3546 Section 3.1
        use_sni_hostname = server_hostname and not is_ipaddress(server_hostname)
        # SecureTransport uses server_hostname in certificate verification.
        send_sni = (use_sni_hostname and HAS_SNI) or (
            IS_SECURETRANSPORT and server_hostname
        )
        # Do not warn the user if server_hostname is an invalid SNI hostname.
        if not HAS_SNI and use_sni_hostname:
            warnings.warn(
                "An HTTPS request has been made, but the SNI (Server Name "
                "Indication) extension to TLS is not available on this platform. "
                "This may cause the server to present an incorrect TLS "
                "certificate, which can cause validation failures. You can upgrade to "
                "a newer version of Python to solve this.  Returns Response object.

        :param request: The :class:`PreparedRequest <PreparedRequest>` being sent.
        :param stream: (optional) Whether to stream the request content.
        :param timeout: (optional) How long to wait for the server to send
            data before giving up, as a float, or a :ref:`(connect timeout,
            read timeout) <timeouts>` tuple.
        :type timeout: float or tuple or urllib3 Timeout object
        :param verify: (optional) Either a boolean, in which case it controls whether
            we verify the server's TLS certificate, or a string, in which case it
            must be a path to a CA bundle to use
        :param cert: (optional) Any user-provided SSL certificate to be trusted.
        :param proxies: (optional) The proxies dictionary to apply to the request.
        :rtype: requests.Response
        """

        try:
            conn = self.get_connection(request.url, proxies)
        except LocationValueError as e:
            raise InvalidURL(e, request=request)

        self.cert_verify(conn, request.url, verify, cert)
        url = self.request_url(request, proxies)
        self.add_headers(request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies)

        chunked = not (request.body is None or 'Content-Length' in request.headers)

        if isinstance(timeout, tuple):
            try:
                connect, read = timeout
                timeout = TimeoutSauce(connect=connect, read=read)
            except ValueError as e:
                # this may raise a string formatting error.
                err = ("Invalid timeout {}.  This is the
        lowest level call for making a request, so you'll need to specify all
        the raw details.

        .. note::

           More commonly, it's appropriate to use a convenience method provided
           by :class:`.RequestMethods`, such as :meth:`request`.

        .. note::

           `release_conn` will only behave as expected if
           `preload_content=False` because we want to make
           `preload_content=False` the default behaviour someday soon without
           breaking backwards compatibility.

        :param method:
            HTTP request method (such as GET, POST, PUT, etc.)

        :param url:
            The URL to perform the request on.

        :param body:
            Data to send in the request body, either :class:`str`, :class:`bytes`,
            an iterable of :class:`str`/:class:`bytes`, or a file-like object.

        :param headers:
            Dictionary of custom headers to send, such as User-Agent,
            If-None-Match, etc. If None, pool headers are used. If provided,
            these headers completely replace any pool-specific headers.

        :param retries:
            Configure the number of retries to allow before raising a
            :class:`~urllib3.exceptions.MaxRetryError` exception.

            Pass ``None`` to retry until you receive a response. Pass a
            :class:`~urllib3.util.retry.Retry` object for fine-grained control
            over different types of retries.
            Pass an integer number to retry connection errors that many times,
            but no other types of errors. Pass zero to never retry.

            If ``False``, then retries are disabled and any exception is raised
            immediately. Also, instead of raising a MaxRetryError on redirects,
            the redirect response will be returned.

        :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int.

        :param redirect:
            If True, automatically handle redirects (status codes 301, 302,
            303, 307, 308). Each redirect counts as a retry. Disabling retries
            will disable redirect, too.

        :param assert_same_host:
            If ``True``, will make sure that the host of the pool requests is
            consistent else will raise HostChangedError. When ``False``, you can
            use the pool on an HTTP proxy and request foreign hosts.

        :param timeout:
            If specified, overrides the default timeout for this one
            request. It may be a float (in seconds) or an instance of
            :class:`urllib3.util.Timeout`.

        :param pool_timeout:
            If set and the pool is set to block=True, then this method will
            block for ``pool_timeout`` seconds and raise EmptyPoolError if no
            connection is available within the time period.

        :param release_conn:
            If False, then the urlopen call will not release the connection
            back into the pool once a response is received (but will release if
            you read the entire contents of the response such as when
            `preload_content=True`). This is useful if you're not preloading
            the response's content immediately. You will need to call
            ``r.release_conn()`` on the response ``r`` to return the connection
            back into the pool. If None, it takes the value of
            ``response_kw.get('preload_content', True)``.

        :param chunked:
            If True, urllib3 will send the body using chunked transfer
            encoding. Otherwise, urllib3 will send the body using the standard
            content-length form. Defaults to False.

        :param int body_pos:
            Position to seek to in file-like body in the event of a retry or
            redirect. Typically this won't need to be set because urllib3 will
            auto-populate the value when needed.

        :param \\**response_kw:
            Additional parameters are passed to
            :meth:`urllib3.response.HTTPResponse.from_httplib`
        """

        parsed_url = parse_url(url)
        destination_scheme = parsed_url.scheme

        if headers is None:
            headers = self.headers

        if not isinstance(retries, Retry):
            retries = Retry.from_int(retries, redirect=redirect, default=self.retries)

        if release_conn is None:
            release_conn = response_kw.get("preload_content", True)

        # Check host
        if assert_same_host and not self.is_same_host(url):
            raise HostChangedError(self, url, retries)

        # Ensure that the URL we're connecting to is properly encoded
        if url.startswith("/"):
            url = six.ensure_str(_encode_target(url))
        else:
            url = six.ensure_str(parsed_url.url)

        conn = None

        # Track whether `conn` needs to be released before
        # returning/raising/recursing. Update this variable if necessary, and
        # leave `release_conn` constant throughout the function. That way, if
        # the function recurses, the original value of `release_conn` will be
        # passed down into the recursive call, and its value will be respected.
        #
        # See issue #651 [1] for details.
        #
        # [1] <https://github.com/urllib3/urllib3/issues/651>
        release_this_conn = release_conn

        http_tunnel_required = connection_requires_http_tunnel(
            self.proxy, self.proxy_config, destination_scheme
        )

        # Merge the proxy headers. Only done when not using HTTP CONNECT. We
        # have to copy the headers dict so we can safely change it without those
        # changes being reflected in anyone else's copy.
        if not http_tunnel_required:
            headers = headers.copy()
            headers.update(self.proxy_headers)

        # Must keep the exception bound to a separate variable or else Python 3
        # complains about UnboundLocalError.
        err = None

        # Keep track of whether we cleanly exited the except block. This
        # ensures we do proper cleanup in finally.
        clean_exit = False

        # Rewind body position, if needed. Record current position
        # for future rewinds in the event of a redirect/retry.
        body_pos = set_file_position(body, body_pos)

        try:
            # Request a connection from the queue.
            timeout_obj = self._get_timeout(timeout)
            conn = self._get_conn(timeout=pool_timeout)

            conn.timeout = timeout_obj.connect_timeout

            is_new_proxy_conn = self.proxy is not None and not getattr(
                conn, "sock", None
            )
            if is_new_proxy_conn and http_tunnel_required:
                self._prepare_proxy(conn)

            # Make the request on the httplib connection object.
            httplib_response = self._make_request(
                conn,
                method,
                url,
                timeout=timeout_obj,
                body=body,
                headers=headers,
                chunked=chunked,
            )

            # If we're going to release the connection in ``finally:``, then
            # the response doesn't need to know about the connection. Otherwise
            # it will also try to release it and we'll have a double-release
            # mess.
            response_conn = conn if not release_conn else None

            # Pass method to Response for length checking
            response_kw["request_method"] = method

            # Import httplib's response into our own wrapper object
            response = self.ResponseCls.from_httplib(
                httplib_response,
                pool=self,
                connection=response_conn,
                retries=retries,
                **response_kw
            )

            # Everything went great!
            clean_exit = True

        except EmptyPoolError:
            # Didn't get a connection from the pool, no need to clean up
            clean_exit = True
            release_this_conn = False
            raise

        except (
            TimeoutError,
            HTTPException,
            SocketError,
            ProtocolError,
            BaseSSLError,
            SSLError,
            CertificateError,
        ) as e:
            # Discard the connection for these exceptions. It will be
            # replaced during the next _get_conn() call.
            clean_exit = False

            def _is_ssl_error_message_from_http_proxy(ssl_error):
                # We're trying to detect the message 'WRONG_VERSION_NUMBER' but
                # SSLErrors are kinda all over the place when it comes to the message,
                # so we try to cover our bases here!
                message = " ".join(re.split("[^a-z]", str(ssl_error).lower()))
                return (
                    "wrong version number" in message or "unknown protocol" in message
                )

            # Try to detect a common user error with proxies which is to
            # set an HTTP proxy to be HTTPS when it should be 'http://'
            # (ie {'http': 'http://proxy', 'https': 'https://proxy'})
            # Instead we add a nice error message and point to a URL.
            if (
                isinstance(e, BaseSSLError)
                and self.proxy
                and _is_ssl_error_message_from_http_proxy(e)
            ):
                e = ProxyError(
                    "Your proxy appears to only use HTTP and not HTTPS, "
                    "try changing your proxy URL to be HTTP.
             Enable/disable GET/OPTIONS/POST/PUT/PATCH/DELETE/HEAD redirection. Defaults to ``True``.
        :type allow_redirects: bool
        :param proxies: (optional) Dictionary mapping protocol to the URL of the proxy.
        :param verify: (optional) Either a boolean, in which case it controls whether we verify
                the server's TLS certificate, or a string, in which case it must be a path
                to a CA bundle to use. Defaults to ``True``.
        :param stream: (optional) if ``False``, the response content will be immediately downloaded.
        :param cert: (optional) if String, path to ssl client cert file (.pem).
        Returns :class:`Response <Response>` object.

        :param method: method for the new :class:`Request` object.
        :param url: URL for the new :class:`Request` object.
        :param params: (optional) Dictionary or bytes to be sent in the query
            string for the :class:`Request`.
        :param data: (optional) Dictionary, list of tuples, bytes, or file-like
            object to send in the body of the :class:`Request`.
        :param json: (optional) json to send in the body of the
            :class:`Request`.
        :param headers: (optional) Dictionary of HTTP Headers to send with the
            :class:`Request`.
        :param cookies: (optional) Dict or CookieJar object to send with the
            :class:`Request`.
        :param files: (optional) Dictionary of ``'filename': file-like-objects``
            for multipart encoding upload.
        :param auth: (optional) Auth tuple or callable to enable
            Basic/Digest/Custom HTTP Auth.
        :param timeout: (optional) How long to wait for the server to send
            data before giving up, as a float, or a :ref:`(connect timeout,
            read timeout) <timeouts>` tuple.
        :type timeout: float or tuple
        :param allow_redirects: (optional) Set to True by default.
        :type allow_redirects: bool
        :param proxies: (optional) Dictionary mapping protocol or protocol and
            hostname to the URL of the proxy.
        :param stream: (optional) whether to immediately download the response
            content. Defaults to ``False``.
        :param verify: (optional) Either a boolean, in which case it controls whether we verify
            the server's TLS certificate, or a string, in which case it must be a path
            to a CA bundle to use. Defaults to ``True``. When set to
            ``False``, requests will accept any TLS certificate presented by
            the server, and will ignore hostname mismatches and/or expired
            certificates, which will make your application vulnerable to
            man-in-the-middle (MitM) attacks. Setting verify to ``False``
            may be useful during local development or testing.
        :param cert: (optional) if String, path to ssl client cert file (.pem).

        # Guard against that specific failure case.
        if isinstance(request, Request):
            raise ValueError('You can only send PreparedRequests.')

         Returns a generator of Responses or Requests."""

        hist = []  # keep track of history

        url = self.get_redirect_target(resp)
        previous_fragment = urlparse(req.url).fragment
        while url:
            prepared_request = req.copy()

            # Update history and keep track of redirects.
            # resp.history must ignore the original request in this loop
            hist.append(resp)
            resp.history = hist[1:]

            try:
                resp.content  # Consume socket so it can be released
            except (ChunkedEncodingError, ContentDecodingError, RuntimeError):
                resp.raw.read(decode_content=False)

            if len(resp.history) >= self.max_redirects:
                raise TooManyRedirects('Exceeded {} redirects.'.format(self.max_redirects), response=resp)

            # Release the connection back into the pool.
            resp.close()

            # Handle redirection without scheme (see: RFC 1808 Section 4)
            if url.startswith('//'):
                parsed_rurl = urlparse(resp.url)
                url = ':'.join([to_native_string(parsed_rurl.scheme), url])

            # Normalize url case and attach previous fragment if needed (RFC 7231 7.1.2)
            parsed = urlparse(url)
            if parsed.fragment == '' and previous_fragment:
                parsed = parsed._replace(fragment=previous_fragment)
            elif parsed.fragment:
                previous_fragment = parsed.fragment
            url = parsed.geturl()

            # Facilitate relative 'location' headers, as allowed by RFC 7231.
            # (e.g. '/path/to/resource' instead of 'http://domain.tld/path/to/resource')
            # Compliant with RFC3986, we percent encode the url.
            if not parsed.netloc:
                url = urljoin(resp.url, requote_uri(url))
            else:
                url = requote_uri(url)

            prepared_request.url = to_native_string(url)

            self.rebuild_method(prepared_request, resp)

            # https://github.com/psf/requests/issues/1084
            if resp.status_code not in (codes.temporary_redirect, codes.permanent_redirect):
                # https://github.com/psf/requests/issues/3490
                purged_headers = ('Content-Length', 'Content-Type', 'Transfer-Encoding')
                for header in purged_headers:
                    prepared_request.headers.pop(header, None)
                prepared_request.body = None

            headers = prepared_request.headers
            headers.pop('Cookie', None)

            # Extract any cookies sent on the response to the cookiejar
            # in the new request. Because we've mutated our copied prepared
            # request, use the old one that we haven't yet touched.
            extract_cookies_to_jar(prepared_request._cookies, req, resp.raw)
            merge_cookies(prepared_request._cookies, self.cookies)
            prepared_request.prepare_cookies(prepared_request._cookies)

            # Rebuild auth and proxy information.
            proxies = self.rebuild_proxies(prepared_request, proxies)
            self.rebuild_auth(prepared_request, resp)

            # A failed tell() sets `_body_position` to `object()`.
        # Guard against that specific failure case.
        if isinstance(request, Request):
            raise ValueError('You can only send PreparedRequests.')

         Returns Response object.

        :param request: The :class:`PreparedRequest <PreparedRequest>` being sent.
        :param stream: (optional) Whether to stream the request content.
        :param timeout: (optional) How long to wait for the server to send
            data before giving up, as a float, or a :ref:`(connect timeout,
            read timeout) <timeouts>` tuple.
        :type timeout: float or tuple or urllib3 Timeout object
        :param verify: (optional) Either a boolean, in which case it controls whether
            we verify the server's TLS certificate, or a string, in which case it
            must be a path to a CA bundle to use
        :param cert: (optional) Any user-provided SSL certificate to be trusted.
        :param proxies: (optional) The proxies dictionary to apply to the request.
        :rtype: requests.Response
        """

        try:
            conn = self.get_connection(request.url, proxies)
        except LocationValueError as e:
            raise InvalidURL(e, request=request)

        self.cert_verify(conn, request.url, verify, cert)
        url = self.request_url(request, proxies)
        self.add_headers(request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies)

        chunked = not (request.body is None or 'Content-Length' in request.headers)

        if isinstance(timeout, tuple):
            try:
                connect, read = timeout
                timeout = TimeoutSauce(connect=connect, read=read)
            except ValueError as e:
                # this may raise a string formatting error.
                err = ("Invalid timeout {}. Pass a (connect, read) "
                       "timeout tuple, or a single float to set "
                       "both timeouts to the same value".format(timeout))
                raise ValueError(err)
        elif isinstance(timeout, TimeoutSauce):
            pass
        else:
            timeout = TimeoutSauce(connect=timeout, read=timeout)

        try:
            if not chunked:
                resp = conn.urlopen(
                    method=request.method,
                    url=url,
                    body=request.body,
                    headers=request.headers,
                    redirect=False,
                    assert_same_host=False,
                    preload_content=False,
                    decode_content=False,
                    retries=self.max_retries,
                    timeout=timeout
                )

            # Send the request.
            else:
                if hasattr(conn, 'proxy_pool'):
                    conn = conn.proxy_pool

                low_conn = conn._get_conn(timeout=DEFAULT_POOL_TIMEOUT)

                try:
                    skip_host = 'Host' in request.headers
                    low_conn.putrequest(request.method,
                                        url,
                                        skip_accept_encoding=True,
                                        skip_host=skip_host)

                    for header, value in request.headers.items():
                        low_conn.putheader(header, value)

                    low_conn.endheaders()

                    for i in request.body:
                        low_conn.send(hex(len(i))[2:].encode('utf-8'))
                        low_conn.send(b'\r\n')
                        low_conn.send(i)
                        low_conn.send(b'\r\n')
                    low_conn.send(b'0\r\n\r\n')

                    # Receive the response from the server
                    try:
                        # For Python 2.7, use buffering of HTTP responses
                        r = low_conn.getresponse(buffering=True)
                    except TypeError:
                        # For compatibility with Python 3.3+
                        r = low_conn.getresponse()

                    resp = HTTPResponse.from_httplib(
                        r,
                        pool=conn,
                        connection=low_conn,
                        preload_content=False,
                        decode_content=False
                    )
                except:
                    # If we hit any problems here, clean up the connection.
                     This is the
        lowest level call for making a request, so you'll need to specify all
        the raw details.

        .. note::

           More commonly, it's appropriate to use a convenience method provided
           by :class:`.RequestMethods`, such as :meth:`request`.

        .. note::

           `release_conn` will only behave as expected if
           `preload_content=False` because we want to make
           `preload_content=False` the default behaviour someday soon without
           breaking backwards compatibility.

        :param method:
            HTTP request method (such as GET, POST, PUT, etc.)

        :param url:
            The URL to perform the request on.

        :param body:
            Data to send in the request body, either :class:`str`, :class:`bytes`,
            an iterable of :class:`str`/:class:`bytes`, or a file-like object.

        :param headers:
            Dictionary of custom headers to send, such as User-Agent,
            If-None-Match, etc. If None, pool headers are used. If provided,
            these headers completely replace any pool-specific headers.

        :param retries:
            Configure the number of retries to allow before raising a
            :class:`~urllib3.exceptions.MaxRetryError` exception.

            Pass ``None`` to retry until you receive a response. Pass a
            :class:`~urllib3.util.retry.Retry` object for fine-grained control
            over different types of retries.
            Pass an integer number to retry connection errors that many times,
            but no other types of errors. Pass zero to never retry.

            If ``False``, then retries are disabled and any exception is raised
            immediately. Also, instead of raising a MaxRetryError on redirects,
            the redirect response will be returned.

        :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int.

        :param redirect:
            If True, automatically handle redirects (status codes 301, 302,
            303, 307, 308). Each redirect counts as a retry. Disabling retries
            will disable redirect, too.

        :param assert_same_host:
            If ``True``, will make sure that the host of the pool requests is
            consistent else will raise HostChangedError. When ``False``, you can
            use the pool on an HTTP proxy and request foreign hosts.

        :param timeout:
            If specified, overrides the default timeout for this one
            request. It may be a float (in seconds) or an instance of
            :class:`urllib3.util.Timeout`.

        :param pool_timeout:
            If set and the pool is set to block=True, then this method will
            block for ``pool_timeout`` seconds and raise EmptyPoolError if no
            connection is available within the time period.

        :param release_conn:
            If False, then the urlopen call will not release the connection
            back into the pool once a response is received (but will release if
            you read the entire contents of the response such as when
            `preload_content=True`). This is useful if you're not preloading
            the response's content immediately. You will need to call
            ``r.release_conn()`` on the response ``r`` to return the connection
            back into the pool. If None, it takes the value of
            ``response_kw.get('preload_content', True)``.

        :param chunked:
            If True, urllib3 will send the body using chunked transfer
            encoding. Otherwise, urllib3 will send the body using the standard
            content-length form. Defaults to False.

        :param int body_pos:
            Position to seek to in file-like body in the event of a retry or
            redirect. Typically this won't need to be set because urllib3 will
            auto-populate the value when needed.

        :param \\**response_kw:
            Additional parameters are passed to
            :meth:`urllib3.response.HTTPResponse.from_httplib`
        """

        parsed_url = parse_url(url)
        destination_scheme = parsed_url.scheme

        if headers is None:
            headers = self.headers

        if not isinstance(retries, Retry):
            retries = Retry.from_int(retries, redirect=redirect, default=self.retries)

        if release_conn is None:
            release_conn = response_kw.get("preload_content", True)

        # Check host
        if assert_same_host and not self.is_same_host(url):
            raise HostChangedError(self, url, retries)

        # Ensure that the URL we're connecting to is properly encoded
        if url.startswith("/"):
            url = six.ensure_str(_encode_target(url))
        else:
            url = six.ensure_str(parsed_url.url)

        conn = None

        # Track whether `conn` needs to be released before
        # returning/raising/recursing. Update this variable if necessary, and
        # leave `release_conn` constant throughout the function. That way, if
        # the function recurses, the original value of `release_conn` will be
        # passed down into the recursive call, and its value will be respected.
        #
        # See issue #651 [1] for details.
        #
        # [1] <https://github.com/urllib3/urllib3/issues/651>
        release_this_conn = release_conn

        http_tunnel_required = connection_requires_http_tunnel(
            self.proxy, self.proxy_config, destination_scheme
        )

        # Merge the proxy headers. Only done when not using HTTP CONNECT. We
        # have to copy the headers dict so we can safely change it without those
        # changes being reflected in anyone else's copy.
        if not http_tunnel_required:
            headers = headers.copy()
            headers.update(self.proxy_headers)

        # Must keep the exception bound to a separate variable or else Python 3
        # complains about UnboundLocalError.
        err = None

        # Keep track of whether we cleanly exited the except block. This
        # ensures we do proper cleanup in finally.
        clean_exit = False

        # Rewind body position, if needed.   This will probably "
                    "lead to SSL verification errors"
                ).format(RECENT_DATE),
                SystemTimeWarning,
            )

        # Wrap socket using verification with the root certs in
        # trusted_root_certs
        default_ssl_context = False
        if self.ssl_context is None:
            default_ssl_context = True
            self.ssl_context = create_urllib3_context(
                ssl_version=resolve_ssl_version(self.ssl_version),
                cert_reqs=resolve_cert_reqs(self.cert_reqs),
            )

        context = self.ssl_context
        context.verify_mode = resolve_cert_reqs(self.cert_reqs)

        # Try to load OS default certs if none are given.
         If none is provided, one will
            be created using :func:`create_urllib3_context`.
        :param ciphers:
            A string of ciphers we wish the client to support.
        :param ca_cert_dir:
            A directory containing CA certificates in multiple separate files, as
            supported by OpenSSL's -CApath flag or the capath argument to
            SSLContext.load_verify_locations().
        :param key_password:
            Optional password if the keyfile is encrypted.
        :param ca_cert_data:
            Optional string containing CA certificates in PEM format suitable for
            passing as the cadata parameter to SSLContext.load_verify_locations()
        :param tls_in_tls:
            Use SSLTransport to wrap the existing socket.
        """
        context = ssl_context
        if context is None:
            # Note: This branch of code and all the variables in it are no longer
            # used by urllib3 itself. We should consider deprecating and removing
            # this code.
            context = create_urllib3_context(ssl_version, cert_reqs, ciphers=ciphers)

        if ca_certs or ca_cert_dir or ca_cert_data:
            try:
                context.load_verify_locations(ca_certs, ca_cert_dir, ca_cert_data)
            except (IOError, OSError) as e:
                raise SSLError(e)

        elif ssl_context is None and hasattr(context, "load_default_certs"):
            # try to load OS default certs; works well on Windows (require Python3.4+)
            context.load_default_certs()

        # Attempt to detect if we get the goofy behavior of the
        # keyfile being encrypted and OpenSSL asking for the
        # passphrase via the terminal and instead error out.
        if keyfile and key_password is None and _is_key_file_encrypted(keyfile):
            raise SSLError("Client private key is encrypted, password is required")

        if certfile:
            if key_password is None:
                context.load_cert_chain(certfile, keyfile)
            else:
                context.load_cert_chain(certfile, keyfile, key_password)

        try:
            if hasattr(context, "set_alpn_protocols"):
                context.set_alpn_protocols(ALPN_PROTOCOLS)
        except NotImplementedError:  # Defensive: in CI, we always have set_alpn_protocols
            pass

        # If we detect server_hostname is an IP address then the SNI
        # extension should not be used according to RFC3546 Section 3.1
        use_sni_hostname = server_hostname and not is_ipaddress(server_hostname)
        # SecureTransport uses server_hostname in certificate verification.
        send_sni = (use_sni_hostname and HAS_SNI) or (
            IS_SECURETRANSPORT and server_hostname
        )
        # Do not warn the user if server_hostname is an invalid SNI hostname.
        if not HAS_SNI and use_sni_hostname:
            warnings.warn(
                "An HTTPS request has been made, but the SNI (Server Name "
                "Indication) extension to TLS is not available on this platform. "
                "This may cause the server to present an incorrect TLS "
                "certificate, which can cause validation failures. You can upgrade to "
                "a newer version of Python to solve this.  Returns Response object.

        :param request: The :class:`PreparedRequest <PreparedRequest>` being sent.
        :param stream: (optional) Whether to stream the request content.
        :param timeout: (optional) How long to wait for the server to send
            data before giving up, as a float, or a :ref:`(connect timeout,
            read timeout) <timeouts>` tuple.
        :type timeout: float or tuple or urllib3 Timeout object
        :param verify: (optional) Either a boolean, in which case it controls whether
            we verify the server's TLS certificate, or a string, in which case it
            must be a path to a CA bundle to use
        :param cert: (optional) Any user-provided SSL certificate to be trusted.
        :param proxies: (optional) The proxies dictionary to apply to the request.
        :rtype: requests.Response
        """

        try:
            conn = self.get_connection(request.url, proxies)
        except LocationValueError as e:
            raise InvalidURL(e, request=request)

        self.cert_verify(conn, request.url, verify, cert)
        url = self.request_url(request, proxies)
        self.add_headers(request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies)

        chunked = not (request.body is None or 'Content-Length' in request.headers)

        if isinstance(timeout, tuple):
            try:
                connect, read = timeout
                timeout = TimeoutSauce(connect=connect, read=read)
            except ValueError as e:
                # this may raise a string formatting error.
                err = ("Invalid timeout {}.  This is the
        lowest level call for making a request, so you'll need to specify all
        the raw details.

        .. note::

           More commonly, it's appropriate to use a convenience method provided
           by :class:`.RequestMethods`, such as :meth:`request`.

        .. note::

           `release_conn` will only behave as expected if
           `preload_content=False` because we want to make
           `preload_content=False` the default behaviour someday soon without
           breaking backwards compatibility.

        :param method:
            HTTP request method (such as GET, POST, PUT, etc.)

        :param url:
            The URL to perform the request on.

        :param body:
            Data to send in the request body, either :class:`str`, :class:`bytes`,
            an iterable of :class:`str`/:class:`bytes`, or a file-like object.

        :param headers:
            Dictionary of custom headers to send, such as User-Agent,
            If-None-Match, etc. If None, pool headers are used. If provided,
            these headers completely replace any pool-specific headers.

        :param retries:
            Configure the number of retries to allow before raising a
            :class:`~urllib3.exceptions.MaxRetryError` exception.

            Pass ``None`` to retry until you receive a response. Pass a
            :class:`~urllib3.util.retry.Retry` object for fine-grained control
            over different types of retries.
            Pass an integer number to retry connection errors that many times,
            but no other types of errors. Pass zero to never retry.

            If ``False``, then retries are disabled and any exception is raised
            immediately. Also, instead of raising a MaxRetryError on redirects,
            the redirect response will be returned.

        :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int.

        :param redirect:
            If True, automatically handle redirects (status codes 301, 302,
            303, 307, 308). Each redirect counts as a retry. Disabling retries
            will disable redirect, too.

        :param assert_same_host:
            If ``True``, will make sure that the host of the pool requests is
            consistent else will raise HostChangedError. When ``False``, you can
            use the pool on an HTTP proxy and request foreign hosts.

        :param timeout:
            If specified, overrides the default timeout for this one
            request. It may be a float (in seconds) or an instance of
            :class:`urllib3.util.Timeout`.

        :param pool_timeout:
            If set and the pool is set to block=True, then this method will
            block for ``pool_timeout`` seconds and raise EmptyPoolError if no
            connection is available within the time period.

        :param release_conn:
            If False, then the urlopen call will not release the connection
            back into the pool once a response is received (but will release if
            you read the entire contents of the response such as when
            `preload_content=True`). This is useful if you're not preloading
            the response's content immediately. You will need to call
            ``r.release_conn()`` on the response ``r`` to return the connection
            back into the pool. If None, it takes the value of
            ``response_kw.get('preload_content', True)``.

        :param chunked:
            If True, urllib3 will send the body using chunked transfer
            encoding. Otherwise, urllib3 will send the body using the standard
            content-length form. Defaults to False.

        :param int body_pos:
            Position to seek to in file-like body in the event of a retry or
            redirect. Typically this won't need to be set because urllib3 will
            auto-populate the value when needed.

        :param \\**response_kw:
            Additional parameters are passed to
            :meth:`urllib3.response.HTTPResponse.from_httplib`
        """

        parsed_url = parse_url(url)
        destination_scheme = parsed_url.scheme

        if headers is None:
            headers = self.headers

        if not isinstance(retries, Retry):
            retries = Retry.from_int(retries, redirect=redirect, default=self.retries)

        if release_conn is None:
            release_conn = response_kw.get("preload_content", True)

        # Check host
        if assert_same_host and not self.is_same_host(url):
            raise HostChangedError(self, url, retries)

        # Ensure that the URL we're connecting to is properly encoded
        if url.startswith("/"):
            url = six.ensure_str(_encode_target(url))
        else:
            url = six.ensure_str(parsed_url.url)

        conn = None

        # Track whether `conn` needs to be released before
        # returning/raising/recursing. Update this variable if necessary, and
        # leave `release_conn` constant throughout the function. That way, if
        # the function recurses, the original value of `release_conn` will be
        # passed down into the recursive call, and its value will be respected.
        #
        # See issue #651 [1] for details.
        #
        # [1] <https://github.com/urllib3/urllib3/issues/651>
        release_this_conn = release_conn

        http_tunnel_required = connection_requires_http_tunnel(
            self.proxy, self.proxy_config, destination_scheme
        )

        # Merge the proxy headers. Only done when not using HTTP CONNECT. We
        # have to copy the headers dict so we can safely change it without those
        # changes being reflected in anyone else's copy.
        if not http_tunnel_required:
            headers = headers.copy()
            headers.update(self.proxy_headers)

        # Must keep the exception bound to a separate variable or else Python 3
        # complains about UnboundLocalError.
        err = None

        # Keep track of whether we cleanly exited the except block. This
        # ensures we do proper cleanup in finally.
        clean_exit = False

        # Rewind body position, if needed. Record current position
        # for future rewinds in the event of a redirect/retry.
        body_pos = set_file_position(body, body_pos)

        try:
            # Request a connection from the queue.
            timeout_obj = self._get_timeout(timeout)
            conn = self._get_conn(timeout=pool_timeout)

            conn.timeout = timeout_obj.connect_timeout

            is_new_proxy_conn = self.proxy is not None and not getattr(
                conn, "sock", None
            )
            if is_new_proxy_conn and http_tunnel_required:
                self._prepare_proxy(conn)

            # Make the request on the httplib connection object.
            httplib_response = self._make_request(
                conn,
                method,
                url,
                timeout=timeout_obj,
                body=body,
                headers=headers,
                chunked=chunked,
            )

            # If we're going to release the connection in ``finally:``, then
            # the response doesn't need to know about the connection. Otherwise
            # it will also try to release it and we'll have a double-release
            # mess.
            response_conn = conn if not release_conn else None

            # Pass method to Response for length checking
            response_kw["request_method"] = method

            # Import httplib's response into our own wrapper object
            response = self.ResponseCls.from_httplib(
                httplib_response,
                pool=self,
                connection=response_conn,
                retries=retries,
                **response_kw
            )

            # Everything went great!
            clean_exit = True

        except EmptyPoolError:
            # Didn't get a connection from the pool, no need to clean up
            clean_exit = True
            release_this_conn = False
            raise

        except (
            TimeoutError,
            HTTPException,
            SocketError,
            ProtocolError,
            BaseSSLError,
            SSLError,
            CertificateError,
        ) as e:
            # Discard the connection for these exceptions. It will be
            # replaced during the next _get_conn() call.
            clean_exit = False

            def _is_ssl_error_message_from_http_proxy(ssl_error):
                # We're trying to detect the message 'WRONG_VERSION_NUMBER' but
                # SSLErrors are kinda all over the place when it comes to the message,
                # so we try to cover our bases here!
                message = " ".join(re.split("[^a-z]", str(ssl_error).lower()))
                return (
                    "wrong version number" in message or "unknown protocol" in message
                )

            # Try to detect a common user error with proxies which is to
            # set an HTTP proxy to be HTTPS when it should be 'http://'
            # (ie {'http': 'http://proxy', 'https': 'https://proxy'})
            # Instead we add a nice error message and point to a URL.
            if (
                isinstance(e, BaseSSLError)
                and self.proxy
                and _is_ssl_error_message_from_http_proxy(e)
            ):
                e = ProxyError(
                    "Your proxy appears to only use HTTP and not HTTPS, "
                    "try changing your proxy URL to be HTTP.
             Enable/disable GET/OPTIONS/POST/PUT/PATCH/DELETE/HEAD redirection. Defaults to ``True``.
        :type allow_redirects: bool
        :param proxies: (optional) Dictionary mapping protocol to the URL of the proxy.
        :param verify: (optional) Either a boolean, in which case it controls whether we verify
                the server's TLS certificate, or a string, in which case it must be a path
                to a CA bundle to use. Defaults to ``True``.
        :param stream: (optional) if ``False``, the response content will be immediately downloaded.
        :param cert: (optional) if String, path to ssl client cert file (.pem).
        Returns :class:`Response <Response>` object.

        :param method: method for the new :class:`Request` object.
        :param url: URL for the new :class:`Request` object.
        :param params: (optional) Dictionary or bytes to be sent in the query
            string for the :class:`Request`.
        :param data: (optional) Dictionary, list of tuples, bytes, or file-like
            object to send in the body of the :class:`Request`.
        :param json: (optional) json to send in the body of the
            :class:`Request`.
        :param headers: (optional) Dictionary of HTTP Headers to send with the
            :class:`Request`.
        :param cookies: (optional) Dict or CookieJar object to send with the
            :class:`Request`.
        :param files: (optional) Dictionary of ``'filename': file-like-objects``
            for multipart encoding upload.
        :param auth: (optional) Auth tuple or callable to enable
            Basic/Digest/Custom HTTP Auth.
        :param timeout: (optional) How long to wait for the server to send
            data before giving up, as a float, or a :ref:`(connect timeout,
            read timeout) <timeouts>` tuple.
        :type timeout: float or tuple
        :param allow_redirects: (optional) Set to True by default.
        :type allow_redirects: bool
        :param proxies: (optional) Dictionary mapping protocol or protocol and
            hostname to the URL of the proxy.
        :param stream: (optional) whether to immediately download the response
            content. Defaults to ``False``.
        :param verify: (optional) Either a boolean, in which case it controls whether we verify
            the server's TLS certificate, or a string, in which case it must be a path
            to a CA bundle to use. Defaults to ``True``. When set to
            ``False``, requests will accept any TLS certificate presented by
            the server, and will ignore hostname mismatches and/or expired
            certificates, which will make your application vulnerable to
            man-in-the-middle (MitM) attacks. Setting verify to ``False``
            may be useful during local development or testing.
        :param cert: (optional) if String, path to ssl client cert file (.pem).

        # Guard against that specific failure case.
        if isinstance(request, Request):
            raise ValueError('You can only send PreparedRequests.')

         Returns a generator of Responses or Requests."""

        hist = []  # keep track of history

        url = self.get_redirect_target(resp)
        previous_fragment = urlparse(req.url).fragment
        while url:
            prepared_request = req.copy()

            # Update history and keep track of redirects.
            # resp.history must ignore the original request in this loop
            hist.append(resp)
            resp.history = hist[1:]

            try:
                resp.content  # Consume socket so it can be released
            except (ChunkedEncodingError, ContentDecodingError, RuntimeError):
                resp.raw.read(decode_content=False)

            if len(resp.history) >= self.max_redirects:
                raise TooManyRedirects('Exceeded {} redirects.'.format(self.max_redirects), response=resp)

            # Release the connection back into the pool.
            resp.close()

            # Handle redirection without scheme (see: RFC 1808 Section 4)
            if url.startswith('//'):
                parsed_rurl = urlparse(resp.url)
                url = ':'.join([to_native_string(parsed_rurl.scheme), url])

            # Normalize url case and attach previous fragment if needed (RFC 7231 7.1.2)
            parsed = urlparse(url)
            if parsed.fragment == '' and previous_fragment:
                parsed = parsed._replace(fragment=previous_fragment)
            elif parsed.fragment:
                previous_fragment = parsed.fragment
            url = parsed.geturl()

            # Facilitate relative 'location' headers, as allowed by RFC 7231.
            # (e.g. '/path/to/resource' instead of 'http://domain.tld/path/to/resource')
            # Compliant with RFC3986, we percent encode the url.
            if not parsed.netloc:
                url = urljoin(resp.url, requote_uri(url))
            else:
                url = requote_uri(url)

            prepared_request.url = to_native_string(url)

            self.rebuild_method(prepared_request, resp)

            # https://github.com/psf/requests/issues/1084
            if resp.status_code not in (codes.temporary_redirect, codes.permanent_redirect):
                # https://github.com/psf/requests/issues/3490
                purged_headers = ('Content-Length', 'Content-Type', 'Transfer-Encoding')
                for header in purged_headers:
                    prepared_request.headers.pop(header, None)
                prepared_request.body = None

            headers = prepared_request.headers
            headers.pop('Cookie', None)

            # Extract any cookies sent on the response to the cookiejar
            # in the new request. Because we've mutated our copied prepared
            # request, use the old one that we haven't yet touched.
            extract_cookies_to_jar(prepared_request._cookies, req, resp.raw)
            merge_cookies(prepared_request._cookies, self.cookies)
            prepared_request.prepare_cookies(prepared_request._cookies)

            # Rebuild auth and proxy information.
            proxies = self.rebuild_proxies(prepared_request, proxies)
            self.rebuild_auth(prepared_request, resp)

            # A failed tell() sets `_body_position` to `object()`.
        # Guard against that specific failure case.
        if isinstance(request, Request):
            raise ValueError('You can only send PreparedRequests.')

         Returns Response object.

        :param request: The :class:`PreparedRequest <PreparedRequest>` being sent.
        :param stream: (optional) Whether to stream the request content.
        :param timeout: (optional) How long to wait for the server to send
            data before giving up, as a float, or a :ref:`(connect timeout,
            read timeout) <timeouts>` tuple.
        :type timeout: float or tuple or urllib3 Timeout object
        :param verify: (optional) Either a boolean, in which case it controls whether
            we verify the server's TLS certificate, or a string, in which case it
            must be a path to a CA bundle to use
        :param cert: (optional) Any user-provided SSL certificate to be trusted.
        :param proxies: (optional) The proxies dictionary to apply to the request.
        :rtype: requests.Response
        """

        try:
            conn = self.get_connection(request.url, proxies)
        except LocationValueError as e:
            raise InvalidURL(e, request=request)

        self.cert_verify(conn, request.url, verify, cert)
        url = self.request_url(request, proxies)
        self.add_headers(request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies)

        chunked = not (request.body is None or 'Content-Length' in request.headers)

        if isinstance(timeout, tuple):
            try:
                connect, read = timeout
                timeout = TimeoutSauce(connect=connect, read=read)
            except ValueError as e:
                # this may raise a string formatting error.
                err = ("Invalid timeout {}. Pass a (connect, read) "
                       "timeout tuple, or a single float to set "
                       "both timeouts to the same value".format(timeout))
                raise ValueError(err)
        elif isinstance(timeout, TimeoutSauce):
            pass
        else:
            timeout = TimeoutSauce(connect=timeout, read=timeout)

        try:
            if not chunked:
                resp = conn.urlopen(
                    method=request.method,
                    url=url,
                    body=request.body,
                    headers=request.headers,
                    redirect=False,
                    assert_same_host=False,
                    preload_content=False,
                    decode_content=False,
                    retries=self.max_retries,
                    timeout=timeout
                )

            # Send the request.
            else:
                if hasattr(conn, 'proxy_pool'):
                    conn = conn.proxy_pool

                low_conn = conn._get_conn(timeout=DEFAULT_POOL_TIMEOUT)

                try:
                    skip_host = 'Host' in request.headers
                    low_conn.putrequest(request.method,
                                        url,
                                        skip_accept_encoding=True,
                                        skip_host=skip_host)

                    for header, value in request.headers.items():
                        low_conn.putheader(header, value)

                    low_conn.endheaders()

                    for i in request.body:
                        low_conn.send(hex(len(i))[2:].encode('utf-8'))
                        low_conn.send(b'\r\n')
                        low_conn.send(i)
                        low_conn.send(b'\r\n')
                    low_conn.send(b'0\r\n\r\n')

                    # Receive the response from the server
                    try:
                        # For Python 2.7, use buffering of HTTP responses
                        r = low_conn.getresponse(buffering=True)
                    except TypeError:
                        # For compatibility with Python 3.3+
                        r = low_conn.getresponse()

                    resp = HTTPResponse.from_httplib(
                        r,
                        pool=conn,
                        connection=low_conn,
                        preload_content=False,
                        decode_content=False
                    )
                except:
                    # If we hit any problems here, clean up the connection.


How to get current page of created slide or how create table of content?

Category

[ ] Enhancement
[ ] Bug
[x] Question
[x] Documentation gap/issue

Version
Please specify what version of the library you are using: [3.9.0]
Please specify what version(s) of PowerPoint you are targeting: [not_related]
Expected / Desired Behavior / Question
How to build a slider with table of content?
On version 3.1.1 I was using .number but after bumping to 3.9.0 I have a problem.
Somehow I need to get page number from created slide.
Is there any other good solution (API?) to create table of content?
Observed Behavior
Long time ago there was a function getPageNumber() (https://github.com/gitbrent/PptxGenJS/issues/353)
Version 3.1.1 returned a number  const slide = pptx.addSlide('Page number'); return slide.number;.
On version 3.3.0 .number was changed/renamed.
Apparently on 3.9.0 there is an attribute slide._slideNum but using TS there is no clean approach to get it. TS documentation suggest .slideNumber but it's not supported by the code.
Steps to Reproduce
V 3.2.1 https://codesandbox.io/s/pptxgenjs-page-number-3-2-1-hqew7?file=/src/App.js
V 3.9.0 https://codesandbox.io/s/pptxgenjs-page-number-3-9-0-2n9js?file=/src/App.js

The ability to retrieve the slide number was removed as it did not seem useful. It also conflicted with the newer property for the Slide Number prop (SlideNumberProps) used to set slide number on the slide.
As the developer, you can track how many slides have been returned.

If anyone else needs to know the slide number after adding tables with autoPage: true, you can access it with slide._slideNum. The only downside is that you'll need to add another slide after the table to access it. See: https://github.com/gitbrent/PptxGenJS/discussions/1149#discussioncomment-3416290


feat/priority: implement message prioritization

All messages to be sent out now need to specify priority. Crust will do it best to ensure the higher priority (0 being the highest) messages are sent before any lower priority ones even if lower priority were the ones to come into the queue first. Priority ranges between 0 (highest) and 255 (lowest).

This change is

r? @canndrew
(maidsafe_highfive has picked a reviewer for you, use r? to override)

r? @afck

Review status: 0 of 10 files reviewed at latest revision, 2 unresolved discussions.

src/socket.rs, line 150 [r1] (raw file):

            try!(data.write_u32::<LittleEndian>(len as u32));

            let entry = self.write_queue.entry(priority).or_insert(VecDeque::with_capacity(10));

This will create a VecDeque whether the entry exists or not. It's better to use or_insert_with and VecDeque::new or || VecDeque::with_capacity(10).

src/core/state.rs, line 24 [r1] (raw file):

use mio::{EventLoop, EventSet, Handler, Token};

/// Priority of a message to be sent by Crust. Priority 0 being the highest and very unlikely to be

It will probably make sense to actually never drop priority 0 (that's what we currently do in master).

Comments from Reviewable

src/socket.rs, line 150 [r1] (raw file):

This will create a VecDeque whether the entry exists or not
But that is what i want - if the entry does not exist create a default one so that i can do a push back in the next line below. Sorry i didn't get this point could you explain more ?

Comments from Reviewable

src/socket.rs, line 150 [r1] (raw file):

This will create a VecDeque whether the entry exists or not

But that is what i want - if the entry does not exist create a default one so that i can do a push back in the next line below. Sorry i didn't get this point could you explain more ?

Comments from Reviewable

Review status: 0 of 10 files reviewed at latest revision, 2 unresolved discussions.

src/socket.rs, line 150 [r1] (raw file):
Previously, ustulation (Spandan Sharma) wrote…
> > This will create a VecDeque whether the entry exists or not
>
> But that is what i want - if the entry does not exist create a default one so that i can do a push back in the next line below. Sorry i didn't get this point could you explain more ?
>

If the entry doesn't exist it's fine. But if it _does_ exist, this will allocate a new `VecDeque` anyway and pass it ot the `or_insert` method, just to have it dropped there again.
`or_insert_with(VecDeque::new)` would only call the `VecDeque::new` constructor if it actually needs it, i. e. if the entry actually doesn't exist, avoiding the unnecessary allocation.

Comments from Reviewable

src/socket.rs, line 150 [r1] (raw file):
Previously, afck (Andreas Fackler) wrote…
> If the entry doesn't exist it's fine. But if it _does_ exist, this will allocate a new `VecDeque` anyway and pass it ot the `or_insert` method, just to have it dropped there again.
> `or_insert_with(VecDeque::new)` would only call the `VecDeque::new` constructor if it actually needs it, i. e. if the entry actually doesn't exist, avoiding the unnecessary allocation.

I dont think that is how it works (either that or my head isnt't functioning correctly)
https://doc.rust-lang.org/nightly/std/collections/btree_map/enum.Entry.html#method.or_insert
So from that - if the entry does not exist it will use the default, if it does then it will return the existing. That is what _default_ means i hope in that function parameter

Comments from Reviewable

Review status: 0 of 10 files reviewed at latest revision, 2 unresolved discussions.

src/socket.rs, line 150 [r1] (raw file):
Previously, ustulation (Spandan Sharma) wrote…
> I dont think that is how it works (either that or my head isnt't functioning correctly)
> https://doc.rust-lang.org/nightly/std/collections/btree_map/enum.Entry.html#method.or_insert
> So from that - if the entry does not exist it will use the default, if it does then it will return the existing. That is what _default_ means i hope in that function parameter

That's what the `or_insert` method does, yes. However, it is _called_ in either case, and as an argument it takes the newly (and often unnecessarily) allocated `VecDeque`. It then either inserts it or drops it, which is a waste.
The `or_insert_with` method takes an `FnOnce` instead and only calls that if the entry is empty. If that `FnOnce` is where the new `VecDeque` is being allocated, the allocation actually is avoided if the entry is empty.

Comments from Reviewable

Review status: 0 of 10 files reviewed at latest revision, 2 unresolved discussions.

src/socket.rs, line 150 [r1] (raw file):
Previously, afck (Andreas Fackler) wrote…
> That's what the `or_insert` method does, yes. However, it is _called_ in either case, and as an argument it takes the newly (and often unnecessarily) allocated `VecDeque`. It then either inserts it or drops it, which is a waste.
> The `or_insert_with` method takes an `FnOnce` instead and only calls that if the entry is empty. If that `FnOnce` is where the new `VecDeque` is being allocated, the allocation actually is avoided if the entry is empty.

Ah right i see what you mean - i've used a lamda instead now

src/core/state.rs, line 24 [r1] (raw file):
Previously, afck (Andreas Fackler) wrote…
> It will probably make sense to actually _never_ drop priority 0 (that's what we currently do in master).

done

Comments from Reviewable

Reviewed 8 of 10 files at r1, 2 of 2 files at r2.
Review status: all files reviewed at latest revision, all discussions resolved.

Comments from Reviewable


Fix data type for openldap::server::overlay::options

I changed my mind regarding the way to test this.  Integration tests are barely impossible in a portable way, tests with rspec-puppet do not make sense so rely on the most basic unit tests to check the behavior of the code (without involving Puppet type checking unfortunately).

@ghoneycutt I further simplified the data types and added tests as requested :+1:.  I think the discussions are resolved, but I let you close them in case I missed some point.

I believe all the raised issues where fixed, and I will merge this.  Thanks!


Remove Apifox.Apifox 2.3.25 to Ruihu.Apifox 2.3.25

[x] Have you signed the Contributor License Agreement?
[x] Have you checked that there aren't other open pull requests for the same manifest update/change?
[x] This PR only modifies one (1) manifest
[ ] Have you validated your manifest locally with winget validate --manifest <path>?
[ ] Have you tested your manifest locally with winget install --manifest <path>?
[ ] Does your manifest conform to the 1.6 schema?

Note: <path> is the name of the directory containing the manifest you're submitting.

Microsoft Reviewers: Open in CodeFlow

URL: http://cdn.apifox.cn/download/2.3.25/Apifox-2.3.25.exe
Status Code: 200
(Automated message - build 869)


add count command

It's nice to see that you created a new variable/method dedicated for counting itself so that people who read the code would understand the purpose of the variable.
Some people might be confused if the coder just extrapolated number of people from the 'list' command instead of having a segregated variable/method.

This PR/issue should be against a repo in the org of your module e.g.,  nus-cs2103-AY1819S1 or nusCS2113-AY1819S1, not against the repo in se-edu org :-)
Closing...


How to use SDCard in SPI mode & spi_master at the same time on the M5Stack(esp32 core)?

It looks like spi_master and sd card in spi mode (sdpi_host) cannot be used at the same time.
I've tested combining the "iot_lcd.cpp" from  and sd card example and I cannot get both working.
/GPIO/
My LCD GPIO:
RST-GPIO23 DC-GPIO27 MOSI-GPIO23 SCK-GPIO18 CS-GPIO14
My SD SPI GPIO:
CS-GPIO4 MOSI-GPIO23 SDDO-GPIO19 CLK-GPIO18
/****Test configuration:/
SDcard and display use the different pins for spi interface.
Display uses HSPI_HOST and DMA channel 1.
SDCard uses VSPI_HOST an DMA channel 2.
Depending on which one is accessed first, either sdcard or display does not work.
When the sdcard is mounted first, sd card is detected, card info is correct, file can be opened, read, written...
Then the display is initialized.
After that, trying to open the file fails with:
E (2800) sdspi_host: sdspi_host_start_command: cmd=24 error=0x107
D (2800) sdmmc_cmd: sdmmc_req_run returned 0x107
E (2800) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x107
E (2810) diskio_sdmmc: sdmmc_write_blocks failed (263)
Display work with no problem.
When the display is intialized first, after the initialization the first display test works as expected, display is initialized and the pattern drawn.
Then the sdcard is mounted and works as expected, card info is correct, file can be opened, read, written...
After the sdcard intialization the display no longer works.
/My Code*****/
static CEspLcd* lcd_obj = NULL;
static const char *TAG = "sdcard";
#define PIN_NUM_MISO 19
#define PIN_NUM_MOSI 23
#define PIN_NUM_CLK  18
#define PIN_NUM_CS   4
#define SDSPI_HOST_M5STACK() {
.flags = SDMMC_HOST_FLAG_SPI,
.slot = VSPI_HOST,
.max_freq_khz = SDMMC_FREQ_DEFAULT,
.io_voltage = 3.3f,
.init = &sdspi_host_init,
.set_bus_width = NULL,
.get_bus_width = NULL,
.set_card_clk = &sdspi_host_set_card_clk,
.do_transaction = &sdspi_host_do_transaction,
.deinit = &sdspi_host_deinit,
.io_int_enable = NULL,
.io_int_wait = NULL,
.command_timeout_ms = 0,
}
#define SDSPI_SLOT_CONFIG_M5STACK() {
.gpio_miso = PIN_NUM_MISO,
.gpio_mosi = PIN_NUM_MOSI,
.gpio_sck  = PIN_NUM_CLK,
.gpio_cs   = PIN_NUM_CS,
.gpio_cd   = SDSPI_SLOT_NO_CD,
.gpio_wp   = SDSPI_SLOT_NO_WP,
.dma_channel = 2
}
void sdcard_main(void)
{
ESP_LOGI(TAG, "Initializing SD card");
ESP_LOGI(TAG, "Using SPI peripheral");

sdmmc_host_t host = SDSPI_HOST_M5STACK();
sdspi_slot_config_t slot_config = SDSPI_SLOT_CONFIG_M5STACK();
slot_config.gpio_miso = PIN_NUM_MISO;
slot_config.gpio_mosi = PIN_NUM_MOSI;
slot_config.gpio_sck  = PIN_NUM_CLK;
slot_config.gpio_cs   = PIN_NUM_CS;
// This initializes the slot without card detect (CD) and write protect (WP) signals.
// Modify slot_config.gpio_cd and slot_config.gpio_wp if your board has these signals.

// Options for mounting the filesystem.
// If format_if_mount_failed is set to true, SD card will be partitioned and
// formatted in case when mounting fails.
esp_vfs_fat_sdmmc_mount_config_t mount_config = {
    .format_if_mount_failed = false,
    .max_files = 5,
    .allocation_unit_size = 16 * 1024
};

// Use settings defined above to initialize SD card and mount FAT filesystem.
// Note: esp_vfs_fat_sdmmc_mount is an all-in-one convenience function.
// Please check its source code and implement error recovery when developing
// production applications.
sdmmc_card_t* card;
esp_err_t ret = esp_vfs_fat_sdmmc_mount("/sdcard", &host, &slot_config, &mount_config, &card);

if (ret != ESP_OK) {
    if (ret == ESP_FAIL) {
        ESP_LOGE(TAG, "Failed to mount filesystem. "
            "If you want the card to be formatted, set format_if_mount_failed = true.");
    } else {
        ESP_LOGE(TAG, "Failed to initialize the card (%s). "
            "Make sure SD card lines have pull-up resistors in place.", esp_err_to_name(ret));
    }
    return;
}

// Card has been initialized, print its properties
sdmmc_card_print_info(stdout, card);

// Use POSIX and C standard library functions to work with files.
// First create a file.
ESP_LOGI(TAG, "Opening file");
FILE* f = fopen("/sdcard/hello.txt", "w");
if (f == NULL) {
    ESP_LOGE(TAG, "Failed to open file for writing");
    return;
}
fprintf(f, "Hello %s!\n", card->cid.name);
fclose(f);
ESP_LOGI(TAG, "File written");

// Check if destination file exists before renaming
struct stat st;
if (stat("/sdcard/foo.txt", &st) == 0) {
    // Delete it if it exists
    unlink("/sdcard/foo.txt");
}

// Rename original file
ESP_LOGI(TAG, "Renaming file");
if (rename("/sdcard/hello.txt", "/sdcard/foo.txt") != 0) {
    ESP_LOGE(TAG, "Rename failed");
    return;
}

// Open renamed file for reading
ESP_LOGI(TAG, "Reading file");
f = fopen("/sdcard/foo.txt", "r");
if (f == NULL) {
    ESP_LOGE(TAG, "Failed to open file for reading");
    return;
}
char line[64];
fgets(line, sizeof(line), f);
fclose(f);
// strip newline
char* pos = strchr(line, '\n');
if (pos) {
    *pos = '\0';
}
ESP_LOGI(TAG, "Read from file: '%s'", line);

// All done, unmount partition and disable SDMMC or SPI peripheral
esp_vfs_fat_sdmmc_unmount();
ESP_LOGI(TAG, "Card unmounted");

}
extern "C" void app_main(void *pvParameter)
{
/Initialize LCD/
lcd_conf_t lcd_pins = {
.lcd_model    = LCD_MOD_ILI9341,
.pin_num_miso = GPIO_NUM_19,
.pin_num_mosi = GPIO_NUM_23,
.pin_num_clk  = GPIO_NUM_18,
.pin_num_cs   = GPIO_NUM_14,
.pin_num_dc   = GPIO_NUM_27,
.pin_num_rst  = GPIO_NUM_33,
.pin_num_bckl = GPIO_NUM_32,
.clk_freq     = 40 * 1000 * 1000,
.rst_active_level = 0,
.bckl_active_level = 1,
.spi_host = HSPI_HOST,
.init_spi_bus = true,
};
if (lcd_obj == NULL) {
    lcd_obj = new CEspLcd(&lcd_pins);
}

lcd_obj->setRotation(1);
lcd_obj->fillScreen(COLOR_ESP_BKGD);

//LCD APIS test is ok!!
sdcard_main();
//SD write Read file is ok!!

//ALL LCD APIS test is invalid.
lcd_obj->fillScreen(COLOR_BLUE);

vTaskDelay(2000 / portTICK_PERIOD_MS);

}

Do you have a suitable solution?
This question really bothers me to use esp32 on the M5Stack.

Closing as duplicate of https://github.com/espressif/esp-idf/issues/1597. Please follow the link to this issue and click "Subscribe" to receive further update.


KAFKA-3063; LogRecoveryTest causes JVM to exit occasionally

Remove deletion of tmp file in OffsetCheckpoint's constructor. This delete causes unintuitive behaviour like LogRecoveryTest causing a System.exit because the test creates an instance of OffsetCheckpoint in order to call read() on it (while unexpectedly deleting a file being written by another instance of OffsetCheckpoint).
Also:

Improve error-handling in OffsetCheckpoint
Also include minor performance improvements in read()
Minor clean-ups to ReplicaManager and LogRecoveryTest

Review by @ewencp or @guozhangwang (both of you showed interest in this problem).
I've included a few clean-ups in this PR, let me know if you'd prefer if I submitted them separately.

LGTM


dotnet pack with nuspec/project file

I need to be able to specify which files to include, and I haven't found how to do that with the csproj file, only with the nuspec file. On the other hand, the version number is set dynamically in the csproj file (it includes the date), and the nupkg can't do that. How can I get both behaviors? How do I tell dotnet pack to only include the files I want, through the csproj?

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: a7e805a3-f2ec-b05a-d5c8-29f7a8c16a5f
Version Independent ID: 4257ec12-df6f-ec52-aad3-012e5fce8133
Content: dotnet pack command - .NET Core CLI
Content Source: docs/core/tools/dotnet-pack.md
Product: dotnet-core
Technology: dotnet-cli
GitHub Login: @tdykstra
Microsoft Alias: tdykstra

@wli3 Who can help with this question?

@rrelyea and @nkolev92

There are some examples in https://docs.microsoft.com/en-us/nuget/reference/msbuild-targets#packing-using-a-nuspec & https://docs.microsoft.com/en-us/nuget/reference/msbuild-targets#advanced-extension-points-to-create-customized-package

Thanks @nkolev92 -- I'll add these links to the doc.


Fix: Replace screenshots on user doc page #2987

Automated message from Dropbox CLA bot
@540KJ, it looks like you've already signed the Dropbox CLA. Thanks!

This looks great, merged, thanks @540KJ!


Canonicalize options.method in m.request

Currently, m.request({ method: 'get', data: foo, url: bar }) doesn't send the data to the server because the method is checked against uppercase "GET". The documentation does say the 'method must be either "GET", "POST", ...', but it wasn't immediately obvious why it didn't work because HTTP methods are usually treated case-insensitively.

cf. fetch api
https://fetch.spec.whatwg.org/#http

To normalize a method, if it is a byte case-insensitive match for DELETE, GET, HEAD, OPTIONS, POST, or PUT, byte uppercase it.


Configure PDFKit to use XVFB

Description of change
wkhtmltopdf does not work out of the box on Ubuntu because it needs a display. We are adding XVFB as a dependency separately in our Terraform  but we also need to tell PDFKit to use xvfb-run to execute wkhtmltopdf if this executable is present

Just reading up on mkmf a bit more, it seems it's not advised to include this in your ruby projects so willingly, because of reasons I don't fully understand, but enough for me to pause.
Some more googling has given me this: system("which xvfb-run > /dev/null 2>&1") which is a) more minimal but also b) a little more brittle (will also return false if which isn't installed, or anything else goes wrong with this command), but given I don't think we have to worry about BOPS being installed on a windows system any time soon, I think it's a better trade off. What do you think?

Just reading up on mkmf a bit more, it seems it's not advised to include this in your ruby projects so willingly, because of reasons I don't fully understand

That's good to know! I think your proposed solution seems sensible


added Sieve_of_Eratosthenes.cpp

added Sieve_of_Eratosthenes.cpp

added Sieve_of_Eratosthenes.cpp

This branch has conflicts that must be resolved

please Delete this repo nd again fork nd did same thing nd update yopur PR
bcz of this i m not able to merge the PR


Please remove Tasmota as provided 3rd party firmware...

since actual Tuya Convert does not erase flash. It is a high risk to use Tasmota as target firmware.
Tasmota needs a erased flash to work reliable, because it stores and uses settings in flash areas.
Documented here https://github.com/ct-Open-Source/tuya-convert/issues/328#issuecomment-545831626

The comment you linked is talking about their own bin they built with Arduino, not Tasmota. Majority of cases report success. And it is known that it is not a guaranteed process, which you must agree to before using tuya-convert. In any case, I'll accept a PR if you want to update the bin.

This was not a finding from a self builded binary.
#328 is the flie you have in your repo.
And every Tasmota file can fail because Tuya convert does NOT erase flash.


Update scroll position when opening from command line with line specified

Attempt to fix #4780.
The event listener solution is probably hacky.  I mostly don't quite know when the DisplayBuffer is fully "initialized"/has a height, width, etc.  As of right now if I attempt to call @scrollToCursorPosition() in TextEditor's constructor (at say line 105), the DisplayBuffer has no size information when it gets to scrollToScreenRange() and no scrolling occurs.

#4780 was closed as we can't reproduce the problem anymore, so I'm closing this PR as well. If you can still reproduce the problem -- please post the steps in the issue and we can start from there. Thanks again!


Testing heroku deployment

Testing heroku branch deployments. DONT MERGE THIS PR.

Branching of master directly, this seems to deploy fine.


Update the game over message

Update the game over message so people know how to play again!

Thoughts: Everything looks good to push to prod.


Use in Godot Engine for mesh boolean operators on triangle meshes

Hi!
I am interested to know if I can use PicoGKRuntime for mesh boolean operators for intersection, subtraction and difference on triangle meshes in Godot Engine. I cannot use C# in the core Godot Engine.

Analysis of the dependencies required means I'd probably need to distribute as a c++ "gdextension".

boost
tbb
c-blosc
openvdb

A common request is to force meshes to be manifold and also autolod (mesh decimation).

Hi @fire —
yes, you can use the PicoGK runtime for this, either through the exported C API, or using the C++ Voxels and Mesh directly. I implemented all of these header-only, so the only things you would need are the compiled dependencies. the openvdb team is currently trying the eliminate the dependency on boos. TBB is required, blosc is only required if you need to deal with compressed .VDB files, which you are probably not.
You could, of course, also use openvdb directly, to do what you want to accomplish, using my source as an inspiration. OpenVDB can look daunting, but once you get the hang of it, it's relatively straightforward.
To retopologize a mesh, youd'd voxelize your mesh with something like this:
// Convert Mesh to Voxels

openvdb::math::Transform::Ptr roTransform
  = openvdb::math::Transform::createLinearTransform(fVoxelSize);

openvdb::FloatGrid::Ptr roGrid = openvdb::tools::meshToLevelSet<openvdb::FloatGrid>(
  *roTransform,
  oVertices,
  oTriangles,
  3.0);

// Convert Voxels to Mesh

std::vector< openvdb::Vec3s > oPoints;
std::vector< openvdb::Vec3I > oTriangles;
std::vector< openvdb::Vec4I > oQuads;

openvdb::tools::volumeToMesh<openvdb::FloatGrid>(
  *roGrid,
  oPoints,
  oTriangles,
  oQuads,
  0.0f,
  0.0,
  alse);

// Convert quads to triangles

for (const openvdb::Vec4I oQuad : oQuads)
{
    openvdb::Vec3I o1(oQuad[0], oQuad[1], oQuad[2]);
    oTriangles.push_back(o1);

    openvdb::Vec3I o2(oQuad[2], oQuad[3], oQuad[0]);
    oTriangles.push_back(o2);
}

// Now you have all vertices in oPoints and all triangles in oTriangles

The easiest way to see if it is doing what you want is use the PicoGK demo C# code and load various demo STLs and output them, as retopologized meshes.
Voxels vox = new(Mesh.mshFromStlFile(...);
Mesh msh = new(vox); // retopologize
msh.SaveToStlFile(...);

Hope this helps,
Lin

I recall that keeping vertex attributes was a headache. Will investigate.

In conclusion I split the problems:

no solution for making things manifold
Use https://github.com/elalish/manifold for the cad kernel

Thanks for the help though.


Heisenbug - CoInitialize sometimes needed when not in the main thread

Ran into this one when using FileOperator in a different thread.
Sometimes, when the code is running in a different thread than the original, we get an error that CoInitialize hasn't been called yet (the underlying API is through COM objects).
This one's a bit weird, The specifics of this case: I was using wxtrio to offload some long work into a thread using cooperative multitasking (async).  I'll have to dig into the specifics of trio (wxtrio just runs trio in guest mode - and I was launching long sync functions using trio.to_thread.run_sync).  I know trio uses a thread pool to run this jobs, but the question is: can a different thread end up running that code a different points?
The reason this needs a bit more digging is that CoInitialize and CoUninitialize  must be called in balanced pairs in each thread msdn.  If trio ends up having the code hop threads, this messes up the whole thing.
Normally, pythoncom handles this for us, but something is throwing it off.  For the moment, a workaround is the call CoInitialize / CoUninitialize myself when in code that can run in a different thread (it's safe to call the pair more than once in a single thread), but I want to make sure there's no thread hopping going on.  This brute force approach might end up with unbalanced calls.

Update: checked in with the trio guys, should be safe to just call CoInitialize/CoUninitialize in the the trio specific case.  Now just need to update the codebase to ensure they get called in matching pairs - might want to rework when the IFileOperation instance is created / destroyed (currently it's destroyed in the exit block)


credentials required for the build?

while trying to build the vaxthesat on either MacOS or Linux Ubuntu 18, i get to step 11/12 and it appears that credentials are required...
which would these before? GitHub or something else?
Step 11/12 : COPY --from=generator-base /upload/ /upload
invalid from flag value generator-base: pull access denied for generator-base, repository does not exist or may require 'docker login': denied: requested access to the resource is denied
make: *** [generator] Error 1

ok...there's a dependence on generator-base that isn't in the build script...had to manually build the base.


Some questions

Hi!
The design of these keyboards are really great and I am considering having them printed. I am familiar with soldering, but only on store bought kits. I was wondering if you could answer some questions regarding the Flea.

Does it support Nice!nano and zmk?
Is the sockets designed for choc v1 with choc spacing?
Are there case designs available?
Does it support power switch? If so, what kind?
Anything out of the ordenary with these designs I should be aware of?

Hi. Thanks for your interest in the Bugs.

Yes
Yes
No. But someone has made some. Details are in my channel on the Absolem Club Discord server: https://discord.com/channels/714176584269168732/912348297107214378/1069273304696901692. You could always ask them for the files.
Yes.
They do not have a reset switch. If you want to flash them you need to short the reset and ground pins on the n!n.

The best place to get help with my designs is on the Discord server linked above. Good luck with your build.