diff --git a/.doctor-rst.yaml b/.doctor-rst.yaml index 2ecd4fc7d2d..03806a68585 100644 --- a/.doctor-rst.yaml +++ b/.doctor-rst.yaml @@ -8,6 +8,7 @@ rules: correct_code_block_directive_based_on_the_content: ~ deprecated_directive_should_have_version: ~ ensure_bash_prompt_before_composer_command: ~ + ensure_class_constant: ~ ensure_correct_format_for_phpfunction: ~ ensure_exactly_one_space_before_directive_type: ~ ensure_exactly_one_space_between_link_definition_and_link: ~ @@ -49,6 +50,7 @@ rules: no_namespace_after_use_statements: ~ no_php_open_tag_in_code_block_php_directive: ~ no_space_before_self_xml_closing_tag: ~ + no_typographic_quotes: ~ non_static_phpunit_assertions: ~ only_backslashes_in_namespace_in_php_code_block: ~ only_backslashes_in_use_statements_in_php_code_block: ~ diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 497dfd9b430..3722546330d 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -72,7 +72,7 @@ jobs: key: ${{ runner.os }}-doctor-rst-${{ steps.extract_base_branch.outputs.branch }} - name: "Run DOCtor-RST" - uses: docker://oskarstark/doctor-rst:1.67.0 + uses: docker://oskarstark/doctor-rst:1.69.1 with: args: --short --error-format=github --cache-file=/github/workspace/.cache/doctor-rst.cache diff --git a/_build/build.php b/_build/build.php index 5298abe779a..b684700a848 100755 --- a/_build/build.php +++ b/_build/build.php @@ -15,6 +15,13 @@ ->addOption('generate-fjson-files', null, InputOption::VALUE_NONE, 'Use this option to generate docs both in HTML and JSON formats') ->addOption('disable-cache', null, InputOption::VALUE_NONE, 'Use this option to force a full regeneration of all doc contents') ->setCode(function(InputInterface $input, OutputInterface $output) { + // the doc building app doesn't work on Windows + if ('\\' === DIRECTORY_SEPARATOR) { + $output->writeln('ERROR: The application that builds Symfony Docs does not support Windows. You can try using a Linux distribution via WSL (Windows Subsystem for Linux).'); + + return 1; + } + $io = new SymfonyStyle($input, $output); $io->text('Building all Symfony Docs...'); diff --git a/best_practices.rst b/best_practices.rst index 2c393cae9c6..6211d042f0b 100644 --- a/best_practices.rst +++ b/best_practices.rst @@ -95,7 +95,7 @@ Use Secrets for Sensitive Information ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ When your application has sensitive configuration, like an API key, you should -store those securely via :doc:`Symfony’s secrets management system `. +store those securely via :doc:`Symfony's secrets management system `. Use Parameters for Application Configuration ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -362,10 +362,6 @@ Unless you have two legitimately different authentication systems and users (e.g. form login for the main site and a token system for your API only), it's recommended to have only one firewall to keep things simple. -Additionally, you should use the ``anonymous`` key under your firewall. If you -require users to be logged in for different sections of your site, use the -:doc:`access_control ` option. - Use the ``auto`` Password Hasher ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ diff --git a/bundles/best_practices.rst b/bundles/best_practices.rst index 37dc386b8e4..8049ebb9a1c 100644 --- a/bundles/best_practices.rst +++ b/bundles/best_practices.rst @@ -195,25 +195,24 @@ Continuous Integration Testing bundle code continuously, including all its commits and pull requests, is a good practice called Continuous Integration. There are several services -providing this feature for free for open source projects, like `GitHub Actions`_ -and `Travis CI`_. +providing this feature for free for open source projects, like `GitHub Actions`_. A bundle should at least test: * The lower bound of their dependencies (by running ``composer update --prefer-lowest``); * The supported PHP versions; -* All supported major Symfony versions (e.g. both ``4.x`` and ``5.x`` if +* All supported major Symfony versions (e.g. both ``6.4`` and ``7.x`` if support is claimed for both). -Thus, a bundle supporting PHP 7.3, 7.4 and 8.0, and Symfony 4.4 and 5.x should +Thus, a bundle supporting PHP 7.4, 8.3 and 8.4, and Symfony 6.4 and 7.x should have at least this test matrix: =========== =============== =================== PHP version Symfony version Composer flags =========== =============== =================== -7.3 ``4.*`` ``--prefer-lowest`` -7.4 ``5.*`` -8.0 ``5.*`` +7.4 ``6.4`` ``--prefer-lowest`` +8.3 ``7.*`` +8.4 ``7.*`` =========== =============== =================== .. tip:: @@ -233,10 +232,10 @@ with Symfony Flex to install a specific Symfony version: .. code-block:: bash - # this requires Symfony 5.x for all Symfony packages - export SYMFONY_REQUIRE=5.* + # this requires Symfony 7.x for all Symfony packages + export SYMFONY_REQUIRE=7.* # alternatively you can run this command to update composer.json config - # composer config extra.symfony.require "5.*" + # composer config extra.symfony.require "7.*" # install Symfony Flex in the CI environment composer global config --no-plugins allow-plugins.symfony/flex true @@ -560,6 +559,7 @@ Learn more * :doc:`/bundles/extension` * :doc:`/bundles/configuration` +* :doc:`/frontend/create_ux_bundle` .. _`PSR-4`: https://www.php-fig.org/psr/psr-4/ .. _`Symfony Flex recipe`: https://github.com/symfony/recipes @@ -568,4 +568,3 @@ Learn more .. _`choose any license`: https://choosealicense.com/ .. _`valid license identifier`: https://spdx.org/licenses/ .. _`GitHub Actions`: https://docs.github.com/en/free-pro-team@latest/actions -.. _`Travis CI`: https://docs.travis-ci.com/ diff --git a/cache.rst b/cache.rst index 83bb5b4cedc..5687d3544b6 100644 --- a/cache.rst +++ b/cache.rst @@ -539,6 +539,8 @@ Symfony stores the item automatically in all the missing pools. ; }; +.. _cache-using-cache-tags: + Using Cache Tags ---------------- @@ -950,9 +952,9 @@ a message bus to compute values in a worker: .. code-block:: php // config/framework/framework.php - use function Symfony\Component\DependencyInjection\Loader\Configurator\env; use Symfony\Component\Cache\Messenger\EarlyExpirationMessage; use Symfony\Config\FrameworkConfig; + use function Symfony\Component\DependencyInjection\Loader\Configurator\env; return static function (FrameworkConfig $framework): void { $framework->cache() diff --git a/components/browser_kit.rst b/components/browser_kit.rst index bcb8f7b3c8e..8cf0772298c 100644 --- a/components/browser_kit.rst +++ b/components/browser_kit.rst @@ -143,7 +143,7 @@ field values, etc.) before submitting it:: $crawler = $client->request('GET', 'https://github.com/login'); // find the form with the 'Log in' button and submit it - // 'Log in' can be the text content, id, value or name of a