karrio-hermes 2026.1.4__py3-none-any.whl → 2026.1.5__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.
- karrio/providers/hermes/units.py +16 -6
- {karrio_hermes-2026.1.4.dist-info → karrio_hermes-2026.1.5.dist-info}/METADATA +1 -1
- {karrio_hermes-2026.1.4.dist-info → karrio_hermes-2026.1.5.dist-info}/RECORD +6 -6
- {karrio_hermes-2026.1.4.dist-info → karrio_hermes-2026.1.5.dist-info}/WHEEL +0 -0
- {karrio_hermes-2026.1.4.dist-info → karrio_hermes-2026.1.5.dist-info}/entry_points.txt +0 -0
- {karrio_hermes-2026.1.4.dist-info → karrio_hermes-2026.1.5.dist-info}/top_level.txt +0 -0
karrio/providers/hermes/units.py
CHANGED
|
@@ -337,18 +337,17 @@ def load_services_from_csv() -> list:
|
|
|
337
337
|
# Map carrier service code to karrio service code
|
|
338
338
|
karrio_service_code = ShippingService.map(service_code).name_or_key
|
|
339
339
|
|
|
340
|
+
row_min_weight = float(row["min_weight"]) if row.get("min_weight") else None
|
|
341
|
+
row_max_weight = float(row["max_weight"]) if row.get("max_weight") else None
|
|
342
|
+
|
|
340
343
|
# Initialize service if not exists
|
|
341
344
|
if karrio_service_code not in services_dict:
|
|
342
345
|
services_dict[karrio_service_code] = {
|
|
343
346
|
"service_name": service_name,
|
|
344
347
|
"service_code": karrio_service_code,
|
|
345
348
|
"currency": row.get("currency", "EUR"),
|
|
346
|
-
"min_weight":
|
|
347
|
-
|
|
348
|
-
),
|
|
349
|
-
"max_weight": (
|
|
350
|
-
float(row["max_weight"]) if row.get("max_weight") else None
|
|
351
|
-
),
|
|
349
|
+
"min_weight": row_min_weight,
|
|
350
|
+
"max_weight": row_max_weight,
|
|
352
351
|
"max_length": (
|
|
353
352
|
float(row["max_length"]) if row.get("max_length") else None
|
|
354
353
|
),
|
|
@@ -366,6 +365,15 @@ def load_services_from_csv() -> list:
|
|
|
366
365
|
),
|
|
367
366
|
"zones": [],
|
|
368
367
|
}
|
|
368
|
+
else:
|
|
369
|
+
# Update service-level weight bounds to cover all zones
|
|
370
|
+
current = services_dict[karrio_service_code]
|
|
371
|
+
if row_min_weight is not None:
|
|
372
|
+
if current["min_weight"] is None or row_min_weight < current["min_weight"]:
|
|
373
|
+
current["min_weight"] = row_min_weight
|
|
374
|
+
if row_max_weight is not None:
|
|
375
|
+
if current["max_weight"] is None or row_max_weight > current["max_weight"]:
|
|
376
|
+
current["max_weight"] = row_max_weight
|
|
369
377
|
|
|
370
378
|
# Parse country codes
|
|
371
379
|
country_codes = [
|
|
@@ -376,6 +384,8 @@ def load_services_from_csv() -> list:
|
|
|
376
384
|
zone = models.ServiceZone(
|
|
377
385
|
label=row.get("zone_label", "Default Zone"),
|
|
378
386
|
rate=float(row.get("rate", 0.0)),
|
|
387
|
+
min_weight=row_min_weight,
|
|
388
|
+
max_weight=row_max_weight,
|
|
379
389
|
transit_days=(
|
|
380
390
|
int(row["transit_days"].split("-")[0]) if row.get("transit_days") and row["transit_days"].split("-")[0].isdigit() else None
|
|
381
391
|
),
|
|
@@ -6,7 +6,7 @@ karrio/plugins/hermes/__init__.py,sha256=zUfOhtzuErd1H1ICL4rQt68e6BWRQf_B6_kW5UV
|
|
|
6
6
|
karrio/providers/hermes/__init__.py,sha256=wMiVnPz7EgKdbu1pGBuvalfyuHj5QwSeMijjvEP6q4w,590
|
|
7
7
|
karrio/providers/hermes/error.py,sha256=YWmYC_l7_nyJCxiqM0Kgf6yV9IpJ04tkdZyyMT7QnkY,2974
|
|
8
8
|
karrio/providers/hermes/tracking.py,sha256=olKfHEVYZuwGL9e4348Ui-mAKBGr94FLF6VyxCwtZZg,5941
|
|
9
|
-
karrio/providers/hermes/units.py,sha256=
|
|
9
|
+
karrio/providers/hermes/units.py,sha256=8-_jGT_yjnBmZWcNBzbGD1AszxUIJ4v3apQjOfzW6N0,14275
|
|
10
10
|
karrio/providers/hermes/utils.py,sha256=NOfS_K0Zw7_wxJGBJfkdXwZP6hs0bsaZye5uypztGc4,4163
|
|
11
11
|
karrio/providers/hermes/pickup/__init__.py,sha256=E59ks-qJAsNmfQgaZ7X0tZuBetITsdRSMJUAZnqxabg,307
|
|
12
12
|
karrio/providers/hermes/pickup/cancel.py,sha256=JYVGL9decPB0QOHsjrYU5cwT_4vzrpsaEjapC9F3t7A,1587
|
|
@@ -22,8 +22,8 @@ karrio/schemas/hermes/pickup_create_response.py,sha256=sAgq92J0TZOUolhMcvDkp6qSR
|
|
|
22
22
|
karrio/schemas/hermes/shipment_request.py,sha256=FMqrSlCDG4eGDkuqPDc_DDCbtV_vGRyrRBFCiNTFkmM,7415
|
|
23
23
|
karrio/schemas/hermes/shipment_response.py,sha256=BI2kUemG-wTzAFpok9KEnlwjm6eK_LemBA_Cyga_e6A,3477
|
|
24
24
|
karrio/schemas/hermes/tracking_response.py,sha256=6-bqTSl-N65PHl8cs1puOCFubzIZB55RveLdpNsmTEE,1967
|
|
25
|
-
karrio_hermes-2026.1.
|
|
26
|
-
karrio_hermes-2026.1.
|
|
27
|
-
karrio_hermes-2026.1.
|
|
28
|
-
karrio_hermes-2026.1.
|
|
29
|
-
karrio_hermes-2026.1.
|
|
25
|
+
karrio_hermes-2026.1.5.dist-info/METADATA,sha256=Ute2gZYW9m-tFogSK6_rWzfYnplNCXt63cvk1bzjhuk,982
|
|
26
|
+
karrio_hermes-2026.1.5.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
|
|
27
|
+
karrio_hermes-2026.1.5.dist-info/entry_points.txt,sha256=R8XDrYBqWXTPqaO0iTi4Buz8iQiiBiuHkJVNtZIXTkU,57
|
|
28
|
+
karrio_hermes-2026.1.5.dist-info/top_level.txt,sha256=9Nasa6abG7pPPG8MGzlemnqw1ohIqgouzQ7HGBnOFLg,27
|
|
29
|
+
karrio_hermes-2026.1.5.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|