Skip to content

Commit

Permalink
don't instantiate hookimplmarker by implprefix deprecated in pytest-d…
Browse files Browse the repository at this point in the history
…ev/pluggy#116

Signed-off-by: Oleg Höfling <oleg.hoefling@gmail.com>
  • Loading branch information
hoefling committed May 22, 2019
1 parent 696fcc7 commit 29af259
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 7 deletions.
7 changes: 2 additions & 5 deletions src/devpi_ext/login.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
import ConfigParser as configparser
import os

from pluggy import HookimplMarker
import devpi.main


_key_repo = 'repository'
Expand All @@ -24,10 +24,7 @@
_section_keys = (_key_repo, _key_username, _key_password)


hookimpl = HookimplMarker('devpiclient')


@hookimpl(tryfirst=True)
@devpi.main.hookimpl(tryfirst=True)
def devpiclient_get_password(url, username):
"""See :py:func:`devpi.hookspecs.devpiclient_get_password`"""
pypirc = os.path.join(os.path.expanduser('~'), '.pypirc')
Expand Down
2 changes: 0 additions & 2 deletions src/devpi_ext/login.pyi
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
from typing import Optional, Text, TextIO
from pluggy import HookimplMarker

hookimpl: HookimplMarker

def _find_password(fp: TextIO, url: Text, username: Text) -> Optional[Text]: ...
def devpiclient_get_password(url: Text, username: Text) -> Optional[Text]: ...
Empty file added tests/test_hook_registration.py
Empty file.

0 comments on commit 29af259

Please sign in to comment.