Skip to content

Commit ac301b5

Browse files
committed
fix
1 parent e5e0a72 commit ac301b5

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

packages/settings-library/src/settings_library/basic_types.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#
2-
# NOTE: This files copies some of the types from models_library.basic_types
2+
# NOTE: This file copies some of the types from models_library.basic_types
33
# This is a minor evil to avoid the maintenance burden that creates
44
# an extra dependency to a larger models_library (intra-repo library)
55

@@ -59,3 +59,9 @@ class IDStr(ConstrainedStr):
5959
strip_whitespace = True
6060
min_length = 1
6161
max_length = 50
62+
63+
64+
# https://en.wikipedia.org/wiki/List_of_TCP_and_UDP_port_numbers#Registered_ports
65+
class RegisteredPortInt(ConstrainedInt):
66+
gt = 1024
67+
lt = 65535

packages/settings-library/src/settings_library/tracing.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
from models_library.basic_types import RegisteredPortInt
21
from pydantic import AnyUrl, Field
2+
from settings_library.basic_types import RegisteredPortInt
33

44
from .base import BaseCustomSettings
55

0 commit comments

Comments
 (0)