Skip to content

Commit 5e47114

Browse files
authored
Add support for PHP versions up to 8.4 (#160)
1 parent 30779ed commit 5e47114

File tree

7 files changed

+42
-16
lines changed

7 files changed

+42
-16
lines changed

.github/workflows/pr.yml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ on:
77

88
jobs:
99
run:
10+
name: PHP ${{ matrix.php-versions }} (Redis ${{ matrix.redis-versions }})
1011
runs-on: ubuntu-latest
1112
container: shivammathur/node
1213
services:
@@ -19,13 +20,14 @@ jobs:
1920
--health-timeout 5s
2021
--health-retries 5
2122
strategy:
23+
fail-fast: false
2224
matrix:
23-
php-versions: ['7.1', '7.2', '7.3', '7.4', '8.0', '8.1', '8.2']
25+
php-versions: ['7.1', '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3', '8.4']
2426
redis-versions: ['5', '6', '7']
25-
name: PHP ${{ matrix.php-versions }} (Redis ${{ matrix.redis-versions }})
27+
2628
steps:
2729
- name: Checkout
28-
uses: actions/checkout@v2
30+
uses: actions/checkout@v4
2931

3032
- name: Setup PHP
3133
uses: shivammathur/setup-php@v2
@@ -35,10 +37,10 @@ jobs:
3537

3638
- name: Get composer cache directory
3739
id: composercache
38-
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
40+
run: echo "dir=$(composer config cache-files-dir)" >> "$GITHUB_OUTPUT"
3941

4042
- name: Cache dependencies
41-
uses: actions/cache@v2
43+
uses: actions/cache@v4
4244
with:
4345
path: ${{ steps.composercache.outputs.dir }}
4446
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,14 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
66

77
## [Unreleased]
88

9+
## [3.23.0] - 2025-06-10
10+
### Changes
11+
- PHP 8.3, 8.4 support
12+
- Laravel 12 support
13+
- Add `monolog/monolog` 3.0 support
14+
- Add `predis/predis` 2.0 support
15+
- Use `DateTime()` instead of deprecated `strftime`
16+
917
## [3.22.0] - 2023-02-24
1018
### Changes
1119
- PHP 8.2 support

LICENSE.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2018-2019 PDFfiller
3+
Copyright (c) 2018-2025 PDFfiller
44
Copyright (c) 2013-2015 Ryver, Inc
55

66
Permission is hereby granted, free of charge, to any person obtaining a copy

README.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
# qless-php
22

3-
[![PHP Version](https://img.shields.io/badge/supported->%3D7.1%20<8.2-blue?logo=php)](https://php.net/)
3+
[![PHP Version](https://img.shields.io/badge/supported->%3D7.1%20<=8.4-blue?logo=php)](https://php.net/)
44
[![Workflow Status](https://github.com/pdffiller/qless-php/actions/workflows/pr.yml/badge.svg)](https://github.com/pdffiller/qless-php/actions/workflows/pr.yml)
5-
[![Infection MSI](https://badge.stryker-mutator.io/github.com/pdffiller/qless-php/master)](https://infection.github.io)
65

76
PHP Bindings for qless.
87

@@ -947,7 +946,7 @@ qless-php is open-sourced software licensed under the MIT License.
947946
See the [`LICENSE.txt`](https://github.com/pdffiller/qless-php/blob/master/LICENSE.txt) file for more.
948947

949948

950-
© 2018-2022 PDFfiller<br>
949+
© 2018-2025 PDFfiller<br>
951950
© 2013-2015 Ryver, Inc <br>
952951

953952
All rights reserved.

composer.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,15 @@
2424
}
2525
],
2626
"require": {
27-
"php": ">=7.1 < 8.3",
27+
"php": "^7.1 || ^8.0",
2828
"ext-json": "*",
2929
"ext-pcntl": "*",
3030
"ext-pcre": "*",
3131
"ext-posix": "*",
3232
"ext-sockets": "*",
33-
"monolog/monolog": "^1.23 || ^2.0",
34-
"predis/predis": "^1.1.10",
33+
"ext-intl": "*",
34+
"monolog/monolog": "^1.23 || ^2.0 || ^3.0",
35+
"predis/predis": "^1.1.10 || ^2.0",
3536
"psr/log": "^1 || ^2 || ^3",
3637
"ramsey/uuid": "^3.7 || ^4",
3738
"seld/signal-handler": "1.1.*"

src/Workers/ForkingWorker.php

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,13 @@ protected function performWork(BaseJob $job): void
9090
$this->childStart();
9191
$this->watchdogStart($this->client->createSubscriber(['ql:log']));
9292

93-
$this->title(sprintf('Forked %d at %s', $this->childPID, strftime('%F %T')));
93+
$this->title(
94+
sprintf(
95+
'Forked %d at %s',
96+
$this->childPID,
97+
(new \DateTime())->format('Y-m-d H:i:s')
98+
)
99+
);
94100

95101
// Parent process, sit and wait
96102
while ($this->childProcesses > 0) {
@@ -340,7 +346,7 @@ private function childStart(): void
340346
$this->who = 'child:' . $this->name;
341347
$this->logContext = ['type' => $this->who];
342348

343-
$this->title('Processing ' . $jid . ' since ' . strftime('%F %T'));
349+
$this->title('Processing ' . $jid . ' since ' . (new \DateTime())->format('Y-m-d H:i:s'));
344350
$this->childPerform($this->job);
345351

346352
socket_close($socket);
@@ -453,7 +459,13 @@ private function watchdogStart(WatchdogSubscriber $subscriber): void
453459
$this->who = 'watchdog:' . $this->name;
454460
$this->logContext = ['type' => $this->who];
455461

456-
$this->title(sprintf('Watching events for %s since %s', $this->job->jid, strftime('%F %T')));
462+
$this->title(
463+
sprintf(
464+
'Watching events for %s since %s',
465+
$this->job->jid,
466+
(new \DateTime())->format('Y-m-d H:i:s')
467+
)
468+
);
457469
$subscriber->watchdog($this->job->jid, $this->name, $this->childPID);
458470

459471
socket_close($socket);

src/Workers/SimpleWorker.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,11 @@ public function setLogger(LoggerInterface $logger): void
4444
*/
4545
protected function performWork(BaseJob $job): void
4646
{
47-
$this->title(sprintf('Processing %s since %s', $job->jid, strftime('%F %T')));
47+
$this->title(sprintf(
48+
'Processing %s since %s',
49+
$job->jid,
50+
(new \DateTime())->format('Y-m-d H:i:s')
51+
));
4852

4953
try {
5054
$this->performJob($job, $this->logContext);

0 commit comments

Comments
 (0)