-
Notifications
You must be signed in to change notification settings - Fork 699
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
mvc: Phalcon framework dependency #6389
Comments
AdSchellevis
added a commit
that referenced
this issue
Jan 9, 2024
AdSchellevis
added a commit
that referenced
this issue
Feb 13, 2024
Add simple Message class and remove "Messages" dependancy in Validation.php, which should be backwards compatible with all existing validations. By moving \Phalcon\Filter\Validation() into validate() we're making the validation paths more explicit, if an objects implements ValidatorInterface, it uses phalcon, otherwise it's a simple BaseValidator passing messages back to $this->appendMessage(). The original phalcon Message class has additional fields we don't use, we only use fieldname for tracking purposes and the message itself.
AdSchellevis
added a commit
that referenced
this issue
Feb 13, 2024
AdSchellevis
added a commit
that referenced
this issue
Feb 13, 2024
fix regression in c2ea9aa and amend unit tests.
swhite2
added a commit
that referenced
this issue
Feb 14, 2024
Properties should be copied 1-to-1 before we apply the required defaults if necessary. In the previous situation this caused required properties to be set to an empty value after the default value had already been written to it. In the failure case we attempt to be a bit more explicit and refer to the crash reporter. While here, the master branch has dropped the Phalcon Messages class, so switch to count() since this seems to inherit array type and is therefore backwards compatible: $msgs = new \Phalcon\Messages\Messages(); $count = count($msgs); // $count == 0 See #6389
fichtner
pushed a commit
that referenced
this issue
Feb 15, 2024
Properties should be copied 1-to-1 before we apply the required defaults if necessary. In the previous situation this caused required properties to be set to an empty value after the default value had already been written to it. In the failure case we attempt to be a bit more explicit and refer to the crash reporter. While here, the master branch has dropped the Phalcon Messages class, so switch to count() since this seems to inherit array type and is therefore backwards compatible: $msgs = new \Phalcon\Messages\Messages(); $count = count($msgs); // $count == 0 See #6389 (cherry picked from commit fdc8a8f) (cherry picked from commit 3cb2f3d)
AdSchellevis
added a commit
that referenced
this issue
Feb 15, 2024
AdSchellevis
added a commit
that referenced
this issue
Feb 15, 2024
…for backwards compatible OPNsense\Base\Messages\Message class. for #6389
AdSchellevis
added a commit
that referenced
this issue
Feb 18, 2024
Fix regression in c2ea9aa, performValidation() should return an object which is able to add new messages (using appendMessage()) as the previous Messages class did.
fichtner
pushed a commit
that referenced
this issue
Mar 12, 2024
fichtner
pushed a commit
that referenced
this issue
Mar 12, 2024
Add simple Message class and remove "Messages" dependancy in Validation.php, which should be backwards compatible with all existing validations. By moving \Phalcon\Filter\Validation() into validate() we're making the validation paths more explicit, if an objects implements ValidatorInterface, it uses phalcon, otherwise it's a simple BaseValidator passing messages back to $this->appendMessage(). The original phalcon Message class has additional fields we don't use, we only use fieldname for tracking purposes and the message itself.
fichtner
pushed a commit
that referenced
this issue
Mar 12, 2024
fichtner
pushed a commit
that referenced
this issue
Mar 12, 2024
fix regression in c2ea9aa and amend unit tests.
fichtner
pushed a commit
that referenced
this issue
Mar 12, 2024
Properties should be copied 1-to-1 before we apply the required defaults if necessary. In the previous situation this caused required properties to be set to an empty value after the default value had already been written to it. In the failure case we attempt to be a bit more explicit and refer to the crash reporter. While here, the master branch has dropped the Phalcon Messages class, so switch to count() since this seems to inherit array type and is therefore backwards compatible: $msgs = new \Phalcon\Messages\Messages(); $count = count($msgs); // $count == 0 See #6389
fichtner
pushed a commit
that referenced
this issue
Mar 12, 2024
fichtner
pushed a commit
that referenced
this issue
Mar 12, 2024
…for backwards compatible OPNsense\Base\Messages\Message class. for #6389
fichtner
pushed a commit
that referenced
this issue
Mar 12, 2024
Fix regression in c2ea9aa, performValidation() should return an object which is able to add new messages (using appendMessage()) as the previous Messages class did.
AdSchellevis
added a commit
that referenced
this issue
Apr 30, 2024
…e to offer multiple model paths in the phalcon configuration, in practice this was never used (all models live in /usr/local/opnsense/mvc/app/models). for #6389
AdSchellevis
added a commit
that referenced
this issue
Apr 30, 2024
…e to offer multiple model paths in the phalcon configuration, in practice this was never used (all models live in /usr/local/opnsense/mvc/app/models). for #6389
AdSchellevis
added a commit
that referenced
this issue
Apr 30, 2024
…nse\Core\AppConfig class. for #6389
AdSchellevis
added a commit
that referenced
this issue
May 6, 2024
AdSchellevis
added a commit
that referenced
this issue
May 6, 2024
AdSchellevis
added a commit
that referenced
this issue
May 6, 2024
AdSchellevis
added a commit
that referenced
this issue
May 6, 2024
AdSchellevis
added a commit
that referenced
this issue
May 7, 2024
The original intend was to be able to reuse the Csrf class, but as this requires direct access to the session object, it's likely not a good idea for the goals of #6389 Since the legacy pages need a lock on session anyway, keeping it doesn't make a difference.
AdSchellevis
added a commit
that referenced
this issue
May 7, 2024
AdSchellevis
added a commit
that referenced
this issue
May 7, 2024
AdSchellevis
added a commit
that referenced
this issue
May 7, 2024
AdSchellevis
added a commit
that referenced
this issue
May 7, 2024
AdSchellevis
added a commit
that referenced
this issue
May 8, 2024
AdSchellevis
added a commit
that referenced
this issue
May 8, 2024
AdSchellevis
added a commit
that referenced
this issue
May 11, 2024
AdSchellevis
added a commit
that referenced
this issue
May 11, 2024
AdSchellevis
added a commit
that referenced
this issue
May 11, 2024
AdSchellevis
added a commit
that referenced
this issue
May 11, 2024
AdSchellevis
added a commit
that referenced
this issue
May 11, 2024
AdSchellevis
added a commit
that referenced
this issue
May 12, 2024
AdSchellevis
added a commit
that referenced
this issue
May 12, 2024
…sses with a routing class of our own. (#6389) This removes most phalcon code currently being used on our end, except the Volt templates (which are re-wrapped) and a translation class we can easisly replace later in a separate commit. Consumers of our controller classes shouldn't notice a difference as the used objects and methods are named the same. The most notable changes are the following ones: * Exceptions about not being able to find a requested path now break down into different exceptions inheriting from DispatchException, which makes it easier from the entrypoint (api.php, index.php) to catch and handle accordingly. * When not in development mode, raw exceptions are not being returned anymore, which increases security * The Dispatcher class is reponsible for object construction and mapping validation (valid uri, but no object found) * The Router class replaces previous Application class, it disects offered uri's into namespaces, classnames and methods to call.
AdSchellevis
added a commit
that referenced
this issue
May 12, 2024
This removes most phalcon code currently being used on our end, except the Volt templates (which are re-wrapped) and a translation class we can easily replace later in a separate commit. Consumers of our controller classes shouldn't notice a difference as the used objects and methods are named the same. The most notable changes are the following ones: * Exceptions about not being able to find a requested path now break down into different exceptions inheriting from DispatchException, which makes it easier from the entrypoint (api.php, index.php) to catch and handle accordingly. * When not in development mode, raw exceptions are not being returned anymore, which increases security * The Dispatcher class is reponsible for object construction and mapping validation (valid uri, but no object found) * The Router class replaces previous Application class, it disects offered uri's into namespaces, classnames and methods to call. In the long run there should be a seperate controller for controllers using volt templates or api calls, but as the existing ones don't distinct between this and the output handling is different now, we can park this for a later moment in time (the performance penalty should be rather low). Some unused functionality has been removed, for example support for the X-HTTP-Method-Override header in Request->getMethod() (see https://github.com/phalcon/cphalcon/blob/44243c07658d060cd8a21761743b0f4fc01641aa/phalcon/Http/Request.zep#L599-L609).
AdSchellevis
added a commit
that referenced
this issue
May 12, 2024
This removes most phalcon code currently being used on our end, except the Volt templates (which are re-wrapped) and a translation class we can easily replace later in a separate commit. Consumers of our controller classes shouldn't notice a difference as the used objects and methods are named the same. The most notable changes are the following ones: * Exceptions about not being able to find a requested path now break down into different exceptions inheriting from DispatchException, which makes it easier from the entrypoint (api.php, index.php) to catch and handle accordingly. * When not in development mode, raw exceptions are not being returned anymore, which increases security * The Dispatcher class is reponsible for object construction and mapping validation (valid uri, but no object found) * The Router class replaces previous Application class, it disects offered uri's into namespaces, classnames and methods to call. In the long run there should be a seperate controller for controllers using volt templates or api calls, but as the existing ones don't distinct between this and the output handling is different now, we can park this for a later moment in time (the performance penalty should be rather low). Some unused functionality has been removed, for example support for the X-HTTP-Method-Override header in Request->getMethod() (see https://github.com/phalcon/cphalcon/blob/44243c07658d060cd8a21761743b0f4fc01641aa/phalcon/Http/Request.zep#L599-L609).
AdSchellevis
added a commit
that referenced
this issue
May 13, 2024
This removes most phalcon code currently being used on our end, except the Volt templates (which are re-wrapped) and a translation class we can easily replace later in a separate commit. Consumers of our controller classes shouldn't notice a difference as the used objects and methods are named the same. The most notable changes are the following ones: * Exceptions about not being able to find a requested path now break down into different exceptions inheriting from DispatchException, which makes it easier from the entrypoint (api.php, index.php) to catch and handle accordingly. * When not in development mode, raw exceptions are not being returned anymore, which increases security * The Dispatcher class is reponsible for object construction and mapping validation (valid uri, but no object found) * The Router class replaces previous Application class, it disects offered uri's into namespaces, classnames and methods to call. In the long run there should be a seperate controller for controllers using volt templates or api calls, but as the existing ones don't distinct between this and the output handling is different now, we can park this for a later moment in time (the performance penalty should be rather low). Some unused functionality has been removed, for example support for the X-HTTP-Method-Override header in Request->getMethod() (see https://github.com/phalcon/cphalcon/blob/44243c07658d060cd8a21761743b0f4fc01641aa/phalcon/Http/Request.zep#L599-L609).
AdSchellevis
added a commit
that referenced
this issue
May 13, 2024
This removes most phalcon code currently being used on our end, except the Volt templates (which are re-wrapped) and a translation class we can easily replace later in a separate commit. Consumers of our controller classes shouldn't notice a difference as the used objects and methods are named the same. The most notable changes are the following ones: * Exceptions about not being able to find a requested path now break down into different exceptions inheriting from DispatchException, which makes it easier from the entrypoint (api.php, index.php) to catch and handle accordingly. * When not in development mode, raw exceptions are not being returned anymore, which increases security * The Dispatcher class is reponsible for object construction and mapping validation (valid uri, but no object found) * The Router class replaces previous Application class, it disects offered uri's into namespaces, classnames and methods to call. In the long run there should be a seperate controller for controllers using volt templates or api calls, but as the existing ones don't distinct between this and the output handling is different now, we can park this for a later moment in time (the performance penalty should be rather low). Some unused functionality has been removed, for example support for the X-HTTP-Method-Override header in Request->getMethod() (see https://github.com/phalcon/cphalcon/blob/44243c07658d060cd8a21761743b0f4fc01641aa/phalcon/Http/Request.zep#L599-L609).
fichtner
pushed a commit
that referenced
this issue
May 13, 2024
This removes most phalcon code currently being used on our end, except the Volt templates (which are re-wrapped) and a translation class we can easily replace later in a separate commit. Consumers of our controller classes shouldn't notice a difference as the used objects and methods are named the same. The most notable changes are the following ones: * Exceptions about not being able to find a requested path now break down into different exceptions inheriting from DispatchException, which makes it easier from the entrypoint (api.php, index.php) to catch and handle accordingly. * When not in development mode, raw exceptions are not being returned anymore, which increases security * The Dispatcher class is reponsible for object construction and mapping validation (valid uri, but no object found) * The Router class replaces previous Application class, it disects offered uri's into namespaces, classnames and methods to call. In the long run there should be a seperate controller for controllers using volt templates or api calls, but as the existing ones don't distinct between this and the output handling is different now, we can park this for a later moment in time (the performance penalty should be rather low). Some unused functionality has been removed, for example support for the X-HTTP-Method-Override header in Request->getMethod() (see https://github.com/phalcon/cphalcon/blob/44243c07658d060cd8a21761743b0f4fc01641aa/phalcon/Http/Request.zep#L599-L609).
AdSchellevis
added a commit
that referenced
this issue
May 13, 2024
AdSchellevis
added a commit
that referenced
this issue
May 21, 2024
…uments returned $_POST previsouly. (same likely the case for get())
AdSchellevis
added a commit
that referenced
this issue
May 21, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Important notices
Before you add a new report, we ask you kindly to acknowledge the following:
Is your feature request related to a problem? Please describe.
Given the state of Phalcon, it’s probably a good idea to start planning for losing more dependencies on the framework.
Describe the solution you like
A good start would probably be to start with our model implementation, which seems to depend on the following classes for which we should build native php alternatives in that case:
Phalcon\Filter\Validation\Validator\EmailPhalcon\Filter\Validation\Validator\ExclusionInPhalcon\Filter\Validation\Validator\InclusionInPhalcon\Filter\Validation\Validator\NumericalityPhalcon\Filter\Validation\Validator\PresenceOfPhalcon\Filter\Validation\Validator\RegexPhalcon\Filter\Validation\Validator\UrlOPNsense\Phalcon\Logger\LoggerPhalcon\Filter\Validation\ExceptionPhalcon\Logger\Adapter\SyslogPhalcon\Messages\MessagePhalcon\Messages\MessagesPhalcon\Config\ConfigDescribe alternatives you considered
N/A
Additional context
N/A
The text was updated successfully, but these errors were encountered: