nlbone 0.8.0__py3-none-any.whl → 0.8.2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,6 @@
1
1
  {
2
- "auth": {
3
- "otp_sent": "کد تایید برای {mobile} ارسال شد."
4
- }
2
+ "MONTHLY": "ماه",
3
+ "YEARLY": "سال",
4
+ "DAILY": "روز",
5
+ "WEEKLY": "هفته"
5
6
  }
nlbone/utils/http.py CHANGED
@@ -12,7 +12,7 @@ def auth_headers(token: str | None) -> dict[str, str]:
12
12
 
13
13
 
14
14
  def build_list_query(
15
- limit: int, offset: int, filters: dict[str, Any] | None, sort: list[tuple[str, str]] | None
15
+ limit: int, offset: int, filters: dict[str, Any] | None, sort: list[tuple[str, str]] | None
16
16
  ) -> dict[str, Any]:
17
17
  q: dict[str, Any] = {"limit": limit, "offset": offset}
18
18
  if filters:
@@ -32,4 +32,6 @@ def normalize_https_base(url: str, enforce_https: bool = True) -> str:
32
32
 
33
33
 
34
34
  def get_service_base_url() -> str:
35
- return current_request().base_url
35
+ req = current_request() # Starlette Request
36
+ url = req.base_url # URL object
37
+ return str(url.replace(scheme="https"))
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: nlbone
3
- Version: 0.8.0
3
+ Version: 0.8.2
4
4
  Summary: Backbone package for interfaces and infrastructure in Python projects
5
5
  Author-email: Amir Hosein Kahkbazzadeh <a.khakbazzadeh@gmail.com>
6
6
  License: MIT
@@ -33,7 +33,7 @@ nlbone/adapters/http_clients/uploadchi/uploadchi_async.py,sha256=PQbVNeaYde5CmgT
33
33
  nlbone/adapters/i18n/__init__.py,sha256=fS97TR7HEc7fiDC2ufQKoFOxXDNkGA4njAFIB3EmhLk,426
34
34
  nlbone/adapters/i18n/engine.py,sha256=yH_b614oJQ2PgM8qpQ5_Prroi4Jjqb-xPguHCCJm0_0,1305
35
35
  nlbone/adapters/i18n/loaders.py,sha256=7td0Cmn0ehjDO2S2qeH31zwl8UyWI7quzedP9PnPhWk,2381
36
- nlbone/adapters/i18n/locales/fa-IR.json,sha256=Sc711S0_HexhSCJ6eVgr2HjoSDmSz4uODZmNn9O9Pec,88
36
+ nlbone/adapters/i18n/locales/fa-IR.json,sha256=C7nc8Lf1iX7Mxmk_TdFYQgij68bEyFBVawcJZ4x98do,92
37
37
  nlbone/adapters/messaging/__init__.py,sha256=o6ZiMihm_MhRXfcEpcjHBB3JGQovQbg3pxe0qS6516c,41
38
38
  nlbone/adapters/messaging/event_bus.py,sha256=MSM70JPHoDK17efWlh20ATT1O0KW7xWnwZ5D-gI6U_w,3773
39
39
  nlbone/adapters/messaging/rabbitmq.py,sha256=Io3flSj8DMIHExJguh3hDgWT4LuDoPYb_xmQQ3k47Cs,1894
@@ -111,12 +111,12 @@ nlbone/utils/context.py,sha256=Wq3QLYsMzo_xUiVAHLgEPQUG6LhgJTmFn8MO5Qa7S8w,1837
111
111
  nlbone/utils/crypto.py,sha256=PX0Tlf2nqXcGbuv16J26MoUPzo2c4xcD4sZBXxhBXgQ,746
112
112
  nlbone/utils/flatten_dict.py,sha256=nkx8gAcJkjCKG3I5y9clqtjGMZCWyUWRhgD2R8zGEqM,299
113
113
  nlbone/utils/flatten_sqlalchemy_result.py,sha256=JGwQEauoJVjhzvXrOtqabj3wQ7zp2-OPwhuh44sUdUE,625
114
- nlbone/utils/http.py,sha256=0yeI34j5FfelqvX3PJnKknSXji1jl15VYbVIIvrSbXg,997
114
+ nlbone/utils/http.py,sha256=llb4aPDL-Uvrht3c_VwJdngdKeT4WsCu1pXSoeI7vWA,1114
115
115
  nlbone/utils/normalize_mobile.py,sha256=sGH4tV9gX-6eVKozviNWJhm1DN1J28Nj-ERldCYkS_E,732
116
116
  nlbone/utils/redactor.py,sha256=-V4HrHmHwPi3Kez587Ek1uJlgK35qGSrwBOvcbw8Jas,1279
117
117
  nlbone/utils/time.py,sha256=DjjyQ9GLsfXoT6NK8RDW2rOlJg3e6sF04Jw6PBUrSvg,1268
118
- nlbone-0.8.0.dist-info/METADATA,sha256=Joe3SppJPlbtJ5q5vdB1jSKCTAgOodLaLdkI4BWg7K4,2294
119
- nlbone-0.8.0.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
120
- nlbone-0.8.0.dist-info/entry_points.txt,sha256=CpIL45t5nbhl1dGQPhfIIDfqqak3teK0SxPGBBr7YCk,59
121
- nlbone-0.8.0.dist-info/licenses/LICENSE,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
122
- nlbone-0.8.0.dist-info/RECORD,,
118
+ nlbone-0.8.2.dist-info/METADATA,sha256=U98QL0qunT7iz-N8KrbuowCD_QYC47K_YiYcPfH8IuY,2294
119
+ nlbone-0.8.2.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
120
+ nlbone-0.8.2.dist-info/entry_points.txt,sha256=CpIL45t5nbhl1dGQPhfIIDfqqak3teK0SxPGBBr7YCk,59
121
+ nlbone-0.8.2.dist-info/licenses/LICENSE,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
122
+ nlbone-0.8.2.dist-info/RECORD,,
File without changes