You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
According to its documentation, Repo.remote() is supposed to raise a ValueError is the specified remote name does not match an existing remote on the repository.
However, from the code it seems that its not the case:
def remote(self, name='origin'):
""":return: Remote with the specified name
:raise ValueError: if no remote with such a name exists"""
return Remote(self, name)
See the __init__ implementation for Remote:
class Remote(LazyMixin, Iterable):
def __init__(self, repo, name):
self.repo = repo
self.name = name
if os.name == 'nt':
dir(self)
The actual code just create a Remote instance which fails later on whenever one of its method is called.
This is likely not the expected behavior and I would assume the documation to be more sensible that the current implementation.
The text was updated successfully, but these errors were encountered:
According to its documentation,
Repo.remote()
is supposed to raise aValueError
is the specified remote name does not match an existing remote on the repository.However, from the code it seems that its not the case:
See the
__init__
implementation forRemote
:The actual code just create a
Remote
instance which fails later on whenever one of its method is called.This is likely not the expected behavior and I would assume the documation to be more sensible that the current implementation.
The text was updated successfully, but these errors were encountered: