Skip to content

Exception - Class "PHP_CodeSniffer\Util\MessageCollector" not found #245

@RussellEngland

Description

@RussellEngland

Just pulled v5.0.9 and get this error :(

Same for Moodle 4.5.5+, 5.0.1+ and 5.1dev

Exception - Class "PHP_CodeSniffer\Util\MessageCollector" not found

[More information about this error](https://docs.moodle.org/500/en/error/moodle/generalexceptionmessage)

Debug info:
Error code: generalexceptionmessageDismiss this notification
Stack trace:
line 164 of /local/codechecker/vendor/squizlabs/php_codesniffer/src/Ruleset.php: Error thrown
line 348 of /local/codechecker/vendor/squizlabs/php_codesniffer/src/Runner.php: call to PHP_CodeSniffer\Ruleset->__construct()
line 119 of /local/codechecker/classes/runner.php: call to PHP_CodeSniffer\Runner->init()
line 131 of /local/codechecker/classes/runner.php: call to local_codechecker\runner->init()
line 106 of /local/codechecker/index.php: call to local_codechecker\runner->run()

Steps to reproduce

  1. Update codechecker to v5.0.9
  2. Upgrade Moodle
  3. Go to Site admin > Development > Code checker
  4. Enter local/codechecker

Workaround - revert to 5.0.8

  1. cd local/codechecker
  2. git checkout v5.0.8
  3. uninstall codechecker php admin/cli/uninstall_plugins.php --plugins=local_codechecker --run
  4. Upgrade moodle php admin/cli/upgrade.php

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions