Skip to content

Commit

Permalink
Merge branch 'release/1.5.6'
Browse files Browse the repository at this point in the history
* release/1.5.6:
  bump version
  updates tox config
  fix http_basic_auth
  • Loading branch information
saxix committed Jan 20, 2023
2 parents 33eee4d + 43f8900 commit 2a523e7
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[bumpversion]
current_version = 1.5.5
current_version = 1.5.6
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)
serialize = {major}.{minor}.{patch}
commit = False
Expand Down
5 changes: 5 additions & 0 deletions CHANGES
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
1.5.6
-----
* pass request when basic_auth authenticate


1.5.5
-----
* minor refactoring of get_urls()
Expand Down
2 changes: 1 addition & 1 deletion src/admin_extra_buttons/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
NAME = 'django-admin-extra-buttons'
VERSION = __version__ = '1.5.5'
VERSION = __version__ = '1.5.6'
__author__ = 'sax'
2 changes: 1 addition & 1 deletion src/admin_extra_buttons/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def handle_basic_auth(request):
if authmeth.lower() == "basic":
auth = codecs.decode(auth.encode("utf8").strip(), "base64").decode()
username, password = auth.split(":", 1)
user = authenticate(username=username, password=password)
user = authenticate(request=request, username=username, password=password)
if user: # pragma: no branch
login(request, user)
return user
Expand Down
4 changes: 3 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,11 @@ markers =
functional: mark a test as functional

[testenv]
passenv = PYTHONDONTWRITEBYTECODE DISPLAY

setenv =
PYTHONDONTWRITEBYTECODE=true
DISPLAY=:0.0

extras = test
deps=
d22: django==2.2.*
Expand Down

0 comments on commit 2a523e7

Please sign in to comment.