magento / magento-cloud-docker

All Submissions you make to Magento Inc. (“Magento") through GitHub are subject to the following terms and conditions: (1) You grant Magento a perpetual, worldwide, non-exclusive, no charge, royalty free, irrevocable license under your applicable copyrights and patents to reproduce, prepare derivative works of, display, publically perform, sublicense and distribute any feedback, ideas, code, or other information (“Submission") you submit through GitHub. (2) Your Submission is an original work of authorship and you are the owner or are legally entitled to grant the license stated above. (3) You agree to the Contributor License Agreement found here: https://github.com/magento/magento2/blob/master/CONTRIBUTOR_LICENSE_AGREEMENT.html
Open Software License 3.0
257 stars 192 forks source link

PHP Opcache is overcaching files in developer mode #312

Closed aepod closed 3 years ago

aepod commented 3 years ago

Preconditions

  1. Developer mode, with native filesync
  2. WSL2 enabled docker (may affect macs too)
  3. Default php.ini, no changes to opcache settings

Steps to reproduce

  1. Bring up docker
  2. Change phtml template
  3. Clear magento caches
  4. changes do not reflect

Expected result

  1. Changes get reflected.

Actual result

  1. Changes are not shown. Also of note, you can restart containers with docker-compose down && docker-compose up. This will then reflect the changes.

Cause

Opcache is toggled on and no file changes are being checked. Reseting opcache or invalidating also fixes this.

YPyltiai commented 3 years ago

@aepod , wasn't it fixed with latest version? It looks very familiar.

shiftedreality commented 3 years ago

Fixed in latest version