cancel
Showing results for 
Search instead for 
Did you mean: 

Magento 2.4 extension not working (Solved)

Swappart
Frequent Contributor

Trying to integrate Shipstation with Magento 2.4.4. The extension is version 2.3.1 from the Magento marketplace. I'm getting the following error in the admin area.

 

Deprecated Functionality: error_log(): Passing null to parameter #1 ($message) of type string is deprecated in /home/public_html/magento/vendor/auctane/api/Model/NoConfigNotification.php on line 32

 

Looking at NoConfigNotification.php, I can see the configuration is supposed to be done from my shipstation.com account. I have tried setting up the store integration there, but I get a 404 error. I can see the APIs in swagger. I'm able to manually hit the GET API (v1/auctane/configure). I figured out from looking at Authenticator.php that I needed to pass 'ShipStation-Access-Token' in the header with the generated api key as it's value. I tried with cURL and get a 200 OK. I'm also able to hit the POST API and pass dummy values which make the above error go away. So, it seems the APIs are working. I'm not sure why Shipstation is getting a 404. Any ideas how to get this working?

144 REPLIES 144

Swappart
Frequent Contributor

I solved these issues a while ago and created a drop in extension to make it easier for everyone else. The extension just overrides several files and replaces them with ones I've corrected.

The latest version of SS in the marketplace is not right. It is an older version and it does not work. The version I use is 2.3.1, and it works for Magento 4.5.x.

To get it, use the following commands.

composer require auctane/api 2.3.1

Then download ShipStationFixer.zip from my site. Unzip and place Swappart directory in your app/code directory. and run the following commands.

php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy -f
php bin/magento indexer:reindex
php bin/magento c:f

You may still have other issues related to ShipStation adding index.php to your url. That is a different issue, and somewhere in this thread, I've posted how to fix that in your server's vhosts file. After fixing that, you may have to set up the store again in ShipStation so the necessary keys will be received by your SS install and stored in the database.

 

 

 

info720
Occasional Contributor

I had downloaded the fix but I see it needs to be in a folder called Swappart didn't see that.
also on 2.3.2 so I'll make those changes and try again/
Thanks 

info720
Occasional Contributor

Actually progress - I can now connect without error. Doesn't import any orders though, so we'll wait and see if it works when a new order shows up.

Swappart
Frequent Contributor

You can create a test product with a $0 price, and then use a test account to purchase it. Since it's free, it doesn't require any payment info. That's what I do, and then I just disable the test product until I need it again. Is this a new site, or something that worked previously and quit when you upgraded Magento?

We upgraded to Magento 2.4.5-p3 about 30 days ago, everything worked until today, now orders will not download. Shipstation support is no help, they want us to down grade Magento to 2.4.3 (which is not even supported), Will your fix work for this problem? Thanks Dave

atl
New Contributor

Hi All,

Anyone following this or proposing to use Magento with Shipstation should be fully aware that SS support for Magento was and continues to be appalling. I have also been advised (on a slightly older version of M2) to downgrade to an old unsupported version of Magento. This is an embarrassing level of support.

An amazing miss step for SS, given the size of the Magento user base - they are just not interested.....

Swappart
Frequent Contributor

 ShipStationFixer works. I just realized I made a mistake though. It should be placed in app/code/Swappart. I just uploaded a corrected version which contains the Swappart directory. I posted another reply with detailed instructions, but it has to be approved before it is visible for some reason. It only works with version 2.3.1 though. 

 

composer require auctane/api 2.3.1

php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy -f
php bin/magento indexer:reindex
php bin/magento c:f

info720
Occasional Contributor

Still showing those errors, dropped the version back to 2.3.1
Just to be clear app/code/Swappart
With the structure inside

Controller
Etc
Model
Plugin
registration

 

upgraded compiled deployed still shows same error.

Swappart
Frequent Contributor

app/code/Swappart/ShipStationFixer/

info720
Occasional Contributor

Does help when I do it right, it now works. Thanks for this, definitely a life saver.

Now if it would only work when using a VPN

lighthouseleds
Occasional Contributor

I agree, shipstation support is absolutely dismal and very surprising they could careless about magento integration. My guess is they get most of their business from the SaaS solutions (shopify, bigcommerce, volusion, etc...).

I used the fix by @Swappart and it is working well. I have not had any additional issues. I am now on 2.4.5-p2. I may recommend completely deleting your current shipstation extension and downloading the latest release. I have had issues with their releases and the files not being what they show on magento marketplace version. 

I hope this helps a little. 

lighthouseleds
Occasional Contributor

I had a similar issue where it wouldn't import orders between when it was working before and then after it was "fixed". I think it is because it believes it imported them. I can't recall what I found when digging into that. I contacted shipstation support (chat) and they can initiate an import different than we can on the client side. I gave them the order numbers and they were able to initiate the import and it brought them in. I would only contact them with that once you confirm a new order imports properly.

info720
Occasional Contributor

Will try that again still getting this error in the log

[2023-03-24T12:48:47.141518+00:00] auctane_api.ERROR: Deprecated Functionality: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /home/maxed4/public_html/vendor/auctane/api/Model/Action/Export.php on line 485 [] []

Swappart
Frequent Contributor

That issue should be resolved with my code. After you reverted to 2.3.1, did you do the following?

 

php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy -f
php bin/magento indexer:reindex
php bin/magento c:f

 

atl
New Contributor

1) Magento 2.4.5. Have installed/followed all of "Swappart" brilliant work
2) I have not dug into my server logs yet
3) I am seeing the same at SS as before
4) Have put the Api key from Magento and store url into SS, "Test Connection" no problem, then Save.
5) If I  come back and ... "Edit Connection" in SS, the "Setup Marketplace Connection" form does not have the Api/Url details that I previously entered.
6) I have queried with SS and they say that is the same for everyone and that this is not the reason it is showing the red ! instead of a Green Tick.

Question. Is that correct, if you have a working connection and you ... "Edit Connection" in SS, are those fields blank for you, i.e. you cannot "Test Connection" and this can only be done when you first setup (daft if that is the case)?

Cheers

Swappart
Frequent Contributor

Mine is the same. Those fields are blank. You are probably getting the red ! because it isn't able to import. Do you have index.php in your URL? When SS tries to connect to your store, for some reason, they add index.php into the url. If your site doesn't have that, then SS gets a 403. This also means the API never gets the keys which need to be in the database. You have to look at your server logs at this point and see if connections from shipstation (auctane/api) are returning a 403. If so, the solution is using rewrite rules in your server's vhosts file. We can go more into that when we determine if it is the issue.

lighthouseleds
Occasional Contributor

Since custom options were mentioned here, I am curious. Does this actually work for anyone? Unless I am understanding the functionality of it. I am assuming this will allow me to send any attribute from magento (from the selectable list) and import it into shipstation. I have an attribute selected and it never imports into shipstation. 

I am asking because I want to import harmonization codes for international shipping. From what I can see shipstation does not support this "natively" (baffling). I was hoping to set my HS code attribute as an export option and then maybe use that in shipstation to populate the Harmonization field. Typing this out, I doubt that possible but I may as well post it to see if anyone has any luck in getting anything like this to work.

It works on imports from eBay. They appear in the Notes section on the order details page. Not sure why it doesn't work from Magento. I don't think there's any way to make ShipStation do anything with them other than display them anyway though.

lighthouseleds
Occasional Contributor

That's really disappointing. 

 

To confirm, I am using 2.3.1 as well and it is working with 2.4.5-p2. Hopefully that helps anyone out there. 

cwwallis
New Contributor

This worked for me too.  Only issue I have is not all my order data is coming over on the feed. Anyone know how to edit that so I can add the missing details?

jdapron
First-timer

Hi, Thanks to Swappart for the huge fix.

We have Magento ver. 2.4.5-p1 and I believe the latest shipstation extension.

We just added a custom attribute in General Settings, and it worked again for importing orders.

However, every maybe 1 out  of 100 orders will not get imported for some reason.

Any ideas or things to check that may fix this?

lighthouseleds
Occasional Contributor

More issues with updating magento and auctane. ugh.... trying to update from 2.4.6-p3 to 2.4.6-p4

I first tried this with auctane version 2.3.1 and then attempted on 2.4.1. Either version of auctane was unsuccessful. I then found an article regarding zend and adding it back in with composer require: 

public_html$ bin/magento setup:di:compile
Compilation was started.
Area configuration aggregation... 5/9 [===============>------------] 55% 49 secs 362.0 MiB
In ClassReader.php line 57:

Impossible to process constructor argument Parameter #15 [ <required> Zend\Http\Client $zendClient ] of Auctane\Api\Model\Carrier\Ship
ping class

In GetParameterClassTrait.php line 34:

Class "Zend\Http\Client" does not exist

setup:di:compile

 This also didn't work. I am now restoring back to 2.4.6-p3. All of the above mentioned resulted in that same error when trying to compile. How is this that difficult for auctane/shipstation to get this right???

Any advice @Swappart ?

Unbelievable, or not so much, Shipstation denies any issues and tells me to have "Magento fix the problem". 

lighthouseleds
Occasional Contributor

Has anyone here updated M2 to 2.4.6-p4 and using the shipstation integration?

lighthouseleds
Occasional Contributor

Yet another update from shipstation. Absurd. I think this message alone says they have abandoned magento support.

Thank you for reaching out. 
 
Our senior support team recommends reaching out to your Magento developer to assist with the error. I truly apologize for the inconvenience. I understand how frustrating this can be. 
 
If you need further help feel free to reach out. 
 
Kind regards, 

Itumeleng M.