Problem/Motivation

Under php 7.4, dangling comma throws a parse error: ParseError: syntax error, unexpected ')', expecting variable (T_VARIABLE) in /var/www/html/web/modules/contrib/scheduler/src/SchedulerPluginManager.php on line 33

Steps to reproduce

My case is core 9.5.11, php 7.4.

Issue fork scheduler-3454508

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

    Comments

    kazajhodo created an issue. See original summary.

    kazajhodo’s picture

    This can be deleted, duplicate of #3442310. Not sure why I'm still having the issue when I pull 2.0.3.

    jonathan1055’s picture

    Yes I removed the new trailing comma in the second set of commits on #3442310-9: Fix new PHPCS standard for multi-line function definitions, for both 2.x and 8.x-1.x

    However, from https://git.drupalcode.org/project/scheduler/-/commits/2.x?ref_type=heads we see that the addition of the comma was done on 21 April, 2.0.3 was released on 28 April, then the reversal was on 4 May, after 2.0.3 was released.

    Maybe I need to release 2.0.4 to keep the module compatible with PHP7.4?

    jpdippenaar’s picture

    If you could please release 2.0.4 with this update.

    I am having issues on PHP7.4 / D8.9.20 We are in the process of upgrading D8 to D10 (yes I know) - but part of the process is to make sure the current modules work with our new composer workflow so when the current version gets installed on the server it breaks.

    jonathan1055’s picture

    Title: syntax error, unexpected ')', expecting variable (T_VARIABLE) » Syntax error, unexpected ')', expecting variable (T_VARIABLE)
    Issue summary: View changes
    Status: Active » Fixed

    I have just tagged and released 2.0.4 - thank you for the reminder.

    https://www.drupal.org/project/scheduler/releases/2.0.4

    Status: Fixed » Closed (fixed)

    Automatically closed - issue fixed for 2 weeks with no activity.