Cleanup PhpStan test

Created on 5 September 2024, 9 months ago
Updated 6 September 2024, 9 months ago
πŸ“Œ Task
Status

Active

Version

3.0

Component

Code

Created by

πŸ‡©πŸ‡ͺGermany jurgenhaas Gottmadingen

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @jurgenhaas
  • Issue was unassigned.
  • Status changed to Needs review 9 months ago
  • πŸ‡©πŸ‡ͺGermany jurgenhaas Gottmadingen

    PHPStan is now green as well. I've added a couple of @todo in the code where the clean-up identified some obviously broken functionality which I wasn't able to resolve right away.

  • πŸ‡ΊπŸ‡ΈUnited States erutan

    This has been committed to the module already, should this just be closed along with https://www.drupal.org/project/fullcalendar/issues/3472260 πŸ“Œ Cleanup PHPCS test Needs review ?

  • Status changed to Active 10 days ago
  • πŸ‡ΊπŸ‡ΈUnited States dcam

    I'm setting this issue back to active because there was a commit for it, but there's more work to do. The PhpStan (next minor) test is failing. It's allowed to fail, which is fine. But someone needs to resolve any problems with it.

  • πŸ‡ΊπŸ‡ΈUnited States dcam
  • First commit to issue fork.
  • Pipeline finished with Failed
    9 days ago
    Total: 190s
    #514925
  • Pipeline finished with Failed
    9 days ago
    Total: 166s
    #514943
  • Pipeline finished with Failed
    9 days ago
    Total: 200s
    #514949
  • Pipeline finished with Failed
    9 days ago
    Total: 159s
    #514959
  • Pipeline finished with Failed
    9 days ago
    Total: 155s
    #514969
  • Pipeline finished with Failed
    9 days ago
    Total: 5316s
    #515009
  • Pipeline finished with Canceled
    9 days ago
    Total: 88s
    #515072
  • Pipeline finished with Failed
    9 days ago
    Total: 164s
    #515073
  • Pipeline finished with Failed
    9 days ago
    Total: 179s
    #515077
  • Pipeline finished with Failed
    9 days ago
    Total: 224s
    #515089
  • Pipeline finished with Failed
    9 days ago
    Total: 149s
    #515100
  • Pipeline finished with Failed
    9 days ago
    #515105
  • Pipeline finished with Failed
    9 days ago
    Total: 150s
    #515107
  • Pipeline finished with Failed
    9 days ago
    Total: 159s
    #515109
  • Pipeline finished with Failed
    9 days ago
    Total: 163s
    #515111
  • Pipeline finished with Failed
    9 days ago
    Total: 162s
    #515115
  • Hi there, I have solved all the issues with phpstan and phpcs in this project expect one.

    ```
    ------ -----------------------------------------------------------------------
    Line src/Plugin/fullcalendar/type/FullCalendar.php
    ------ -----------------------------------------------------------------------
    1766 Relying on entity queries to check access by default is deprecated in
    drupal:9.2.0 and an error will be thrown from drupal:10.0.0. Call
    \Drupal\Core\Entity\Query\QueryInterface::accessCheck() with TRUE or
    FALSE to specify whether access should be checked.
    πŸ’‘ See https://www.drupal.org/node/3201242 β†’
    ------ -----------------------------------------------------------------------
    ```
    we get the above error when `$tids = $query->execute();`

    ```
    ------ -----------------------------------------------------------------------
    Line src/Plugin/fullcalendar/type/FullCalendar.php
    ------ -----------------------------------------------------------------------
    1766 Call to method Drupal\Core\Entity\Query\QueryInterface::accessCheck()
    with true will always evaluate to true.
    πŸͺͺ method.alreadyNarrowedType
    πŸ’‘ Because the type is coming from a PHPDoc, you can turn off this
    check by setting treatPhpDocTypesAsCertain: false in your
    phpstan.neon.
    ------ -----------------------------------------------------------------------
    ```
    and the above when `$tids = $query->accessCheck(TRUE)->execute();`

  • πŸ‡¨πŸ‡¦Canada mandclu

    Sounds like this is ready for review then?

  • πŸ‡¨πŸ‡¦Canada mandclu
  • Pipeline finished with Skipped
    7 days ago
    #516546
  • πŸ‡¨πŸ‡¦Canada mandclu

    Thanks for the additional work here. Great to have both phpstan tests passing.

  • Thanks for solving the phpstan (minor) issue.

Production build 0.71.5 2024