perceval/backends/core/github.py
def _get_tokens_rate_limits(self):
        """Return array of all tokens remaining API points"""

        remainings = [0] * self.n_tokens
        # Turn off archiving when checking rates, because that would cause
        # archive key conflict (the same URLs giving different responses)
        arch = self.archive
        self.archive = None
        for idx, token in enumerate(self.tokens):
            # Pass flag to skip disabling archiving because this function doies it
            remainings[idx] = self._get_token_rate_limit(token)
        # Restore archiving to whatever state it was
        self.archive = arch
        logger.debug("Remaining API points: {}".format(remainings))
        return remainings
def _get_tokens_rate_limits(self):
        remainings = [0] * self.n_tokens
        # Turn off archiving when checking rates, because that would cause
        # archive key conflict (the same URLs giving different responses)
        arch = self.archive
        self.archive = None
        for idx, token in enumerate(self.tokens):
            # Pass flag to skip disabling archiving because this function doies it
            remainings[idx] = self._get_token_rate_limit(token)
        # Restore archiving to whatever state it was
        self.archive = arch
        logger.debug("Remaining API points: {}".format(remainings))
        return remainings
def _get_tokens_rate_limits ( self ) : remainings = [ 0 ] * self . n_tokens # Turn off archiving when checking rates, because that would cause # archive key conflict (the same URLs giving different responses) arch = self . archive self . archive = None for idx , token in enumerate ( self . tokens ) : # Pass flag to skip disabling archiving because this function doies it remainings [ idx ] = self . _get_token_rate_limit ( token ) # Restore archiving to whatever state it was self . archive = arch logger . debug ( "Remaining API points: {}" . format ( remainings ) ) return remainings
Return array of all tokens remaining API points
Return array of all tokens remaining API points