Update Hikashop + PHP

  • Posts: 99
  • Thank you received: 5
2 years 3 months ago #338773

-- HikaShop version -- : HikaShop Business: 4.4.5
-- Joomla version -- : 3.10.4
-- PHP version -- : PHP Version 8.0.2

After updating to PHP8x

2 issues:

#1) error on checkout with payment using Eslect plugin +PHP 8 *note- works with PHP7.4:

Call to a member function getResponseCode() on null

Call stack
#	Function	Location
1	()	JROOT/plugins/hikashoppayment/eselect/eselect.php:74
2	plgHikashoppaymentEselect->onBeforeOrderCreate()	JROOT/libraries/joomla/event/event.php:70
3	JEvent->update()	JROOT/libraries/joomla/event/dispatcher.php:160
4	JEventDispatcher->trigger()	JROOT/libraries/src/Application/BaseApplication.php:108
5	Joomla\CMS\Application\BaseApplication->triggerEvent()	JROOT/administrator/components/com_hikashop/classes/order.php:175
6	hikashopOrderClass->save()	JROOT/administrator/components/com_hikashop/classes/order.php:891
7	hikashopOrderClass->createFromCart()	JROOT/components/com_hikashop/controllers/checkout.php:656
8	checkoutController->confirm()	JROOT/libraries/src/MVC/Controller/BaseController.php:702
9	Joomla\CMS\MVC\Controller\BaseController->execute()	JROOT/administrator/components/com_hikashop/helpers/helper.php:2286
10	hikashopController->execute()	JROOT/components/com_hikashop/hikashop.php:88
11	require_once()	JROOT/libraries/src/Component/ComponentHelper.php:402
12	Joomla\CMS\Component\ComponentHelper::executeComponent()	JROOT/libraries/src/Component/ComponentHelper.php:377
13	Joomla\CMS\Component\ComponentHelper::renderComponent()	JROOT/libraries/src/Application/SiteApplication.php:194
14	Joomla\CMS\Application\SiteApplication->dispatch()	JROOT/libraries/src/Application/SiteApplication.php:233
15	Joomla\CMS\Application\SiteApplication->doExecute()	JROOT/libraries/src/Application/CMSApplication.php:225
16	Joomla\CMS\Application\CMSApplication->execute()	JROOT/index.php:49



#2 error report on Admin + Public

Warning: Narrowing occurred during type inference of ZEND_FETCH_DIM_W. Please file a bug report on bugs.php.net in /home/xxx_dev/xxx_dev/administrator/components/com_hikashop/helpers/helper.php on line 1381



Please advise.

Please Log in or Create an account to join the conversation.

  • Posts: 81539
  • Thank you received: 13069
  • MODERATOR
2 years 3 months ago #338787

Hi,

1. Thank you for your feedback. The eSelect / Moneris plugin indeed has troubles with PHP 8. I've made a patch on our end for this.
Please download again the install package of HikaShop on our website and install it on yours and you'll get the patch for this.


2. Regarding the warning, it seems to be something linked to a bug in opcache with the compiling of PHP files.
So I don't think we can do anything on our end to avoid it.
Best is to report it on bugs.php.net

In the meantime, you can turn off the "error reporting" in the Joomla settings in order to hide the warning.

Last edit: 2 years 1 month ago by nicolas.
The following user(s) said Thank You: byoguru

Please Log in or Create an account to join the conversation.

  • Posts: 99
  • Thank you received: 5
2 years 3 months ago #338824

Thank you Nicolas.

Please Log in or Create an account to join the conversation.

  • Posts: 99
  • Thank you received: 5
2 years 3 months ago #338955

Hello again Nicholas,
It seems there is a similar error on MASS ACTIONS that we only just found out about during weekly reporting and so I have reverted to PHP7.4

Error: of 0 attempt to modify property value on null.

Trust it is okay to post here.

Please Log in or Create an account to join the conversation.

  • Posts: 81539
  • Thank you received: 13069
  • MODERATOR
2 years 3 months ago #338962

Hi,

It's ok yes. However, without the full error message, I can't say anything as the error could be anywhere.
Could you reproduce the issue after activating the "debug system" setting of the Joomla configuration in order to get the full error message ?

Please Log in or Create an account to join the conversation.

  • Posts: 99
  • Thank you received: 5
2 years 3 months ago #338982

Yes I need to replicate on a development site - please stand by.

Please Log in or Create an account to join the conversation.

  • Posts: 99
  • Thank you received: 5
2 years 3 months ago #338983

Result when triggering CRON via URL

0
Attempt to modify property "action" on null

HOME PAGE
Call stack
#	Function	Location
1	()	JROOT/plugins/hikashop/massaction_user/massaction_user.php:306
2	plgHikashopMassaction_user->onProcessUserMassActionexportCsv()	JROOT/libraries/joomla/event/event.php:70
3	JEvent->update()	JROOT/libraries/joomla/event/dispatcher.php:160
4	JEventDispatcher->trigger()	JROOT/libraries/src/Application/BaseApplication.php:108
5	Joomla\CMS\Application\BaseApplication->triggerEvent()	JROOT/administrator/components/com_hikashop/classes/massaction.php:1418
6	hikashopMassactionClass->process()	JROOT/administrator/components/com_hikashop/classes/massaction.php:1379
7	hikashopMassactionClass->trigger()	JROOT/administrator/components/com_hikashop/classes/massaction.php:2364
8	hikashopMassactionClass->_trigger()	JROOT/plugins/system/hikashopmassaction/hikashopmassaction.php:1919
9	plgSystemHikashopmassaction->onHikashopCronTrigger()	JROOT/libraries/joomla/event/event.php:70
10	JEvent->update()	JROOT/libraries/joomla/event/dispatcher.php:160
11	JEventDispatcher->trigger()	JROOT/libraries/src/Application/BaseApplication.php:108
12	Joomla\CMS\Application\BaseApplication->triggerEvent()	JROOT/administrator/components/com_hikashop/helpers/cron.php:63
13	hikashopCronHelper->cron()	JROOT/plugins/system/hikashoppayment/hikashoppayment.php:133
14	plgSystemHikashoppayment->processCronNotification()	JROOT/plugins/system/hikashoppayment/hikashoppayment.php:48
15	plgSystemHikashoppayment->onAfterInitialise()	JROOT/libraries/joomla/event/event.php:70
16	JEvent->update()	JROOT/libraries/joomla/event/dispatcher.php:160
17	JEventDispatcher->trigger()	JROOT/libraries/src/Application/BaseApplication.php:108
18	Joomla\CMS\Application\BaseApplication->triggerEvent()	JROOT/libraries/src/Application/CMSApplication.php:696
19	Joomla\CMS\Application\CMSApplication->initialiseApp()	JROOT/libraries/src/Application/SiteApplication.php:686
20	Joomla\CMS\Application\SiteApplication->initialiseApp()	JROOT/libraries/src/Application/SiteApplication.php:212
21	Joomla\CMS\Application\SiteApplication->doExecute()	JROOT/libraries/src/Application/CMSApplication.php:225
22	Joomla\CMS\Application\CMSApplication->execute()	JROOT/index.php:49

FROM ADMIN - "process MASS ACTION"

thousands of lines of warnings... (limitation filter set to 2,000):
Warning: Undefined array key "zone_country_code_3" in /home/oreas_dev/oreas_dev/administrator/components/com_hikashop/classes/massaction.php on line 378

Warning: Undefined array key "zone_state_name" in /home/oreas_dev/oreas_dev/administrator/components/com_hikashop/classes/massaction.php on line 378

Warning: Undefined array key "zone_country_code_3" in /home/oreas_dev/oreas_dev/administrator/components/com_hikashop/classes/massaction.php on line 366

Warning: Undefined array key "zone_state_name" in /home/oreas_dev/oreas_dev/administrator/components/com_hikashop/classes/massaction.php on line 366

Warning: Undefined array key "zone_country_code_3" in /home/oreas_dev/oreas_dev/administrator/components/com_hikashop/classes/massaction.php on line 347

+ Duplicate DB Queries
I can sent either a PDF of the ADMIN SCREEN
or login details.

Please Log in or Create an account to join the conversation.

  • Posts: 81539
  • Thank you received: 13069
  • MODERATOR
2 years 2 months ago #339000

Hi,

Thank you for that. I've added some patches for these.
Download again the install package of the latest version of HikaShop on our website and install it on yours to get them and you should not have these anymore.

If you have other issues after this, please provide again the debug and a screenshot of the settings of the mass action would be great too.

The following user(s) said Thank You: byoguru

Please Log in or Create an account to join the conversation.

  • Posts: 99
  • Thank you received: 5
2 years 2 months ago #339025

Thank you. That fixed the issue.

I have a new question about triggering multiple massactions via cron - I will start a new thread.

Please Log in or Create an account to join the conversation.

  • Posts: 99
  • Thank you received: 5
2 years 2 months ago #339068

Hi again Nicolas,
I found another PHP 8 issue

To replicate:- need to have an order for customer with no tax.
Client in Canada sells to USA and does not charge tax outside of Canada.

When editing the order in the admin interface and changing the quantity there is an error.
However I have reverted to PHP7.4 and it works as expected

An error has occurred.
0 Attempt to assign property "tax_namekey" on bool
/home/oreas_dev/oreas_dev/administrator/components/com_hikashop/classes/order_product.php:484
Call stack
#	Function	Location
1	()	JROOT/administrator/components/com_hikashop/classes/order_product.php:484
2	hikashopOrder_productClass->update()	JROOT/administrator/components/com_hikashop/classes/order.php:1240
3	hikashopOrderClass->saveForm()	JROOT/administrator/components/com_hikashop/controllers/order.php:608
4	OrderController->save()	JROOT/libraries/src/MVC/Controller/BaseController.php:702
5	Joomla\CMS\MVC\Controller\BaseController->execute()	JROOT/administrator/components/com_hikashop/helpers/helper.php:2286
6	hikashopController->execute()	JROOT/administrator/components/com_hikashop/hikashop.php:73
7	require_once()	JROOT/libraries/src/Component/ComponentHelper.php:402
8	Joomla\CMS\Component\ComponentHelper::executeComponent()	JROOT/libraries/src/Component/ComponentHelper.php:377
9	Joomla\CMS\Component\ComponentHelper::renderComponent()	JROOT/libraries/src/Application/AdministratorApplication.php:101
10	Joomla\CMS\Application\AdministratorApplication->dispatch()	JROOT/libraries/src/Application/AdministratorApplication.php:159
11	Joomla\CMS\Application\AdministratorApplication->doExecute()	JROOT/libraries/src/Application/CMSApplication.php:225
12	Joomla\CMS\Application\CMSApplication->execute()	JROOT/administrator/index.php:51
 Return to Control Panel

Please Log in or Create an account to join the conversation.

  • Posts: 81539
  • Thank you received: 13069
  • MODERATOR
2 years 2 months ago #339123

Hi,

Thank you for that. I've added a patch for this.
Download again the install package of the latest version of HikaShop on our website and install it on yours to get them and you should not have that error anymore.

Please Log in or Create an account to join the conversation.

  • Posts: 99
  • Thank you received: 5
2 years 2 months ago #339138

Thank you Nicolas.

Please Log in or Create an account to join the conversation.

  • Posts: 584
  • Thank you received: 22
  • Hikaserial Subscription Hikashop Multisite
2 years 1 month ago #340416

Hi,

It looks like this error stil exist! But only in combination with HikaSerial installed!!!!

We have installed again the latest 4.5 version today in combination with PHP 8.
But on the back-and we get this error:

Warning: Narrowing occurred during type inference of ZEND_FETCH_DIM_W. Please file a bug report on bugs.php.net in /data/sites/web/domainnl/subsites/domain.eu/administrator/components/com_hikashop/helpers/helper.php on line 1381

Switching back to PHP 7.4 fixes this issue so it's indeed related to PHP 8.

And in the check-out we get this error with PHP 8 and not with PHP 7.4:
0
Attempt to modify property "checkout_top" on null

We also get this error with PHP 7.4 on check-out:
Warning: Creating default object from empty value in /data/sites/web/domainsnl/subsites/domain.eu/plugins/hikashop/auto_fill/auto_fill.php on line 109

Hope you can fix this.

Kind regards,
Lumiga


Kind regards,
Lumiga
Attachments:
Last edit: 2 years 1 month ago by Lumiga.

Please Log in or Create an account to join the conversation.

  • Posts: 81539
  • Thank you received: 13069
  • MODERATOR
2 years 1 month ago #340423

Hi,

1. So do you mean that if you go on PHP8, you get the error, but then if you disable hikaserial while staying on PHP8, you don't have the error ? That would indeed confirm that it's linked to a problem with PHP8 and HikaSerial.

2. Thank you for the report on the warning with the Auto Fill plugin. I've made a patch in the plugin for this. Download again the install package of the plugin on our website and install it on yours to get it fixed.

Please Log in or Create an account to join the conversation.

  • Posts: 584
  • Thank you received: 22
  • Hikaserial Subscription Hikashop Multisite
2 years 4 weeks ago #340449

Hi Nicolas,

We did not have installed the HikaShop Address Auto fill plugin on this site.
But I downloaded en installed the latest version of Hikashop again and now the issue is solved.
And all errors/warnings etc. are gone!

So thankyou!

Kind regards,
Lumiga


Kind regards,
Lumiga
Attachments:
Last edit: 2 years 4 weeks ago by Lumiga.
The following user(s) said Thank You: nicolas

Please Log in or Create an account to join the conversation.

  • Posts: 81539
  • Thank you received: 13069
  • MODERATOR
2 years 4 weeks ago #340503

Hi,

Do you still have a copy of the helper.php file where the error message was pointing at before you update HikaShop ?
If so, could you provide a copy ?

Please Log in or Create an account to join the conversation.

  • Posts: 584
  • Thank you received: 22
  • Hikaserial Subscription Hikashop Multisite
2 years 3 weeks ago #340522

Yes I have a version form 25-3-2022 but there is no difference in code with the last version as I can see!

File Attachment:

File Name: helper-old...2022.zip
File Size:26 KB


Kind regards,
Lumiga
Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 81539
  • Thank you received: 13069
  • MODERATOR
2 years 3 weeks ago #340523

Hi,

Thank you.
I've created an issue on PHP's github:
github.com/php/php-src/issues/8251
Hopefully, something can come out of this.

Please Log in or Create an account to join the conversation.

  • Posts: 584
  • Thank you received: 22
  • Hikaserial Subscription Hikashop Multisite
2 years 3 weeks ago #340527

Hi Nicolas,

What is important to know is that we have been on PHP 8 for a while and did not experience any problems.
Only after we installed HikaSerial we get these issues!

Kind regards,
Lumiga


Kind regards,
Lumiga
Last edit: 2 years 3 weeks ago by Lumiga.

Please Log in or Create an account to join the conversation.

  • Posts: 584
  • Thank you received: 22
  • Hikaserial Subscription Hikashop Multisite
2 years 3 weeks ago #340630

Hi Nicolas,

Now we get this error on an other website when we update to Hikashop 4.5 without HikaSerial.
So maybe it has nothing to do with Hikaserial.

And after refreshing the warning is gone!

Warning: Narrowing occurred during type inference of ZEND_FETCH_DIM_W. Please file a bug report on bugs.php.net in /data/sites/web/domainnam/subsites/domainname/administrator/components/com_hikashop/helpers/helper.php on line 1381

Kind regards,
Lumiga


Kind regards,
Lumiga
Last edit: 2 years 3 weeks ago by Lumiga.
The following user(s) said Thank You: nicolas

Please Log in or Create an account to join the conversation.

Time to create page: 0.100 seconds
Powered by Kunena Forum