Skip to content

Commit 2651308

Browse files
GsantomaggioDaniele
and
Daniele
authored
Fix (#58)
* Fix Signed-off-by: Gabriele Santomaggio <[email protected]> * formatting --------- Signed-off-by: Gabriele Santomaggio <[email protected]> Co-authored-by: Daniele <[email protected]>
1 parent a6dbdde commit 2651308

File tree

6 files changed

+46
-76
lines changed

6 files changed

+46
-76
lines changed

poetry.lock

Lines changed: 36 additions & 66 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ readme = "README.md"
99
[tool.poetry.dependencies]
1010
python = "^3.9"
1111
python-qpid-proton = "^0.39.0"
12-
jwt = "^1.3.1"
1312
pyjwt = "^2.10.1"
1413

1514
[tool.poetry.group.dev.dependencies]

rabbitmq_amqp_python_client/connection.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ def _create_connection(self) -> None:
139139
mechs = None
140140

141141
if self._oauth2_options is not None:
142-
user = ""
142+
user = "no"
143143
password = self._oauth2_options.token
144144
mechs = "PLAIN"
145145
print("password, mechs: " + user + " " + password)

rabbitmq_amqp_python_client/qpid/proton/_utils.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -467,7 +467,8 @@ def __init__(
467467
)
468468

469469
except ConnectionException:
470-
self.conn.close()
470+
if self.conn is not None:
471+
self.conn.close()
471472
if attempt == len(urls):
472473
raise
473474
continue

tests/conftest.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,11 @@ def environment_auth(pytestconfig):
4646
uri="amqp://localhost:5672",
4747
oauth2_options=OAuth2Options(token=token_string),
4848
)
49-
try:
50-
yield environment
49+
# try:
50+
return environment
5151

52-
finally:
53-
environment.close()
52+
# finally:
53+
# environment.close()
5454

5555

5656
@pytest.fixture()

0 commit comments

Comments
 (0)