Open minchaminder opened 2 weeks ago
@danh91 what do you think about using todays date or the let the api pass the group_id
?
also I think we need to remove customer_request_ids
becouse its now the same as the group_id
and it's wrong
canada post docs:
(Character String - up to 35 characters)
A unique ID that you can define for this shipment. It must be unique or the request will be rejected.
Supplier Account vendors must use this field to provide a unique identifier for any shipment that is a pre-authorized payment request.
You can also use this ID recover shipment details, such as the label, without the need for the information provided in the Create Shipment response. Instead, just use this ID in a request to Get Shipments.
That's one way to appro
@danh91 what do you think about using todays date or the let the api pass the
group_id
?
Yes using the date can be a way to address it.
also I think we need to remove
customer_request_ids
becouse its now the same as thegroup_id
and it's wrongcanada post docs:
(Character String - up to 35 characters) A unique ID that you can define for this shipment. It must be unique or the request will be rejected. Supplier Account vendors must use this field to provide a unique identifier for any shipment that is a pre-authorized payment request. You can also use this ID recover shipment details, such as the label, without the need for the information provided in the Create Shipment response. Instead, just use this ID in a request to Get Shipments.
The customer_request_ids
was supposed to be appended with the index to make uniq. I must have missed it during testing. It is used later as a way to retrieve shipments and process manifests.
Once the uniq issue is solved, Is there a reason to completely remove it?
Once the uniq issue is solved, Is there a reason to completely remove it?
I couldn't see its being used later, I only see shipment_identifiers
being used
Once group_id is not unique, we need to either use uuid just for that, and make unique per parcel,
p.s. I release now that you use group_id for mulit-parcel shipment 🤔
also we need to change the cancel method that instead of void it request shipment refund.
also we need to change the cancel method that instead of void it request shipment refund.
😅 It is way more complex than that. It is supposed to:
submitted
submitted
If it is not behaving like this then we have a bug. In fact if you call cancel for something that has been submitted it will fail because it needs a refund call prior
😅 It is way more complex than that. It is supposed to:
- request refunds then void when the package is
submitted
- void if the package hasn't been
submitted
If it is not behaving like this then we have a bug. In fact if you call cancel for something that has been submitted it will fail because it needs a refund call prior
exactly! and even worse it show in dashboard that it's canceled, as stated in https://github.com/karrioapi/karrio/issues/682
Shipment is marked as purchased I don't see a type submitted
also noticed another bug where the manifest dashboard take the first shipments reference and set it as the reference for the manifest
submitted
is a way of saying you are not going to create a manifest for it later so they mark it as purchased
.
submitted
== purchased
when you don't submit and add a group_id
instead, it means you plan on manifesting at the end of the day.
So if you cancel before manifesting, it will just void without requesting refunds. because it wasn't submitted.
When you manifest then it gets marked as purchased.
At least that's how I understood it.
submitted
is a way of saying you are not going to create a manifest for it later so they mark it aspurchased
.submitted
==purchased
when you don't submit and add a
group_id
instead, it means you plan on manifesting at the end of the day. So if you cancel before manifesting, it will just void without requesting refunds. because it wasn't submitted. When you manifest then it gets marked as purchased.At least that's how I understood it.
oh my bad, I thought you have submitted status in karrio.
that's correct, but I can't find the logic of canceling in the codebase, but this is how it supposed to be.
Here is the current implementation. it is done in the proxy.py file
We also need to account for the possibility of multiple accounts for the same carrier, such as Canada Post. Therefore, the manifesting process must be exclusive per account to avoid conflicts or errors when generating manifests.
Description:
A representative from Canada Post has reported an issue with how Karrio handles Group IDs for Canada Post shipments. The concern is that each shipment is being assigned its own Group ID, which quickly leads to hitting the limits for End-of-Day (EOD) manifests. This is inefficient compared to the expected behavior of grouping multiple shipments under a single Group ID.
Expected Behavior:
Current Behavior:
Steps to Reproduce:
Impact:
This behavior can lead to faster consumption of the EOD manifest limits and makes shipment management less efficient, forcing users to manage multiple manifests instead of a single grouped one. Updating the manifest GUI to work by groups rather than individual shipments would further improve efficiency.
For reference from Canada Post:
Performance limitations To avoid a timeout of our servers, please follow these recommendations: · Do not include more than 30 groups per manifest (i.e., maximum of 30 group-ids in one Transmit Shipments request.) · Do not put more than 5,000 shipments in one group.
System limitations To avoid an error, please do not exceed the following limits before performing a Transmit Shipments call: · Maximum of 50 groups per manifest (error 9109 if exceeded). · Maximum of 10,000 shipments in one group (error 9110 if exceeded). · Maximum of 10,000 shipments across multiple groups (error 9108 if exceeded).
Body (REST)