Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow / in strings #44

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
strategy:
matrix:
target: [x86_64, x86, aarch64]
version: [ "3.8", "3.9", "3.10", "3.11", "3.12" ]
version: [ "3.9", "3.10", "3.11", "3.12", "3.13" ]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
Expand All @@ -45,7 +45,7 @@ jobs:
strategy:
matrix:
target: [x64, x86]
version: [ "3.8", "3.9", "3.10", "3.11", "3.12" ]
version: [ "3.9", "3.10", "3.11", "3.12", "3.13" ]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
Expand All @@ -69,7 +69,7 @@ jobs:
strategy:
matrix:
target: [x86_64, aarch64]
version: [ "3.8", "3.9", "3.10", "3.11", "3.12" ]
version: [ "3.9", "3.10", "3.11", "3.12", "3.13" ]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
Expand Down
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
History
=======

0.7.1 (2024-12-15)
------------------
* Allow "/" in strings
* Drop support for Python 3.8

0.7.0 (2024-10-18)
------------------
* Allow binding to a local random free port
Expand Down
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,11 @@ Wheels are available for:

with Python versions:

* 3.8
* 3.9
* 3.10
* 3.11
* 3.12
* 3.13

**Requirements for installation from source**

Expand Down
6 changes: 0 additions & 6 deletions python/portforward/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -199,9 +199,6 @@ def _validate_str(arg_name, arg) -> str:
if len(arg) == 0:
raise ValueError(f"{arg_name} cannot be an empty str")

if "/" in arg:
raise ValueError(f"{arg_name} contains illegal character '/'")

return arg


Expand Down Expand Up @@ -253,7 +250,4 @@ def _kube_context(context):
if not isinstance(context, str):
raise ValueError(f"kube_context={context} is not a valid str")

if "/" in context:
raise ValueError("kube_context contains illegal character '/'")

return context
2 changes: 0 additions & 2 deletions tests/test_portforward.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,12 +157,10 @@ def test_portforward_from_port_zero_assigns_port(kind_cluster: KindCluster):
[
# Namespace
("", "web", 9000, 80),
("/test", "web", 9000, 80),
(1337, "web", 9000, 80),
(None, "web", 9000, 80),
# Pod name
("test", "", 9000, 80),
("test", "web/", 9000, 80),
("test", 1337, 9000, 80),
("test", None, 9000, 80),
# From port
Expand Down
Loading