magento2-klaviyo's Issues
Cannot save Theme Configuration
Content->Configuration-> Edit (Theme) ->Save Configuration, you will get an error.
Something went wrong while saving this configuration: Notice: Undefined index: field in .../vendor/klaviyo/magento2-extension/Observer/PrivateApiKeyObserver.php on line 25
Please fix this ASAP
Cannot Activate OAuth Magento 2.4.2
I have tried setting up OAuth in Magento 2.4.2 but it will not activate from System > Integrations. I get the error "Sorry, something went wrong. Please try again later." This happens every time i've tried.
I have 3.0.2 installed and upgraded to 3.0.3 so i could setup OAuth as Klaviyo was not detecting my install before (and still not). I have triple checked my API details and they are correct.
question: compatibility with magento 2.2.7
which version can we install for magento ce 2.2.7?
Line Item URL does not exists for "Checkout started"
For "Checkout Started" parameters, there isn't any line item url.
There are parameters like {{ event.Extra.LineItems.0.Product.FirstImageURL }}, {{ event.Extra.LineItems.0.Name }}, {{ event.Extra.LineItems.0.Product.SKU }} but one we need is the line item URL which does not exist.
Please help to check this.
Thank you.
Area code is already set
klaviyo/magento2-extension 4.0.1
When running the following command:
bin/magento queue:consumer:start product_action_attribute.update
I get,
In State.php line 136:
Area code is already set
If I trace the error I get the following output:
#0 Magento\Framework\App\State->setAreaCode(adminhtml) called at [/var/www/html/vendor/klaviyo/magento2-extension/Helper/ScopeSetting.php:72]
#0 Magento\Framework\App\State->setAreaCode(global) called at [/var/www/html/vendor/magento/module-message-queue/Console/StartConsumerCommand.php:91]
\Klaviyo\Reclaim\Plugin\Api\CartSearchRepository::afterGetList Infinite Loop
Steps to reproduce
All cart interactions below should be done via API
- Create cart
- Add at least one product to cart
- Apply coupon code to cart (must be a code)
- Edit the cart product in the admin panel
- Reload cart
Expected Result
/rest/{{store}}/V1/carts/mine
should return your cart ID
Actual Result
An infinite loop is triggered when a quote has quote.coupon_code <> NULL AND quote.trigger_recollect = 1
Summarizing the call stack triggered by this combination:
☝️ Recollection is triggered here because editing a product in the quote sets quote.trigger_recollect = 1
During recollection https://github.com/magento/magento2/blob/ab815b51dad2a89b120cc53b26eefaee80a336f3/app/code/Magento/SalesRule/Observer/CouponCodeValidation.php#L66
validates the coupon code. The validation calls CartRepositoryInterface::getList
which re-triggers your plugin.
$found = $this->cartRepository->getList(
$this->criteriaBuilder->addFilter('main_table.' . CartInterface::KEY_ENTITY_ID, $quote->getId())
->create()
)->getItems();
At this point the request is infinitely looping until it timeouts or exhausts memory.
M2.3 unexpected '$result' (T_VARIABLE)
During magneto 2.3.2 compilation the following error occured
Parse error: syntax error, unexpected '$result' (T_VARIABLE) inl/vendor/klaviyo/magento2-extension/Plugin/Customer/Model/CustomerData.php on line 38;
after reviewing the code it was found you were missing the semicolon from end of variables but can i suggest you rewrite from
public function afterGetSectionData(Customer $subject, $result)
{
if ($this->currentCustomer->getCustomerId()) {
$result['lastname'] = $this->currentCustomer->getCustomer()->getLastname()
$result['email'] = $this->currentCustomer->getCustomer()->getEmail()
} else {
$result['lastname'] = '';
$result['email'] = '';
}
return $result;
}
To
public function afterGetSectionData(Customer $subject, $result)
{
$result['lastname'] = '';
$result['email'] = '';
if ($this->currentCustomer->getCustomerId()) {
$result['lastname'] = $this->currentCustomer->getCustomer()->getLastname();
$result['email'] = $this->currentCustomer->getCustomer()->getEmail();
}
return $result;
}
Magento2.1.6 Klaviyo - Asymmetric transaction rollback.
I have used your extension version 1.0.5 in Magento2.1.6.
Go to Admin > Stores > Configuration > KLAVIYO > General > Settings
-
Enable Klaviyo Extension > Yes
-
Public Klaviyo API Key > XXXXX
-
Private Klaviyo API Key > XXXXX
after Save Config
go to frontend and I try to Newsletter Subscription and getting an error > https://www.screencast.com/t/T24Ncq3T
Thank you
Insufficient CSP whitelisting for connect-src and img-src
When visiting the storefront, there are Content Security Policy violations for these files:
(XHR) https://fast.a.klaviyo.com/onsite/api/v2/modules?company_id={company id}
(Image) https://a.klaviyo.com/api/track?data={data}&company_id={company id}&i=1
It looks like more coverage needs to be added to csp_whitelist.xml. I was able to fix it with a patch that adds the following entries:
<policy id="connect-src"> <values> <value id="klaviyo-cdn" type="host">https://fast.a.klaviyo.com</value> </values> </policy> <policy id="img-src"> <values> <value id="klaviyo" type="host">https://a.klaviyo.com</value> </values> </policy>
No ACL rules
There are no ACL rules so that config access cannot be granted to individual user roles:
Klaviyo overrides saveShippingInformation JS action and removes other extension attributes
We have noticed, that once we installed Klaviyo module, our other 3rd party module Amasty Delivery Date have stopped working as the fields for delivery date and comments have not been passed to PHP.
After investigation it turned out, that Klaviyo module rebuild the saveShippingInformation payload disregarding any other information that could be inserted in the extension_attributes section of payload.
The issue comes from: Klaviyo_Reclaim::js/model/shipping-save-processor/default.js
Undefined property: Klaviyo\Reclaim\Helper\Data::$observerAtcPayload
Hello,
We are getting the following error in logs multiple times daily. Also, not sure if it's related but no klaviyo.log is being generated even though I have "Enable Klaviyo Logger" set to YES in magento extension.
exception.log
[2022-02-04 17:12:13] main.CRITICAL: Notice: Undefined property: Klaviyo\Reclaim\Helper\Data::$observerAtcPayload in /mnt/data/home/XXXXXXX.cloudwaysapps.com/XXXXXXX/public_html/app/code/Klaviyo/Reclaim/Helper/Data.php on line 43 {"exception":"[object] (Exception(code: 0): Notice: Undefined property: Klaviyo\Reclaim\Helper\Data::$observerAtcPayload in /mnt/data/home/XXXXXXX.cloudwaysapps.com/XXXXXXX/public_html/app/code/Klaviyo/Reclaim/Helper/Data.php on line 43 at /mnt/data/home/XXXXXXX.cloudwaysapps.com/XXXXXXX/public_html/vendor/magento/framework/App/ErrorHandler.php:61)"} []
system.log
[2022-02-04 17:12:13] main.CRITICAL: Exception message: Notice: Undefined property: Klaviyo\Reclaim\Helper\Data::$observerAtcPayload in /mnt/data/home/XXXXXXX.cloudwaysapps.com/XXXXXXX/public_html/app/code/Klaviyo/Reclaim/Helper/Data.php on line 43
Trace:
#1 Klaviyo\Reclaim\Helper\Data->getObserverAtcPayload() called at [app/code/Klaviyo/Reclaim/Observer/SalesQuoteSaveAfter.php:68][] []
#2 Klaviyo\Reclaim\Observer\SalesQuoteSaveAfter->execute() called at [vendor/magento/framework/Event/Invoker/InvokerDefault.php:88]
#3 Magento\Framework\Event\Invoker\InvokerDefault->_callObserverMethod() called at [vendor/magento/framework/Event/Invoker/InvokerDefault.php:74]
#4 Magento\Framework\Event\Invoker\InvokerDefault->dispatch() called at [vendor/magento/framework/Event/Manager.php:66]
#5 Magento\Framework\Event\Manager->dispatch() called at [generated/code/Magento/Framework/Event/Manager/Proxy.php:95]
#6 Magento\Framework\Event\Manager\Proxy->dispatch() called at [vendor/magento/framework/Model/AbstractModel.php:829]
#7 Magento\Framework\Model\AbstractModel->afterSave() called at [generated/code/Magento/Quote/Model/Quote/Interceptor.php:1265]
#8 Magento\Quote\Model\Quote\Interceptor->afterSave() called at [vendor/magento/framework/Model/ResourceModel/Db/VersionControl/AbstractDb.php:56]
#9 Magento\Framework\Model\ResourceModel\Db\VersionControl\AbstractDb->processAfterSaves() called at [vendor/magento/framework/Model/ResourceModel/Db/AbstractDb.php:424]
#10 Magento\Framework\Model\ResourceModel\Db\AbstractDb->save() called at [vendor/magento/module-quote/Model/ResourceModel/Quote.php:314]
#11 Magento\Quote\Model\ResourceModel\Quote->save() called at [vendor/magento/module-quote/Model/QuoteRepository/SaveHandler.php:121]
#12 Magento\Quote\Model\QuoteRepository\SaveHandler->save() called at [vendor/magento/framework/Interception/Interceptor.php:58]
#13 Magento\Quote\Model\QuoteRepository\SaveHandler\Interceptor->___callParent() called at [vendor/magento/framework/Interception/Interceptor.php:138]
#14 Magento\Quote\Model\QuoteRepository\SaveHandler\Interceptor->Magento\Framework\Interception{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]
#15 Magento\Quote\Model\QuoteRepository\SaveHandler\Interceptor->___callPlugins() called at [generated/code/Magento/Quote/Model/QuoteRepository/SaveHandler/Interceptor.php:23]
#16 Magento\Quote\Model\QuoteRepository\SaveHandler\Interceptor->save() called at [vendor/magento/module-quote/Model/QuoteRepository.php:202]
#17 Magento\Quote\Model\QuoteRepository->save() called at [vendor/magento/framework/Interception/Interceptor.php:58]
#18 Magento\Quote\Model\QuoteRepository\Interceptor->___callParent() called at [vendor/magento/framework/Interception/Interceptor.php:138]
#19 Magento\Quote\Model\QuoteRepository\Interceptor->Magento\Framework\Interception{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]
#20 Magento\Quote\Model\QuoteRepository\Interceptor->___callPlugins() called at [generated/code/Magento/Quote/Model/QuoteRepository/Interceptor.php:59]
#21 Magento\Quote\Model\QuoteRepository\Interceptor->save() called at [vendor/magento/module-checkout/Model/Cart.php:593]
#22 Magento\Checkout\Model\Cart->save() called at [vendor/magento/framework/Interception/Interceptor.php:58]
#23 Magento\Checkout\Model\Cart\Interceptor->___callParent() called at [vendor/magento/framework/Interception/Interceptor.php:138]
#24 Magento\Checkout\Model\Cart\Interceptor->Magento\Framework\Interception{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]
#25 Magento\Checkout\Model\Cart\Interceptor->___callPlugins() called at [generated/code/Magento/Checkout/Model/Cart/Interceptor.php:131]
#26 Magento\Checkout\Model\Cart\Interceptor->save() called at [vendor/magento/module-checkout/Controller/Cart/Add.php:129]
#27 Magento\Checkout\Controller\Cart\Add->execute() called at [vendor/magento/framework/Interception/Interceptor.php:58]
#28 Magento\Checkout\Controller\Cart\Add\Interceptor->___callParent() called at [vendor/magento/framework/Interception/Interceptor.php:138]
#29 Magento\Checkout\Controller\Cart\Add\Interceptor->Magento\Framework\Interception{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]
#30 Magento\Checkout\Controller\Cart\Add\Interceptor->___callPlugins() called at [generated/code/Magento/Checkout/Controller/Cart/Add/Interceptor.php:23]
#31 Magento\Checkout\Controller\Cart\Add\Interceptor->execute() called at [vendor/magento/framework/App/Action/Action.php:111]
#32 Magento\Framework\App\Action\Action->dispatch() called at [vendor/magento/framework/Interception/Interceptor.php:58]
#33 Magento\Checkout\Controller\Cart\Add\Interceptor->___callParent() called at [vendor/magento/framework/Interception/Interceptor.php:138]
#34 Magento\Checkout\Controller\Cart\Add\Interceptor->Magento\Framework\Interception{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]
#35 Magento\Checkout\Controller\Cart\Add\Interceptor->___callPlugins() called at [generated/code/Magento/Checkout/Controller/Cart/Add/Interceptor.php:32]
#36 Magento\Checkout\Controller\Cart\Add\Interceptor->dispatch() called at [vendor/magento/framework/App/FrontController.php:245]
#37 Magento\Framework\App\FrontController->getActionResponse() called at [vendor/magento/framework/App/FrontController.php:212]
#38 Magento\Framework\App\FrontController->processRequest() called at [vendor/magento/framework/App/FrontController.php:147]
#39 Magento\Framework\App\FrontController->dispatch() called at [vendor/magento/framework/Interception/Interceptor.php:58]
#40 Magento\Framework\App\FrontController\Interceptor->___callParent() called at [vendor/magento/framework/Interception/Interceptor.php:138]
#41 Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception{closure}() called at [vendor/magento/module-store/App/FrontController/Plugin/RequestPreprocessor.php:99]
#42 Magento\Store\App\FrontController\Plugin\RequestPreprocessor->aroundDispatch() called at [vendor/magento/framework/Interception/Interceptor.php:135]
#43 Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception{closure}() called at [vendor/magento/module-page-cache/Model/App/FrontController/BuiltinPlugin.php:71]
#44 Magento\PageCache\Model\App\FrontController\BuiltinPlugin->aroundDispatch() called at [vendor/magento/framework/Interception/Interceptor.php:135]
#45 Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]
#46 Magento\Framework\App\FrontController\Interceptor->___callPlugins() called at [generated/code/Magento/Framework/App/FrontController/Interceptor.php:23]
#47 Magento\Framework\App\FrontController\Interceptor->dispatch() called at [vendor/magento/framework/App/Http.php:116]
#48 Magento\Framework\App\Http->launch() called at [generated/code/Magento/Framework/App/Http/Interceptor.php:23]
#49 Magento\Framework\App\Http\Interceptor->launch() called at [vendor/magento/framework/App/Bootstrap.php:264]
#50 Magento\Framework\App\Bootstrap->run() called at [pub/index.php:29]
User not unsubscribed if Admin Newsletter Subscriber page used
Hi,
This applies to Magento 2.3.1, not tested on anything else.
If you unsubscribe a user from the newsletter subscriber page in the admin they unsubscribe method is never reached.
When the UserProfileNewsletterSubscribeObserver fires the $subscriber->isStatusChanged() always returns false which stops the rest of the execute method running. Magento thinks the user is unsubscribed but the information never makes it back to Klaviyo servers.
Doesn't seem to happen anywhere else on the site (frontend, admin user area, third party modules affecting newsletter subscriptions)
Thanks in advance.
Warning message Fallback to JQueryUI Compat activated
We are getting the following console warning on the checkout:
Fallback to JQueryUI Compat activated. Your store is missing a dependency for a jQueryUI widget. Identifying and addressing the dependency will drastically improve the performance of your site. Compat.js
It looks like the file vendor/klaviyo/magento2-extension/view/frontend/web/js/view/checkout/email.js is requiring 'jquery/ui' which causes this warning. It results in all jquery-ui modules being loaded onto the page.
Email address not validated before saving to quote
The automatic email address capture on the checkout page is not validated before saving it to the quote, this causes validation issues elsewhere:
Steps to reproduce:
- Add products to cart
- Proceed to checkout page
- Enter malformed email, e.g. example@broken
- Go back to cart page
- Remove a product from cart
- Error message appears "We can't remove the item."
UpgradeSchema.php has a bad version_compare
For extension upgrades, kl_sms_consent and kl_email_consent columns only get added to the quote and sales_order tables if the current version is greater then 2.0.0. Shouldn't that be less than 2.0.0 instead? I upgraded from 1.2.3, we don't have those new columns, and the upgrade didn't add the new columns because of the current version compare logic in place.
report.CRITICAL: No such entity with customerId = 0
\Magento\Newsletter\Model\Subscriber::subscribe():487
$this->save();
\Klaviyo\Reclaim\Observer\UserProfileNewsletterSubscribeObserver::execute():33
$customer = $this->customer_repository_interface->getById($subscriber->getCustomerId());
If a guest customer tries to subscribe it get an error "report.CRITICAL: No such entity with customerId = 0"
It will be great to have a configuration field to set Guest Firstname and Guest Lastname, for example:
\Klaviyo\Reclaim\Observer\UserProfileNewsletterSubscribeObserver::execute()
public function execute(\Magento\Framework\Event\Observer $observer)
{
if (!$this->_klaviyoScopeSetting->isEnabled()) {
return;
}
$subscriber = $observer->getDataObject();
if ($subscriber->isStatusChanged()) {
if ($subscriber->getCustomerId() !== 0) {
$customer = $this->customer_repository_interface->getById($subscriber->getCustomerId());
$email = $customer->getEmail();
$firstname = $customer->getFirstname();
$lastname = $customer->getLastname();
} else {
$email = $subscriber->getSubscriberEmail();
$firstname = ''; // get from config
$lastname = ''; // get from config
}
if ($subscriber->isSubscribed()) {
$this->_dataHelper->subscribeEmailToKlaviyoList(
$email,
$firstname,
$lastname
);
} else {
if (isset($customer)) {
$this->_dataHelper->unsubscribeEmailFromKlaviyoList($customer->getEmail());
} else {
$this->_dataHelper->unsubscribeEmailFromKlaviyoList($subscriber->getSubscriberEmail());
}
}
}
}
Or just
public function execute(\Magento\Framework\Event\Observer $observer)
{
if (!$this->_klaviyoScopeSetting->isEnabled()) {
return;
}
$subscriber = $observer->getDataObject();
if ($subscriber->isStatusChanged()) {
if ($subscriber->getCustomerId() !== 0) {
$customer = $this->customer_repository_interface->getById($subscriber->getCustomerId());
}
if ($subscriber->isSubscribed()) {
if (isset($customer)) {
$this->_dataHelper->subscribeEmailToKlaviyoList(
$customer->getEmail(),
$customer->getFirstname(),
$customer->getLastname()
);
} else {
$this->_dataHelper->subscribeEmailToKlaviyoList($subscriber->getSubscriberEmail());
}
} else {
if (isset($customer)) {
$this->_dataHelper->unsubscribeEmailFromKlaviyoList($customer->getEmail());
} else {
$this->_dataHelper->unsubscribeEmailFromKlaviyoList($subscriber->getSubscriberEmail());
}
}
}
}
Customer Specific code in .phtml files
/view/frontend/templates/analytics/initialize.phtml
<script text="text/javascript">
var _learnq = _learnq || [];
<?php if ( $this->isLoggedIn() ): ?>
_learnq.push(['identify', {
$email: "<?php echo $this->getCustomerEmail() ?>",
$first_name: "<?php echo $this->getCustomerFirstname(); ?>",
$last_name: "<?php echo $this->getCustomerLastname(); ?>"
}]);
<?php endif; ?>
</script>
You should NOT load customer specific code in phtml files because that block will get cached by FPC and then every customer will get the same content. So after cleaning cached if the first person who visits your site logged in then the there is a strong possibility that all other users who view page source will see that user info. This could become a privacy issue and also the wrong info will be sent to you. You should instead use Javascript to set this information
Option ID/Values coming in as numbers not names
kl_ tables filling database without any further use
We integrated the new 4.x version of the Klaviyo module. So far the 4.0.2 fixed some issues of the 4.0.1 but one issue we found after a week:
kl_sync and kl_events are constantly filling up. We had a sale this week and kl_sync is 3GB after one week and kl_events 1GB. Thats ridiculous. There should be a cron deleting all synced or moved event data.
3.0.3 tag is missing
Right now in the changelog and on the Magento marketplace we can see that latest version is 3.0.3, but the tag isn't available.
3.0.2...3.0.3 shows no diff at all right now, the https://github.com/klaviyo/magento2-klaviyo/releases shows 3.0.2 as well.
@klaviyojad @remstone7 Could you fix that?
Cannot Save Config
Under Store->Catalog->Catalog-> save Config
Under Store->Catalog->XML Sitemap-> save Config
You will get the error “Something went wrong while saving this configuration: We Can’t save the cron expression.”
Please help to fix this asap
Magento 2.4.4 not supported?
When we try to re-authorize our Klaviyo integration we get a "We ran into an error" message:
Klaviyo is unable to connect to Magento Server for OAuth Handshake.
Url tried was: https://www.domain.com/oauth/token/request
Please ensure that both /oauth/token/request and /oauth/token/access
are accessible
They seem to be accessible and working for others. Any idea?
class Klaviyo\Reclaim\Api\ReclaimInterface does not exist
How can I solve anyone helps me to solve this issue my Magento has 2.4.2
Missing License
This module lacks a license file so it's not clear whether we are allowed to maintain a private fork or contribute back to this module. According to the Magento Marketplace version of this plugin, it's released under Open Software License 3.0 (OSL-3.0) but that's not explicitly stated anywhere in this repo.
Would you be able to clarify the situation, please?
Doesn't work with 2.4 due to 2FA
Currently when you try to integrate Klaviyo with Magento 2.4 you are unable to connect due to 2FA. The only work around is to disable the 2FA module.
ReferenceError: Can't find variable: _learnq
Hi,
I'm getting this on latest 1.1.2 version and Magento 2.3.2
Reporting about 700 errors on a newly launched site (via Sentry.io) in approximately 48 hours. Happening across multiple browsers and devices.
Same issue reported in reports #16 and #42 I'm not sure what percentage of users are getting this issue.
2 way sync missing. Klaviyo unsub is not updated to Magento sub status
This has been discussed in another item already but not solved yet. It´s really business critical for many Magento clients and for Klaviyo I would think to make this work so agencies like our can recommend Klaviyo to Magento clients without workaround like "we need to hide the newsletter status from My account". Mailchimp works just fine with 2-way sync.
SMS Consent for Registered Customers with Saved Addresses
The SMS consent feature adds a checkbox to the shipping address form.
For registered customers with saved addresses, the checkbox will not be available if checking out with an existing saved address. This seems to be a serios gap in the functionality.
Is Klaviyo planning to address this use case as part of the module. Our client wants to make sure this use case is covered if they enable this functionality. We can custom build the something, but if Klaviyo is going to add it (it seems like you should) we'd just need to discard our code later, which would be a waste of time.
Private API Key Stored in plain text
https://github.com/klaviyo/magento2-klaviyo/blob/master/etc/adminhtml/system.xml#L21-L23
Should this be an obscure config value instead of text?
Product Delete not Working after install Module
If i comment this:
Klaviyo\Reclaim\Observer\ProductDeleteBefore
Product delete working fine.
The issue is on:
public function execute(Observer $observer)
{
$product = $observer->getEvent()->getProduct();
$websiteIds = $product->getWebsiteIds();
$storeIdKlaviyoMap = $this->_klaviyoScopeSetting->getStoreIdKlaviyoAccountSetMap($websiteIds);
foreach ($storeIdKlaviyoMap as $klaviyoId => $storeIds) {
if (empty($storeIds)) {
continue;
}
if ($this->_klaviyoScopeSetting->getWebhookSecret() && $this->_klaviyoScopeSetting->getProductDeleteBeforeSetting($storeIds[0])) {
$data = array (
'store_ids' => $storeIds,
'product_id' => $product->getId(),
);
$this->_webhookHelper->makeWebhookRequest('product/delete', $data, $klaviyoId);
}
}
}
to => $storeIdKlaviyoMap = $this->_klaviyoScopeSetting->getStoreIdKlaviyoAccountSetMap($websiteIds);
Swagger is not working
We're on Magento 2.2.6 and this plugin is causing an error for Swagger. Here's the issue when trying to access to this page:
/rest/all/schema?services=all
Data type "anyType" is not declared.
Private API Key field in general settings is disabled
Magento version: 2.4.1
Klaviyo version: 3.0.9
Installing with Composer
On a local machine with a custom domain name (.local)
No TLS/SSL certificate
I can’t follow the instruction from https://help.klaviyo.com/hc/en-us/articles/115005254348-How-to-Integrate-with-Magento-2-x-CE-and-EE-#install-with-composer--2-4--2 since the “Private Klaviyo API Key” field is disabled for no reason.
After Composer installation, I’ve already run:
bin/magento module:enable Klaviyo_Reclaim --clear-static-content
bin/magento setup:upgrade
bin/magento setup:static-content:deploy -f
The extension was enabled, the public key was set, and the configuration was saved. Still, the private API key is disabled. I’ve also tried uninstalling the extension and reinstalling it again using Composer. Nothing works.
I guess this is a bug. Otherwise, there should be a message indicating the reasons why the field is blocked.
Please help.
Track Profile Activity Use Deprecated Request
magento2-klaviyo/Helper/Data.php
Line 131 in 688b85e
The track events are using an encoded GET
request which fails for larger payloads. I don't know the exact length but beyond a certain size Klaviyo rejects the events with 414 Request-URI Too Large
. Klaviyo's API docs recommend sending the track event using the POST
method.
https://apidocs.klaviyo.com/reference/track-identify#track-get
Help with the method getKlSmsConsent
Hello,
I recently upgrade the Klaviyo extension version that I'm using on my Magento 2 store. I installed the latest version, 3.0.5. After sometime, I noticed that no orders were coming anymore. After some investigation I found some exceptions on the logs, they point to a method called getKlSmsConsent
, every time I try to place an order the exception is fired and the checkout cannot proceed, it happens once I select the shipping method and click to proceed.
I can see that it refers to the Consent at Checkout
feature, which's not even enabled on my store.
Below you can find a sample of the exception, for now, I'm disabling the extension, this is urgent.
One thing to notice, my store uses a React application on the frontend, so all the communication happens via the Magento GraphQL API, maybe that can help.
Exception Sample:
[2021-06-26 18:41:27] .ERROR: Call to undefined method Magento\Checkout\Api\Data\ShippingInformationExtension::getKlSmsConsent() {"exception":"[object] (GraphQL\\Error\\Error(code: 0): Call to undefined method Magento\\Checkout\\Api\\Data\\ShippingInformationExtension::getKlSmsConsent() at vendor/webonyx/graphql-php/src/Error/Error.php:174, Error(code: 0): Call to undefined method Magento\\Checkout\\Api\\Data\\ShippingInformationExtension::getKlSmsConsent() at vendor/klaviyo/magento2-extension/Model/Checkout/ShippingInformationManagement.php:29)"} []
You need to escape string
/vendor/klaviyo/magento2-extension/view/frontend/templates/product/viewed.phtml
Does not escape the product name, produces js error if product has double quote in name.
var item = { ProductID: "<?php echo $_product->getId(); ?>", Name: "<?php echo $_product->getName(); ?>", SKU: "<?php echo $_product->getSku(); ?>", URL: "<?php echo $_product->getProductUrl(); ?>", Price: <?php echo number_format($price, 2); ?>, FinalPrice: <?php echo number_format($final_price, 2); ?>, <?php if ($_product_image_url) { ?>ImageURL: "<?php echo $_product_image_url; ?>", <?php } ?> Categories: <?php echo $this->getProductCategoriesAsJson(); ?> };
Add trackingnumber as event field
To my surprise I just found out that the trackingnumber is not synced with the shipment event and by that not available for a transactional email like a shipment notification. I think its mandatory to have.
Message: Property "2" does not have accessor method "get2" in class "Magento\Quote\Api\Data\AddressExtensionInterface". {"exception":"[object]
Just installed module version 3.0.10 on Magento 2.4.1
After enabling and configuring the "Consent and Checkout", this causes 500 error for shipping-information API call (moving from Shipping Step to Payment Step)
Getting product Image
Is there a reason you are getting a random image from the product image gallery using
$_product_image_url = null;
// Check to see if we have an image for this product.
foreach ($_product->getMediaGalleryImages() as $_product_image) {
if (!$_product_image->getDisabled()) {
$_product_image_url = $_imagehelper
->init($_product, 'product_base_image')
->setImageFile($_product_image->getFile())
->getUrl();
break;
}
}
instead of getting the main product image from the product?
$_product_image_url = $_imagehelper->init($_product, 'product_base_image')->getUrl();
Multistore configuration?
Just wondering where this is in the product pipeline?
ACL is missing
The module is missing ACL, meaning that only admin users with full access is able to see the module.
_learnq is not defined
Uncaught ReferenceError: _learnq is not defined
at _learnq.push(['track', 'Viewed Product', item]);
Get this error on product pages from the extension (Version 1.0.5) on Magento 2.2.5
Klaviyo Magento2.2
I am looking for module which supports magento 2.2.+
[Feature] Observer on orders
Hi guys,
There should come a feature that the metrics are updated real time.
Like placed order, fulfilled order, fulfilled shipment, none of these seem 100% accurate or realtime.
Have a look at this repo:
https://github.com/picqer/magento2-plugin
A simple observer based on the order could do the trick, the above plugin has the right code to fit in the klaviyo plugin to update the data real time.
Failed to create Klaviyo user with error: A user with the same user name or email already exists.
I have just installed this module and got to the "Setup Klayivo User" stage and no matter what username i choose, even leaving it as the default "klaviyo" i get the errror "Failed to create Klaviyo user with error: A user with the same user name or email already exists." My business only uses 1 email address.
I havent created a user before and this is a new installation of the klaviyo module.
I am using Magento 2.4.2 and kalviyo was installed using composer.
Thanks,
Alex
Multistore products need to be passed with the correct store view name
Hi,
The event data that is passed to klaviyo does not contains the store view name, therefore it is taking the default values, this causes a lot issues in the flows when the incorrect titles are shown.
Please fix this.
Shipping methods not available after installing extension
My Magento version is 2.3.1 and I installed the recommended version of Klaviyo (3.0.4). After installing and configuration we have an issue with the checkout page. The shipping methods are not available. But after disabling an extension they are showing again and work normally. Can anyone help to fix an issue.?
Add Content Security Policy for 2.3.5
After upgrading to 2.3.5 the following errors are logged in the browser console
[Report Only] Refused to load the script 'https://static.klaviyo.com/onsite/js/klaviyo.js?company_id=' because it violates the following Content Security Policy directive:
[Report Only] Refused to load the script 'https://fast.a.klaviyo.com/media/js/analytics/klaviyo_analytics.js?v=5' because it violates the following Content Security Policy directive:
[Report Only] Refused to connect to 'https://fast.a.klaviyo.com/onsite/api/v2/modules?company_id=' because it violates the following Content Security Policy directive:
This is caused by a new module in 2.3.5 module-csp and can be resolved by adding Klaviyo domains to the Content Security Policy in a csp_whitelist.xml file. See https://devdocs.magento.com/guides/v2.3/extension-dev-guide/security/content-security-policies.html
Typo in classname quoteIdMaskFactory
016114c#diff-8068478cd6f1a97f7d001e4510c4acbbb82f8ba24a899e3a585a79b33817dbcaR22
Magento\Quote\Model\quoteIdMaskFactory
should be Magento\Quote\Model\QuoteIdMaskFactory
(so with a capital Q in Quote)
Js error _learnq is not defined
I suppose this commit introduced changed and breaks the js for the product viewed
ReferenceError: _learnq is not defined
klaviyo version : 1.1.0
magento : 2.3.2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.