Aunque el código de este tutorial utiliza Symfony 8, ¡todo lo comentado funciona en Symfony 7!
// composer.json
{
"require": {
"php": ">=8.4",
"ext-ctype": "*",
"ext-iconv": "*",
"babdev/pagerfanta-bundle": "^4.6", // v4.6.0
"doctrine/dbal": "^4.4", // 4.4.3
"doctrine/doctrine-bundle": "^3.2", // 3.2.2
"doctrine/doctrine-migrations-bundle": "^3.7", // 3.7.0
"doctrine/orm": "^3.6", // 3.6.6
"knplabs/knp-time-bundle": "^2.5", // 2.5.0
"pagerfanta/doctrine-orm-adapter": "^4.8", // v4.8.0
"php-cs-fixer/shim": "^3.94", // v3.95.2
"phpdocumentor/reflection-docblock": "^5.6", // 5.6.7
"phpstan/phpdoc-parser": "^2.3", // 2.3.2
"stof/doctrine-extensions-bundle": "^1.15", // v1.15.3
"symfony/asset": "8.0.*", // v8.0.8
"symfony/asset-mapper": "8.0.*", // v8.0.11
"symfony/console": "8.0.*", // v8.0.11
"symfony/dotenv": "8.0.*", // v8.0.11
"symfony/flex": "^2.10", // v2.10.0
"symfony/form": "8.0.*", // v8.0.9
"symfony/framework-bundle": "8.0.*", // v8.0.11
"symfony/http-client": "8.0.*", // v8.0.9
"symfony/monolog-bundle": "^4.0", // v4.0.2
"symfony/property-access": "8.0.*", // v8.0.8
"symfony/property-info": "8.0.*", // v8.0.8
"symfony/runtime": "8.0.*", // v8.0.12
"symfony/security-bundle": "8.0.*", // v8.0.12
"symfony/security-csrf": "8.0.*", // v8.0.8
"symfony/serializer": "8.0.*", // v8.0.10
"symfony/stimulus-bundle": "^2.34", // v2.35.0
"symfony/twig-bundle": "8.0.*", // v8.0.8
"symfony/ux-turbo": "^2.34", // v2.35.0
"symfony/validator": "8.0.*", // v8.0.10
"symfony/yaml": "8.0.*", // v8.0.12
"symfonycasts/tailwind-bundle": "^0.12.0", // v0.12.0
"twig/extra-bundle": "^3.24", // v3.24.0
"twig/twig": "^3.24" // v3.26.0
},
"require-dev": {
"symfony/debug-bundle": "8.0.*", // v8.0.8
"symfony/maker-bundle": "^1.67", // v1.67.0
"symfony/stopwatch": "8.0.*", // v8.0.8
"symfony/web-profiler-bundle": "8.0.*", // v8.0.12
"zenstruck/foundry": "^2.9" // v2.10.1
}
}
11 Comments
FYI when running
symfony composer req securityI got this message and had to select security-bundle from the listHey @stlgaits,
Strange indeed... This is the behaviour of composer when
symfony/flexisn't available. I'm curious, after you chose thesecurity-bundleand it installed, did the recipe run (didconfig/packages/security.yamlget created)?--Kevin
Hey @stlgaits,
That's weird :) Aliases like
securityshould work well withsymfony/flexpackage in yourcomposer.json. Did you download the course code from this page or are you trying this in your personal project?Anyway, not a big deal, requiring
symfony/security-bundleshould do the trick.Cheers!
I have a problem with installation. In Symfony 8 on Windows 11, when I try to run the command
symfony console tailwind:build, I get the following error: Access denied. Tailwind CSS build failedProblem solved by downgrading to Tailwind 3 and correcting some lines in base.html.twig
Hey @giorgiocba ,
Good job! Yeah, Windows, as always, causing more problems. When you first run the
tailwind:buildcommand - it tries to download the Tailwind binary for your system, and it seems like it can't due to a permissions issue. You should either fix the permissions issue properly or download it manually specify path to it in the config: https://symfony.com/bundles/TailwindBundle/current/index.html#using-a-different-binaryCheers!
Partially resolved, now I discover that pagination is not working
Hm, what exactly does not work? Do you see any errors on the page or in logs? Make sure
symfony composer installcommand executes successfully and you have all the deps installed properly.Cheers!
The problem is as follows: I launch the application, and the first entry is: on the left side of the screen, "USS LeafyCruiser (NCC-0001)." On the right, I have the details of USS LeafyCruiser (NCC-0001), including "arrived," "parts," and "droids."
When I click "next," no new information appears. The screen only tells me I'm on entry 2 of 14. However, on the left side of the screen, "USS LeafyCruiser (NCC-0001)" continues to appear, and on the right side, nothing appears except the "next" and "previous" links. The same thing happens if I go to entries 3, 4, and so on.
I'm currently working with the latest version of Ubuntu Linux and I'm experiencing the same error: paging isn't working. Only page 1 is visible, and none of the subsequent pages are. What's going on?
Hey @giorgiocba,
Yep, this is a bug in the course code. You can see in my video above I experience the same thing. Thanks for reporting!
The issue was the switch from MySQL (previous course that used this code) to Sqlite (switched to in this course for simplicity). They handle group by's a bit differently.
Removing that group-by fixes it! I've also updated the course code. A fresh download fixes it.
This is a great lesson in why your development database platform should match exactly your production database platform. There are subtle nuances like this that can bite you if you don't!
Thanks again!
Kevin
"Houston: no signs of life"
Start the conversation!