Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-76455

Address serious issues identified by static analystic (phpstan)

    XMLWordPrintable

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 4.0.5, 4.1.1
    • None
    • General
    • None

    Description

       8842/8842 [▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓] 100% < 1 sec/< 1 sec 859.4 MiB
       
      Result cache is saved.
       ------ ----------------------------------------
        Line   admin/tool/dataprivacy/classes/api.php
       ------ ----------------------------------------
        375    Cannot use [] for reading.
        454    Cannot use [] for reading.
       ------ ----------------------------------------
       
       ------ ------------------------------------------------------------------------------------------------------------------
        Line   calendar/lib.php
       ------ ------------------------------------------------------------------------------------------------------------------
        4027   Function calendar_inplace_editable() should return core\output\inplace_editable but return statement is missing.
       ------ ------------------------------------------------------------------------------------------------------------------
       
       ------ ----------------------------------------------------------------------------------
        Line   lib/behat/features/bootstrap/behat_init_context.php
       ------ ----------------------------------------------------------------------------------
        43     Class behat_init_context extends unknown class Behat\Behat\Context\BehatContext.
               💡 Learn more at https://phpstan.org/user-guide/discovering-symbols
       ------ ----------------------------------------------------------------------------------
       
       ------ --------------------------------------------------------------------------------------------------------------------
        Line   lib/ddl/sqlite_sql_generator.php
       ------ --------------------------------------------------------------------------------------------------------------------
        33     Non-abstract class sqlite_sql_generator contains abstract method getCreateTempTableSQL() from class sql_generator.
       ------ --------------------------------------------------------------------------------------------------------------------
       
       ------ ------------------------------------------------
        Line   mod/bigbluebuttonbn/classes/form/guest_add.php
       ------ ------------------------------------------------
        92     Cannot use [] for reading.
       ------ ------------------------------------------------
       
       ------ ---------------------------------------------------------------------------------------
        Line   mod/h5pactivity/lib.php
       ------ ---------------------------------------------------------------------------------------
        472    Function h5pactivity_pluginfile() should return bool but return statement is missing.
       ------ ---------------------------------------------------------------------------------------
       
       ------ ---------------------------------------------------------------------------------------------------------------------------
        Line   question/bank/managecategories/classes/question_category_object.php
       ------ ---------------------------------------------------------------------------------------------------------------------------
        391    Method qbank_managecategories\question_category_object::add_category() should return int but return statement is missing.
       ------ ---------------------------------------------------------------------------------------------------------------------------
       
       ------ --------------------------------------------------------------------------------------------------------------------------------
        Line   question/bank/viewquestionname/lib.php
       ------ --------------------------------------------------------------------------------------------------------------------------------
        35     Function qbank_viewquestionname_inplace_editable() should return core\output\inplace_editable but return statement is missing.
       ------ --------------------------------------------------------------------------------------------------------------------------------
       
       -- ----------------------------------------------------------------------------------------------------------
           Error
       -- ----------------------------------------------------------------------------------------------------------
           Ignored error pattern #Method .*\(\) has no return type specified\.# was not matched in reported errors.
       -- ----------------------------------------------------------------------------------------------------------
       
       [ERROR] Found 10 errors
       
      Used memory: 1.07 GB
      

      Attachments

        Issue Links

          Activity

            People

              dobedobedoh Andrew Lyons
              dobedobedoh Andrew Lyons
              Adrian Greeve, David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: