PHP / Magento Dev Blog

  • Home

PHP named arguments and first-class callables – practical pipeline applications

  • 0
Henryk Tews
Sunday, 06 September 2026 / Published in PHP

PHP 8.1 and 8.2 brought named arguments and first-class callables – two features that change the way code is written. Named arguments eliminate “argument order confusion” and improve the readability of function calls with many parameters. First-class callables replace Closure::fromCallable() and [$this, 'method'] with the clean func(...) syntax.

(more…)

Magento 2 product shows “In Stock” with qty=0 – MSI and legacy stock inconsistency

  • 0
Henryk Tews
Wednesday, 02 September 2026 / Published in Magento / Adobe Commerce

A product showed “In Stock” on the product page despite actually being out of stock. Customers placed orders for a product that could not be fulfilled. The error only appeared when creating a shipment. The problem affected configurable products with MSI. Fix time: 4 hours.

(more…)

Docker Compose for Magento 2 without DDEV – custom stack PHP 8.4, MariaDB, Redis, OpenSearch

  • 0
Henryk Tews
Saturday, 29 August 2026 / Published in Środowiska

DDEV is a convenient tool but not the only way. Your own Docker Compose stack gives full control: exactly the service versions you need, custom network, CI/CD integration, deployable to any server without changes. I show a minimal but complete stack for Magento 2 with PHP 8.4, MariaDB 10.6, Redis, OpenSearch and nginx.

(more…)

Magento 2 wrong prices in multi-store – base currency and price rule cache

  • 0
Henryk Tews
Tuesday, 25 August 2026 / Published in Magento / Adobe Commerce

A multi-store shop (5 stores, 3 currencies) started showing wrong prices – the euro price appeared on the PLN store and vice versa. The problem appeared after adding a new store and only affected products with price rules. Fix time: 6 hours.

(more…)

Decorator pattern – dynamic behaviour, PHP, Magento 2 plugin system

  • 0
Henryk Tews
Friday, 21 August 2026 / Published in Wzorce projektowe

The Decorator pattern allows you to dynamically add behaviour to an object without modifying its class and without inheritance. Each decorator wraps the original object and extends or modifies its behaviour. In PHP and Magento 2 it is one of the most frequently used patterns – Magento’s plugin system is effectively a Decorator implemented by the DI framework.

(more…)

Magento 2 admin account locked by brute force attack – unlock and protection

  • 0
Henryk Tews
Monday, 17 August 2026 / Published in Magento / Adobe Commerce

An administrator account was locked after a dictionary attack – 10,000 login attempts in one hour. Magento locks an account after 6 failed attempts for 30 minutes. Problem: the attacker kept resetting the counter by changing IP, while the real admin could not log in. Fix time: 1 hour.

(more…)

Union-Find (Disjoint Set) – PHP implementation, cycle detection, deduplication

  • 0
Henryk Tews
Thursday, 13 August 2026 / Published in Algorytmy

Union-Find (Disjoint Set Union) is a data structure for managing disjoint sets. It supports two operations in nearly O(1) time: checking whether two elements belong to the same set (Find) and merging two sets (Union). The algorithm appears in graph problems, cycle detection and element grouping. In Magento 2 it is useful for merging duplicate customers and products.

(more…)

Magento 2 cron stuck – 50,000 pending jobs and deadlock in cron_schedule

  • 0
Henryk Tews
Sunday, 09 August 2026 / Published in Magento / Adobe Commerce

Magento 2 cron stopped working – over 50,000 unexecuted jobs were backed up in the cron_schedule table. Transactional emails were not going out, indexers were not updating, pricing rules were not refreshing. The shop worked normally for customers but was frozen “from the inside”. Fix time: 3 hours.

(more…)

PHP 8.3 – readonly classes, json_validate(), typed constants, #[Override]

  • 0
Henryk Tews
Wednesday, 05 August 2026 / Published in PHP

PHP 8.3 doprecyzował i rozszerzył kilka funkcji które były już w 8.1 i 8.2. Readonly properties dostały nowe możliwości, json_validate() zastąpiło powszechny hack z json_decode + sprawdzeniem błędu, a nowe funkcje tablic i typowanie klas wbudowanych zamknęły kilka długo otwartych luk. Pokażę zmiany które mają realny wpływ na codzienne pisanie kodu w Magento 2.

(more…)

Magento 2 – invisible CSS z-index bug caused 40% conversion drop

  • 0
Henryk Tews
Sunday, 02 August 2026 / Published in Magento / Adobe Commerce

The shop was running normally, but conversion suddenly dropped 40% in a single day. Google Analytics showed traffic at normal levels. The problem was invisible to the naked eye – only at a specific screen size did checkout buttons overlap and become unclickable. Diagnosis time: 3 hours, fix time: 30 minutes.

(more…)

  • 1
  • 2
  • 3

© 2026 Created by

TOP
Zarządzaj zgodą
Aby zapewnić jak najlepsze wrażenia, korzystamy z technologii, takich jak pliki cookie, do przechowywania i/lub uzyskiwania dostępu do informacji o urządzeniu. Zgoda na te technologie pozwoli nam przetwarzać dane, takie jak zachowanie podczas przeglądania lub unikalne identyfikatory na tej stronie. Brak wyrażenia zgody lub wycofanie zgody może niekorzystnie wpłynąć na niektóre cechy i funkcje.
Funkcjonalne Always active
Przechowywanie lub dostęp do danych technicznych jest ściśle konieczny do uzasadnionego celu umożliwienia korzystania z konkretnej usługi wyraźnie żądanej przez subskrybenta lub użytkownika, lub wyłącznie w celu przeprowadzenia transmisji komunikatu przez sieć łączności elektronicznej.
Preferencje
Przechowywanie lub dostęp techniczny jest niezbędny do uzasadnionego celu przechowywania preferencji, o które nie prosi subskrybent lub użytkownik.
Statystyka
Przechowywanie techniczne lub dostęp, który jest używany wyłącznie do celów statystycznych. Przechowywanie techniczne lub dostęp, który jest używany wyłącznie do anonimowych celów statystycznych. Bez wezwania do sądu, dobrowolnego podporządkowania się dostawcy usług internetowych lub dodatkowych zapisów od strony trzeciej, informacje przechowywane lub pobierane wyłącznie w tym celu zwykle nie mogą być wykorzystywane do identyfikacji użytkownika.
Marketing
Przechowywanie lub dostęp techniczny jest wymagany do tworzenia profili użytkowników w celu wysyłania reklam lub śledzenia użytkownika na stronie internetowej lub na kilku stronach internetowych w podobnych celach marketingowych.
  • Manage options
  • Manage services
  • Manage {vendor_count} vendors
  • Read more about these purposes
Zobacz preferencje
  • {title}
  • {title}
  • {title}