понедельник, 30 апреля 2018 г.

How to fix "the system cannot find the file specified. (code: 2)" and "unable to evaluate symlinks in Dockerfile"

If you receive "unable to evaluate symlinks in Dockerfile path" or "windows named pipe error: the system cannot find the file specified. (code: 2)" errors on Docker for Windows, enable Hyper-V in "turn on or off windows features" app and restart the computer.

среда, 25 апреля 2018 г.

how to fix Liip Imagine Bundle gets image only after browser page refresh

Be sure you didn't left somewhere dump() function at `resolve` route. It prevents of creating correct 301 response. Symfony in Profiler write it is 301, but actually in Chrome Devtools it is 200 because of dump() php function.

четверг, 19 апреля 2018 г.

[Symfony] how to disable "request.INFO: Matched route" messages in Monolog logs

app/config/config_prod.yml:
monolog:    
    handlers:        
        main:
            channels: ["!request"]
and run cache:clear -e prod if you on PROD environment.

среда, 18 апреля 2018 г.

[Sonata] "A non well formed numeric value encountered" error at upload

be sure you are using appropriate context in related form type in Sonata Admin class. If you doesnt need resizing or changing image compression, try to remove formats node in config.yml sonata_media node. It should looks like similar, without formats:

banner:    providers:        - sonata.media.provider.image

вторник, 17 апреля 2018 г.

how to fix 'Mysql has gone away'

just ensure you have swap file and add to /etc/mysql/my.cnf :

max_allowed_packet=32M
wait_timeout=172800