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

Fatal error on creating consignment for pickup point #313

Open
alexroosenstein opened this issue Aug 25, 2021 · 5 comments
Open

Fatal error on creating consignment for pickup point #313

alexroosenstein opened this issue Aug 25, 2021 · 5 comments
Labels
bug Something isn't working

Comments

@alexroosenstein
Copy link

alexroosenstein commented Aug 25, 2021

When creating a consignment and supplying it with an address of a pickup point the following fatal error occurs.
For reproduction purposes, the address apparently belongs to "De Kade Post".
I am using an older version of this library, but the relevant code seems identical to the current version.

<br />
<b>Fatal error</b>:  Uncaught TypeError: Argument 1 passed to MyParcelNL\Sdk\src\Model\Consignment\AbstractConsignment::setPickupNumber() must be of the type string, integer given, called in /myparcelnl/sdk/src/Adapter/ConsignmentAdapter.php on line 214 and defined in myparcelnl/sdk/src/Model/Consignment/AbstractConsignment.php:1640
Stack trace:
#0 myparcelnl/sdk/src/Adapter/ConsignmentAdapter.php(214): MyParcelNL\Sdk\src\Model\Consignment\AbstractConsignment-&gt;setPickupNumber(111)
#1 myparcelnl/sdk/src/Adapter/ConsignmentAdapter.php(184): MyParcelNL\Sdk\src\Adapter\ConsignmentAdapter-&gt;setByMethods(Array, Array)
#2 myparcelnl/sdk/src/Adapter/ConsignmentAdapter.php(44): MyParcelNL\Sdk\src\Adapter\ConsignmentAdapter-&gt;pickup()
#3 myparcelnl in <b>myparcelnl/sdk/src/Model/Consignment/AbstractConsignment.php</b> on line <b>1640</b><br />
@Mitchell-MyParcel Mitchell-MyParcel added the bug Something isn't working label Aug 31, 2021
@Mitchell-MyParcel
Copy link

@alexroosenstein Just to be sure; you are having this issue when an address is entered which unbeknownst is to you a pickup address but not a pickup address that is specifically selected as such in our checkout delivery options? If this is indeed the case than we can reproduce this issue and will work on solving it.

@svenvanhees
Copy link

Can confirm. I get the same issue for a client of mine. A customer of my client entered an pickup point unbeknownst to us. Which results in the error as supplied by @alexroosenstein.

@Mitchell-MyParcel
Copy link

@svenvanhees: Thanks for the confirmation. We are on it.

@peterquentin
Copy link

@Mitchell-MyParcel Any updates on this? I received the same error.

My only option right now is to create the shipment manually in postnl backend right?

@iamniels
Copy link

Could this issue receive some attention? It's a PITA in our workflow.

Regardless of the exception, the label is being created, so I'm unable handle the exception properly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Development

No branches or pull requests

5 participants