Repository navigation
Audit fixes (2026-09) - #3
Merged
Merged
Conversation
…ormance - doSave() now records each key whose set() returned false and returns the list of failed ids (AbstractAdapter::doSave contract), instead of always returning true and masking OOM-dropped writes as success. - SapiKvOps::incrBy() no longer does `(int) false === 0`: it detects the SAPI's false return (stored value is not an integer) and throws, per the KvOpsInterface::incrBy contract. - Add EphpmKvAdapterIntegrationTest wiring the adapter (over InMemoryKvOps) into Symfony's shared AdapterTestCase/CachePoolTest suite, with documented $skippedTests for genuinely unsupported features (prefix clear / SCAN, NamespacedPoolInterface) and assert()-gated key validation. - Tests for both behavior fixes (doSave failure collection via FailingSetKvOps; SapiKvOps incrBy throw via stubbed ephpm_kv_* globals). - README: current release v0.8.6 -> v0.10.2 (min-ePHPm floor language kept).
|
ePHPm Preview — removed Preview deployment has been torn down. |
…its Tests/) The AdapterTestCase base class lives under Symfony\Component\Cache\Tests\, which is export-ignored from the symfony/cache dist tarball, so under CI's composer install --prefer-dist it is not autoloadable and PHPUnit fatals with "Class ... AdapterTestCase not found" at class-declaration time (before any skip logic can run). Forcing a prefer-source install is fragile across symfony/cache 6.4 vs 7.x, so drop the optional conformance harness and keep the package's own passing unit tests. The real audit fixes (doSave failure-id collection and SapiKvOps::incrBy throwing on a non-integer) and their regression tests are unchanged. Also removes the now-unused cache/integration-tests dev dependency, the Symfony\Component\Cache\Tests\ autoload-dev map, the preferred-install source pin, and the assertions-enabling test script that only the harness needed.
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Audited KV/cache fixes for cache-symfony. Adopts
ephpm_kv_setnxwhere it was missing (atomicadd()/NX/locks), stops reporting OOM writes as success, fixes theincrByfalse->0 cast across the copied KvOps, and refreshes docs/CI. Every behavioral change has a test (agent ran the suite green in WSL PHP 8.5).