feat: Throw an error when trying to listen to no longer used signals#59489
Draft
CarlSchwan wants to merge 3 commits intomasterfrom
Draft
feat: Throw an error when trying to listen to no longer used signals#59489CarlSchwan wants to merge 3 commits intomasterfrom
CarlSchwan wants to merge 3 commits intomasterfrom
Conversation
come-nc
reviewed
Apr 7, 2026
lib/private/legacy/OC_Hook.php
Outdated
| * TODO: write example | ||
| */ | ||
| public static function connect($signalClass, $signalName, $slotClass, $slotName) { | ||
| static $debug = null; |
Contributor
There was a problem hiding this comment.
I would say even not on debug we should check, and log an error if not in the list.
Member
Author
There was a problem hiding this comment.
Currently throwing an error but this is mostly to see if tests are failing or not, I'll change it later to just login it as an error
lib/private/legacy/OC_Hook.php
Outdated
| [Filesystem::CLASSNAME, Filesystem::signal_pre_setup], | ||
| [Filesystem::CLASSNAME, Filesystem::signal_post_init_mountpoints], | ||
| [Filesystem::CLASSNAME, 'umount'], | ||
| ['\OCA\Files_Sharing\API\Server2Server', 'preLoginNameUsedAsUserName'], |
Contributor
There was a problem hiding this comment.
Should we add an ignore for \ at the beginning so that we can use ::class everywhere 🤔
Member
Author
There was a problem hiding this comment.
I think we should still thrown if it doesn't match exactly that is emitted
7eb9f6f to
22bd4d3
Compare
Signed-off-by: Carl Schwan <carlschwan@kde.org>
22bd4d3 to
cc6a8d4
Compare
Signed-off-by: Carl Schwan <carlschwan@kde.org>
Allow to use ::class as class names. Only works if the class actually exists, which in many case, isn't the case anymore. Signed-off-by: Carl Schwan <carlschwan@kde.org>
a333c8f to
707699d
Compare
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.
Summary
TODO
Checklist
3. to review, feature component)stable32)AI (if applicable)