Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update README.md #6

Merged
merged 1 commit into from Aug 20, 2018
Merged

Update README.md #6

merged 1 commit into from Aug 20, 2018

Conversation

xchs
Copy link
Contributor

@xchs xchs commented Aug 19, 2018

Fix a typo.

Fix a typo.
@leofeyer leofeyer added the bug label Aug 20, 2018
@leofeyer leofeyer merged commit d427df6 into contao:4.4 Aug 20, 2018
@leofeyer
Copy link
Member

Thank you @xchs.

@xchs xchs deleted the patch-1 branch August 20, 2018 08:41
leofeyer pushed a commit that referenced this pull request Nov 1, 2019
…es command (see #866)

Description
-----------

Together with @Toflar we had a hard time debugging why the `contao:resize-images` command stopped at some point and did not want to continue. The error message was quite unclear especially that the requested file existed:

```
6/77b26349-9084f1ba.jpg......... failed
Unable to open image /var/www/vhosts/domain.tld/httpdocs/releases/233/assets/images/../../var/pim-images/77b26349.jpg
```

So we decided to introduce an option that allows to output more verbose error message simply by executing command in verbose mode `contao:resize-images -v`:

```
f/8ac5c4ec-213df40b.jpg.............. failed

 [ERROR] ImagickException: cache resources exhausted
         `/var/www/vhosts/domain.tld/httpdocs/releases/233/assets/images/../../var/pim-images/8ac5c4ec.jpg' @
         error/cache.c/OpenPixelCache/3864 in
         /var/www/vhosts/domain.tld/httpdocs/releases/233/vendor/imagine/imagine/src/Imagick/Imagine.php:69
         Stack trace:
         #0 /var/www/vhosts/domain.tld/httpdocs/releases/233/vendor/imagine/imagine/src/Imagick/Imagine.php(69):
         Imagick->__construct('/var/www/vhosts...')
         #1 /var/www/vhosts/domain.tld/httpdocs/releases/233/vendor/contao/image/src/Resizer.php(93):
         Imagine\Imagick\Imagine->open('/var/www/vhosts...')
         #2 /var/www/vhosts/domain.tld/httpdocs/releases/233/vendor/contao/image/src/DeferredResizer.php(185):
         Contao\Image\Resizer->executeResize(Object(Contao\Image\Image), Object(Contao\Image\ResizeCoordinates),
         '/var/www/vhosts...', Object(Contao\Image\ResizeOptions))
         #3 /var/www/vhosts/domain.tld/httpdocs/releases/233/vendor/contao/image/src/DeferredResizer.php(108):
         Contao\Image\DeferredResizer->executeDeferredResize('f/8ac5c4ec-213d...', Array,
         Object(Imagine\Imagick\Imagine))
         #4
         /var/www/vhosts/domain.tld/httpdocs/releases/233/vendor/contao/core-bundle/src/Command/ResizeImagesComma
         nd.php(189): Contao\Image\DeferredResizer->resizeDeferredImage(Object(Contao\Image\DeferredImage), false)
         #5
         /var/www/vhosts/domain.tld/httpdocs/releases/233/vendor/contao/core-bundle/src/Command/ResizeImagesComma
         nd.php(166): Contao\CoreBundle\Command\ResizeImagesCommand->resizeImage('f/8ac5c4ec-213d...',
         Object(Symfony\Component\Console\Style\SymfonyStyle))
         #6 /var/www/vhosts/domain.tld/httpdocs/releases/233/vendor/symfony/console/Command/Command.php(255):
```

Commits
-------

e9c6de9 Allow to output more verbose error messages in contao:resize-images command
leofeyer pushed a commit that referenced this pull request Aug 4, 2020
Description
-----------

With @Toflar we have discovered by accident that if a URL is double-encoded (for some reason, doesn't matter) the Contao's `RouteProvider` will eventually throw an error trying to query a database.

```
URL original: drachenlochmuseum-v%25c3%25a4ttis.html
URL decoded: drachenlochmuseum-v%c3%a4ttis.html
URL decoded 2nd time: drachenlochmuseum-vättis.html
```

The decoded URL is used in the database query and that fails because the database driver would like to replace wildcards `%c` with parameters that were not provided.

Stack trace:

```
Exception: Too few arguments to build the query string
#27 vendor/contao/core-bundle/src/Resources/contao/library/Contao/Database/Statement.php(304): replaceWildcards
#26 vendor/contao/core-bundle/src/Resources/contao/library/Contao/Database/Statement.php(249): execute
#25 vendor/contao/core-bundle/src/Resources/contao/library/Contao/Model.php(1102): find
#24 vendor/contao/core-bundle/src/Resources/contao/library/Contao/Model.php(973): findBy
#23 vendor/contao/core-bundle/src/Framework/Adapter.php(38): __call
#22 vendor/contao/core-bundle/src/Routing/RouteProvider.php(493): findPages
#21 vendor/contao/core-bundle/src/Routing/RouteProvider.php(88): getRouteCollectionForRequest
#20 vendor/contao/core-bundle/src/Routing/LegacyRouteProvider.php(43): getRouteCollectionForRequest
#19 vendor/symfony-cmf/routing/src/NestedMatcher/NestedMatcher.php(141): matchRequest
#18 vendor/contao/core-bundle/src/Routing/Matcher/LegacyMatcher.php(69): matchRequest
#17 vendor/symfony-cmf/routing/src/DynamicRouter.php(271): matchRequest
#16 vendor/symfony-cmf/routing/src/ChainRouter.php(188): doMatch
#15 vendor/symfony-cmf/routing/src/ChainRouter.php(158): matchRequest
#14 vendor/symfony/http-kernel/EventListener/RouterListener.php(115): onKernelRequest
#13 vendor/symfony/event-dispatcher/EventDispatcher.php(212): doDispatch
#12 vendor/symfony/event-dispatcher/EventDispatcher.php(44): dispatch
#11 vendor/symfony/http-kernel/HttpKernel.php(126): handleRaw
#10 vendor/symfony/http-kernel/HttpKernel.php(67): handle
#9 vendor/symfony/http-kernel/Kernel.php(198): handle
#8 vendor/symfony/http-kernel/HttpCache/SubRequestHandler.php(85): handle
#7 vendor/symfony/http-kernel/HttpCache/HttpCache.php(448): forward
#6 vendor/symfony/framework-bundle/HttpCache/HttpCache.php(57): forward
#5 vendor/symfony/http-kernel/HttpCache/HttpCache.php(420): fetch
#4 vendor/contao/manager-bundle/src/HttpKernel/ContaoCache.php(46): fetch
#3 vendor/symfony/http-kernel/HttpCache/HttpCache.php(317): lookup
#2 vendor/symfony/http-kernel/HttpCache/HttpCache.php(192): handle
#1 vendor/friendsofsymfony/http-cache/src/SymfonyCache/EventDispatchingHttpCache.php(98): handle
#0 web/app.php(58): null
```

Commits
-------

8ae2582 Fix a potential error if the URL has percentage in it
8caaf25 Fix unit tests
509f762 Correctly encode the page aliases
leofeyer pushed a commit that referenced this pull request Sep 17, 2021
Description
-----------

Running `php -dmemory_limit=<limit> contao-setup` won't make the sub processes run with a memory limit of `<limit>`. In fact this is true for all arguments because the binary cannot know what the php process was called with. 

We should IMHO at least handle the case for the memory limit, though. This PR does this by reading the value via `ini_get` and adding it to the call if not empty.

/cc @rabauss

Commits
-------

74bafa4 set memory limit for sub processes
a623be3 always set memory limit
1b9400a don't mock but ini_set memory limit in tests
1c454cd Reset the memory limit after the test
2528d0e Merge pull request #6 from leofeyer/fix/memory-limit

Reset the memory limit after the test
276dc13 CS
leofeyer pushed a commit that referenced this pull request Oct 1, 2021
Description
-----------

| Q                | A
| -----------------| ---
| Fixed issues     | Fixes #3242

This PR is a first shot at trying to display the root elements of page mounts (or any other tree view).

Before (until Contao 4.12.x):

<img width="1213" alt="Bildschirmfoto 2021-08-27 um 14 10 00" src="https://user-images.githubusercontent.com/481937/131125543-448f18d7-c59f-434a-b826-b47fd2a5487a.png">

With this PR:

<img width="1212" alt="Bildschirmfoto 2021-08-27 um 14 09 05" src="https://user-images.githubusercontent.com/481937/131125575-f820eac1-8a86-43d1-8c6a-deaa28ae899c.png">

It not only shows the trail but also ensures a consistent sorting 😎

Commits
-------

814e363 Implemented displaying the parent trails in tree views
b559a04 Improve Database::getParentRecords()
db97aba CS
c0ff42e Do not show any operations for root trail tree elements
84e1c16 Do not show the breadcrumb link for pages in the trail
553de2b Show the trail also in the bread crumb
781e4d1 Make display of root trails entirely optional and disable when breadcrumb is used
eb61b6a CS

Co-authored-by: Martin Auswöger <martin@auswoeger.com>
5c4bb78 Improve recursion

Co-authored-by: Martin Auswöger <martin@auswoeger.com>
66efbff Merge branch '4.x' into feature/visible-tree-trail
fad0390 Simplify access check

Co-authored-by: Leo Feyer <github@contao.org>
1f50b1e Fixed sorting of root pages removing root nodes
c328fdc CS
cc65396 Do not render already rendered parents multiple times
0682e61 Fixed wrong indentation
800f65c Completely reworked concept
f2a22f6 CS
2dccd76 CS
77f08b1 Make the checks non-strict again
1497a59 Merge pull request #6 from leofeyer/fix/remove-strict-types

Make the checks non-strict again
572b29c Fix the vertical alignment of the pages without link
1246b66 Remove a left-over int cast
7c7ae6a Handle the case that array_search() returns false
239b1a3 Merge branch '4.x' into feature/visible-tree-trail
3871462 Run the Gulp task
leofeyer pushed a commit that referenced this pull request Apr 27, 2022
Description
-----------

-

Commits
-------

211cfca Check type of DataContainer correctly
1dd7287 Add test for legacy datacontainer config
511fbac Increase BC
6d06203 Add deprecations
62b20b6 Compare actual class name (#6)
69b4ddb Adjust deprecation

Co-authored-by: Andreas Schempp <andreas.schempp@terminal42.ch>
leofeyer added a commit that referenced this pull request Jun 2, 2023
Description
-----------

Implements #6070

Commits
-------

0349790 Remove the parameters.yml file from the skeleton
24c279b Handle missing parameters in the manager plugin (see #6)

Co-authored-by: ausi <martin@auswoeger.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants