Skip to content

Commit

Permalink
Remove python2 runner (#259)
Browse files Browse the repository at this point in the history
* Remove python2 runner

* Lint fixes
  • Loading branch information
jaysonsantos authored Jan 8, 2025
1 parent efeb037 commit 538a75a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/tests-and-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ jobs:
strategy:
max-parallel: 4
matrix:
python-version: [2.7, 3.7, 3.8, 3.9, "3.10", 3.11]
python-version: [3.7, 3.8, 3.9, "3.10", 3.11]

steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: LizardByte/setup-python[email protected]
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install Dependencies
Expand Down
2 changes: 1 addition & 1 deletion bmemcached/protocol.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ def is_ip_address(address):
return True
except ValueError:
return False

if is_ip_address(server):
return server, default_port

Expand Down
4 changes: 2 additions & 2 deletions test/test_server_parsing.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,9 @@ def testIPv6(self):
server = bmemcached.protocol.Protocol('2001:db8::2')
self.assertEqual(server.host, '2001:db8::2')
self.assertEqual(server.port, 11211)
# Since `2001:db8::2:8080` is a valid IPv6 address,
# Since `2001:db8::2:8080` is a valid IPv6 address,
# it is ambiguous whether to split it into `2001:db8::2` and `8080`
# or treat it as `2001:db8::2:8080`.
# or treat it as `2001:db8::2:8080`.
# Therefore, it will be treated as `2001:db8::2:8080`.
server = bmemcached.protocol.Protocol('2001:db8::2:8080')
self.assertEqual(server.host, '2001:db8::2:8080')
Expand Down

0 comments on commit 538a75a

Please sign in to comment.