5.14.0 (2026-06-04)
Tools
- Zephir Parser v2.0.2
- Zephir 0.22.0 (development - 9d2def774)
Changed
- Alignment with v6; docblocks; sorting; return types; minor fixes (image watermark opacity calc, serializer/helpers, readonly-becoming-mutable, ACL local access). #17055
- Changed return types to
-> <static>or-> <self>in various components. The change is a covariant narrowing on implementation methods and does not touch any interface contracts, so userland classes that implement Phalcon interfaces and return the interface type continue to work unchanged. #17035 - Internal performance work across
Autoload,Dispatcher,Annotations,Db,Mvc\Model,Mvc\Model\Query,Tag,Assets,Acl\Adapter\Memory,Http\Request,Encryption\Crypt. Behavior preserved. #17049 - Moved CI tools/scripts in
resources/removed unused ones #17066 - Moved docker in
resources/#17066 - Refactored docker images (more flexible less cruft) #17066
- Reorganization of quality tool config files (in
resources/) #17066 Phalcon\Autoload\Loadergetters (getDirectories,getExtensions,getFiles) return arrays keyed by the value string instead of by a SHA256 hash of it; iteration order and contents are unchanged. #17049 [doc]Phalcon\Mvc\Router::handle()internal optimizations: O(1) hash lookup for literal-URI routes; per-HTTP-method buckets; hot-loop reads; PCRE patterns chunked; per-route metadata cache deduplicated by route id. #17012 [doc]Phalcon\Mvc\Router\Route::getCompiledHostName()now uses cache for hostname/converters. #17012 [doc]
Added
- Added a new dependency-injection container under
Phalcon\Container, with its contracts underPhalcon\Contracts\Container. It adds:Phalcon\Container\Container/Phalcon\Container\ContainerFactory- the container and its factory, configured throughPhalcon\Contracts\Container\Service\Providerproviders (Phalcon\Container\Provider\Web,Phalcon\Container\Provider\Cli).Phalcon\Container\Definition\ServiceDefinition- fluent service definitions with autowiring, factories, extenders, tags, aliases, and configurable service lifetimes (Phalcon\Container\Definition\ServiceLifetime).Phalcon\Container\Resolver\Resolver- reflection-based constructor / method / parameter autowiring, plus thePhalcon\Container\Resolver\Lazy\*family for lazy resolution (Get,GetCall,NewInstance,Call,Env,CsEnv,ArrayValues, etc.).Phalcon\Container\Exceptions\*- granular, per-cause exceptions (ServiceNotFound,CircularAliasFound,FrozenDefinition,CannotResolveParameter,NoProcessorFound, etc.). #16897 [doc]
- Added a new authentication and authorization layer under
Phalcon\Auth, with its contracts underPhalcon\Contracts\Auth. Built on top ofPhalcon\Container, it adds:Phalcon\Auth\Manager/Phalcon\Auth\ManagerFactory- the central manager that wires guards and access gates together, and its factory.Phalcon\Auth\AuthUser- a lightweight user value object returned by array-backed adapters when no application model class is configured.- Guards under
Phalcon\Auth\Guard-SessionandToken(withAbstractGuardandUserRemember), resolved viaPhalcon\Auth\Guard\GuardLocatorand configured throughPhalcon\Auth\Guard\Config\*(AbstractGuardConfig,SessionGuardConfig,TokenGuardConfig). - Adapters under
Phalcon\Auth\Adapter-Memory,Model, andStreamuser providers (withAbstractAdapterandAbstractArrayAdapter), resolved viaPhalcon\Auth\Adapter\AdapterLocatorand configured throughPhalcon\Auth\Adapter\Config\*(AbstractAdapterConfig,MemoryAdapterConfig,ModelAdapterConfig,StreamAdapterConfig). - Access gates under
Phalcon\Auth\Access-AuthandGuest(withAbstractAccess), resolved viaPhalcon\Auth\Access\AccessLocator. - Dispatcher listeners
Phalcon\Auth\Mvc\AuthDispatcherListenerandPhalcon\Auth\Cli\AuthDispatcherListener(withPhalcon\Auth\AbstractAuthDispatcherListener) to guard MVC and CLI dispatch. Phalcon\Auth\Exceptionplus granularPhalcon\Auth\Exceptions\*(AccessDenied,ConfigRequiresNonEmptyValue,DataMustContainIdKey,DoesNotImplement,FileCannotRead,FileDoesNotContainJson,FileDoesNotExist,FileNotValidJson).- Contracts under
Phalcon\Contracts\Auth-Manager,AuthUser,AuthRemember,RememberToken,Access\Access,Adapter\Adapter,Adapter\AdapterConfig,Adapter\RememberAdapter,Guard\Guard,Guard\GuardConfig,Guard\GuardStateful,Guard\BasicAuth. Phalcon\Support\AbstractLocator- the shared service-locator base extended by the guard, adapter, and access locators. #16273 [doc]
- Added granular exception classes across the framework. Every namespace that previously surfaced failures through a single umbrella
Phalcon\<Namespace>\Exception(or its sub-namespace counterpart) now ships per-cause classes under a siblingExceptions/folder. Each new class extends the existing per-namespace parent socatch (Phalcon\<Namespace>\Exception $e)continues to work unchanged. New classes:Phalcon\Acl\ExceptionsAccessRuleNotFoundCircularInheritanceErrorElementNotFoundForbiddenWildcardInvalidAccessListInvalidComponentImplementationInvalidRoleImplementationInvalidRoleTypeMissingFunctionParametersParameterTypeMismatchRoleNotFoundException
Phalcon\Annotations\ExceptionsAnnotationNotFoundAnnotationsDirectoryNotWritableCannotReadAnnotationDataUnknownAnnotationExpression
Phalcon\Application\ExceptionsModuleNotRegistered
Phalcon\Assets\ExceptionsAssetSourceTargetCollisionCannotReadAssetCollectionNotFoundInvalidAssetSourcePathInvalidAssetTargetPathInvalidFilterInvalidTargetPathTargetPathIsDirectory
Phalcon\Autoload\ExceptionsLoaderDirectoriesNotArrayLoaderMethodNotCallable
Phalcon\Cache\ExceptionCacheKeysNotIterableInvalidCacheKey
Phalcon\Cli\Console\ExceptionsConsoleModuleNotRegisteredContainerRequiredInvalidModuleDefinitionPathModuleDefinitionPathNotFound
Phalcon\Cli\Router\ExceptionsBeforeMatchNotCallableInvalidRoutePathsRouterArgumentsInvalidType
Phalcon\Config\ExceptionsCannotLoadConfigFileConfigNotArrayOrObjectGroupedAdapterRequiresArrayInvalidMergeDataMissingConfigOptionMissingFileExtensionMissingYamlExtension
Phalcon\DataMapper\Pdo\ExceptionDriverNotSupportedUnknownDriverMethodUnknownQueryMethod
Phalcon\Db\ExceptionsCannotInsertWithoutDataCannotPrepareStatementCheckExpressionRequiredColumnTypeRejectsAutoIncrementColumnTypeRejectsScaleColumnTypeRequiredConflictTargetColumnRequiredConflictUpdateColumnRequiredForeignKeyColumnsRequiredGeneratedAutoIncrementConflictGeneratedDefaultConflictIncompleteBindTypesInvalidBindParameterInvalidCheckExpressionInvalidGenerationExpressionInvalidGroupByExpressionInvalidIndexColumnsInvalidIndexDirectionsInvalidIndexWhereInvalidListExpressionInvalidOrderByExpressionInvalidSqlExpressionInvalidSqlExpressionTypeInvalidUnaryExpressionInvalidWhereConditionsMatchedParameterNotFoundMaterializedViewsNotSupportedMissingDefinitionKeyMissingForeignKeyChecksMissingSqliteDatabaseMysqlOnConflictNotSupportedNestedTransactionChangeBlockedNoActiveTransactionReferencedColumnCountMismatchReferencedColumnsRequiredReferencedTableRequiredReturningNotSupportedReturningRequiresColumnSavepointsNotSupportedSqliteAlterCheckNotSupportedSqliteAlterColumnNotSupportedSqliteAlterForeignKeyNotSupportedSqliteAlterPrimaryKeyNotSupportedSqliteDropCheckNotSupportedSqliteDropForeignKeyNotSupportedSqliteDropPrimaryKeyNotSupportedTableMustHaveColumnUnrecognizedDataTypeUpdateFieldCountMismatch
Phalcon\Di\ExceptionsAliasAlreadyInUseAliasNameMustBeStringArgumentTypeRequiredCallArgumentsMustBeArrayCircularAliasReferenceContainerRequiredDefinitionMustBeArrayForReadDefinitionMustBeArrayForUpdateMethodCallMustBeArrayMethodNameRequiredMissingClassNameParameterMissingParameterKeyPropertyInjectionRequiresInstancePropertyMustBeArrayPropertyNameRequiredPropertyValueRequiredServiceCannotBeResolvedSetterInjectionRequiresInstanceSetterParametersMustBeArrayUnknownServiceType
Phalcon\Dispatcher\ExceptionsForwardInInitializeForbidden
Phalcon\Encryption\Crypt\ExceptionDecryptionFailedEmptyDecryptionKeyEmptyEncryptionKeyEncryptionFailedInvalidPaddingSizeIvLengthCalculationFailedMissingAuthDataMissingOpensslExtensionRandomBytesGenerationFailedUnsupportedAlgorithm
Phalcon\Encryption\Security\ExceptionsInvalidRandomInputUnknownHashAlgorithm
Phalcon\Encryption\Security\JWT\ExceptionsEmptyPassphraseInvalidAudienceInvalidAudienceTypeInvalidClaimsInvalidExpirationTimeInvalidHeaderInvalidNotBeforeMalformedJwtStringMissingJwtTypHeaderUnsupportedHmacAlgorithmWeakPassphrase
Phalcon\Events\ExceptionsEventNotCancelableInvalidEventHandlerInvalidEventSourceInvalidEventTypeInvalidSubscriberConfigurationNoListenersForEvent
Phalcon\Filter\ExceptionsFilterNotRegistered
Phalcon\Filter\Validation\ExceptionsFieldNotPrintableFilterServiceUnavailableInvalidAllowedTypesInvalidCallbackReturnInvalidDomainOptionInvalidFieldTypeInvalidFilterServiceInvalidStrictOptionInvalidValidationDataInvalidValidatorInvalidValidatorScopeMissingMbstringNoDataToValidateNoValidatorsNoValidatorsInCompositeUniquenessConversionMustBeArrayUniquenessModelRequiredUniquenessOnlyForPhalconModelValidationEntityNotObject
Phalcon\Flash\ExceptionsEscaperServiceUnavailableFlashMessageNotStringOrArraySessionServiceUnavailable
Phalcon\Forms\ExceptionsElementNotInFormFormElementNameRequiredFormNotInLocatorFormNotRegisteredInvalidEntityInvalidFilterTypeInvalidJsonSchemaJsonSchemaNotArrayNoFormElementsSchemaEntryMissingKeySchemaEntryNotArrayUnknownFormElementTypeYamlExtensionRequiredYamlSchemaNotArray
Phalcon\Html\ExceptionsAttributeNotRenderableFriendlyTitleConversionFailedInvalidResultsetValueServiceNotRegisteredUsingRequiresTwoValues
Phalcon\Http\Cookie\ExceptionsCookieKeyTooShortCryptInterfaceRequiredCryptServiceUnavailableFilterServiceUnavailable
Phalcon\Http\Request\ExceptionsFilterServiceUnavailableInvalidHostInvalidHttpMethodMissingFiltersSanitizerNotFound
Phalcon\Http\Response\ExceptionsNonStandardStatusCodeRequiresMessageResponseAlreadySentResponseServiceUnavailableUrlServiceUnavailable
Phalcon\Image\ExceptionsCompositeFailedExtensionNotLoadedImageLoadFailedMissingDimensionsMissingHeightMissingWidthResizeFailedResourceTypeErrorTextRenderingFailedUnsupportedImageTypeVersionMismatch
Phalcon\Logger\Adapter\ExceptionsFileOpenFailedInvalidStreamModeSyslogOpenFailed
Phalcon\Logger\ExceptionsAdapterNotFoundDeserializationFailedNoAdaptersConfiguredSerializationFailedTransactionAlreadyActiveTransactionNotActive
Phalcon\Messages\ExceptionsMessageNotObjectMessagesNotIterable
Phalcon\Mvc\Application\ExceptionsContainerRequiredInvalidModuleDefinitionModuleDefinitionPathNotFound
Phalcon\Mvc\Dispatcher\ExceptionsResponseServiceUnavailable
Phalcon\Mvc\Micro\ExceptionsContainerRequiredErrorHandlerNotCallableHandlerNotCallableInvalidRegisteredHandlerLazyHandlerNotFoundMissingCollectionMainHandlerNoHandlersToMountNoMatchedRouteHandlerNotFoundHandlerNotCallableResponseHandlerNotCallable
Phalcon\Mvc\Model\Behavior\ExceptionsMissingRequiredOption
Phalcon\Mvc\Model\ExceptionsBelongsToRequiresObjectBindTypeNotDefinedCannotResolveAttributeColumnNotInMapColumnNotInTableColumnsColumnNotInTableMapCorruptColumnTypeCursorIsImmutableDataTypeNotDefinedHandlerMustImplementBindableIdentityNotInColumnMapIdentityNotInTableColumnsIndexNotInCursorIndexNotInRowInvalidConnectionServiceInvalidContainerInvalidDumpResultKeyInvalidFindParametersInvalidGetModelNameReturnInvalidModelNameInvalidModelsManagerServiceInvalidModelsMetadataServiceInvalidResultsetCacheServiceInvalidReturnedRecordInvalidSerializationDataManagerOrmServicesUnavailableMethodNotFoundMissingMethodNameMissingModelClassNameModelCouldNotLoadModelOrmServicesUnavailablePrimaryKeyAttributeNotSetPrimaryKeyRequiredPropertyNotAccessibleRecordCannotRefreshRecordNotPersistedReferencedFieldsMismatchRelationAliasMustBeStringRelationNotDefinedRelationRequiresObjectOrArrayResultsetColumnNotInMapRowIsImmutableSnapshotsDisabledStaticMethodRequiresOneArgumentUnknownRelationTypeUpdateSnapshotDisabled
Phalcon\Mvc\Model\MetaData\ExceptionsCannotObtainTableColumnsColumnMapNotArrayContainerRequiredCorruptedMetaDataInvalidContainerInvalidMetaDataForModelMetaDataDirectoryNotWritableMetaDataStrategyFailedNoAnnotationsForClassNoPropertyAnnotationsForClassTableNotInDatabase
Phalcon\Mvc\Model\Query\ExceptionsAmbiguousColumnAmbiguousJoinRelationBindParameterNotInPlaceholdersBindTypeRequiresArrayBindValueRequiredColumnNotInDomainColumnNotInSelectedModelsCorruptedAstCorruptedDeleteAstCorruptedInsertAstCorruptedSelectAstCorruptedUpdateAstDeleteMultipleNotSupportedDuplicateAliasEmptyArrayPlaceholderValueInsertColumnCountMismatchInvalidCachedResultsetInvalidCachingOptionsInvalidColumnDefinitionInvalidInjectedManagerInvalidInjectedMetadataInvalidQueryCacheServiceInvalidResultsetClassJoinAliasAlreadyUsedJoinFieldCountMismatchMissingCacheKeyMissingMetaDataMissingModelAttributeMissingModelsManagerMixedDatabaseSystemsModelSourceNotFoundModelsListNotLoadedMultipleSqlStatementsNotSupportedNoModelForAliasPhqlColumnNotInMapReadConnectionMissingRelationshipNotFoundResultsetClassNotFoundResultsetNonCacheableUnknownBindTypeUnknownColumnTypeUnknownJoinTypeUnknownModelOrAliasUnknownPhqlExpressionUnknownPhqlExpressionTypeUnknownPhqlStatementUpdateMultipleNotSupportedWriteConnectionMissing
Phalcon\Mvc\Model\Query\Exceptions\BuilderBuilderColumnNotInMapBuilderConditionInvalidModelRequiredNoPrimaryKeyOperatorNotAvailable
Phalcon\Mvc\Router\ExceptionsAnnotationsServiceUnavailableBeforeMatchNotCallableConfigKeyMustBeArrayEmptyGroupOfRoutesGroupRoutesMustBeArrayInvalidCallbackParameterInvalidConfigSourceInvalidNotFoundPathsInvalidRoutePathsInvalidRoutePositionInvalidRouterFactoryConfigMissingGroupRouteKeyMissingRouteConfigKeyRequestServiceUnavailableUnknownHttpMethodWrongPathsKey
Phalcon\Mvc\Url\ExceptionsMissingRouteNameRouteNotFoundRouterServiceUnavailable
Phalcon\Mvc\View\Engine\Volt\ExceptionsCannotOpenCompiledFileCorruptedStatementCorruptedStatementWithDataInvalidCompilationPrefixInvalidExtensionInvalidHaystackInvalidIntermediateRepresentationInvalidOptionTypeInvalidPathClosureReturnInvalidPathTypeInvalidStatementInvalidUserFilterDefinitionInvalidUserFunctionDefinitionMacroAlreadyDefinedMacroNotFoundMbstringRequiredTemplateFileNotFoundTemplateFileNotOpenableTemplatePathCollisionUnknownVoltExpressionUnknownVoltFilterUnknownVoltFilterTypeUnknownVoltStatementVoltDirectoryNotWritable
Phalcon\Mvc\View\ExceptionsInvalidEngineRegistrationInvalidViewsDirTypeSimpleViewNotFoundSimpleViewServicesUnavailableViewNotFoundViewServicesUnavailableViewsDirItemMustBeString
Phalcon\Paginator\ExceptionsBuilderModelNotDefinedInvalidBuilderInstanceInvalidCursorColumnInvalidLimitMissingColumnsForHavingMissingRequiredParameterPaginatorDataNotArray
Phalcon\Session\Adapter\ExceptionsAdapterRuntimeErrorInvalidSavePathSavePathUnavailable
Phalcon\Session\ExceptionsInvalidSessionAdapterInvalidSessionNameSessionAlreadyStartedSessionModificationDenied
Phalcon\Storage\ExceptionsAuthenticationFailedClusterConnectionFailedConnectionFailedDatabaseSelectionFailedInvalidConfigurationStorageError
Phalcon\Storage\Serializer\ExceptionsInvalidSerializationInputInvalidUnserializationInput
Phalcon\Support\Collection\ExceptionsInvalidValueTypeReadOnlyViolation
Phalcon\Support\Debug\ExceptionsRequestHaltedRuntimeWarning
Phalcon\Support\Helper\Json\ExceptionsJsonDecodeErrorJsonEncodeError
Phalcon\Support\Helper\Str\ExceptionsInsufficientArgumentsInvalidReplaceFormatSyntaxError
Phalcon\Time\Clock\ExceptionsInvalidModifier
Phalcon\Translate\ExceptionsFileOpenErrorImmutableObjectInterpolatorNotRegisteredInvalidDataTypeKeyNotFoundMissingContentMissingGettextExtensionMissingRequiredParameterTranslatorNotRegistered#17019
- Added
Phalcon\Events\Manager::fire()beforeFire()/afterFire()extension seams toManager::fire(). #17065 [doc] - Added opt-in memory caps for long-running workers (Swoole / RoadRunner / queue consumers). Default
0preserves the original unbounded behavior: #17049Phalcon\Db\Profiler::setMaxProfiles(int)/getMaxProfiles()[doc]Phalcon\Logger\Adapter\AbstractAdapter::setQueueLimit(int)/getQueueLimit()[doc]Phalcon\Events\Manager::setMethodExistsCacheLimit(int)/getMethodExistsCacheLimit()[doc]Phalcon\Annotations\Adapter\AbstractAdapter::setAnnotationsLimit(int)/getAnnotationsLimit()[doc]Phalcon\Storage\Adapter\Memory::setMaxItems(int)/getMaxItems()[doc]
- Added
Phalcon\Mvc\Router\Route::setRouteId(string $routeId)- setter intended for restoring cached routes #17012 [doc] - Added
Phalcon\Mvc\Router::buildDispatcherDump()/Phalcon\Mvc\Router::loadDispatcherFromArray(array $dump)- used to build/load the routes #17012 [doc] - Added
Phalcon\Mvc\Router::dumpDispatcher(string $path)/Phalcon\Mvc\Router::loadDispatcher(string $path)- file-shaped helpers that write/read routes #17012 [doc] - Added
Phalcon\Mvc\Router::useCache()- to use aPhalcon\Cacheadapter to store routes #17012 [doc]
Fixed
- Fixed
$this->eventsManagerresolving tonullinsidePhalcon\Mvc\Controllermethods #17060 [doc] - Fixed
Phalcon\Events\EventandPhalcon\Events\Manager::fire()being declaredfinalin 5.13.0 (#17006), which prevented subclassing the events manager. #17065 [doc] - Fixed
Phalcon\Forms\Form::clear()leaving a previously-boundnullfield value in the data array instead of unsetting it before reassigning the element default #17042 [doc] - Fixed
Phalcon\Mvc\Model::getChangedFields()/hasChanged()flagging every null-valued column of a freshly-loaded row as changed #17042 [doc] - Fixed
Phalcon\Mvc\Model::getUpdatedFields()flagging unchanged null-valued columns as updated #17042 [doc] - Fixed
Phalcon\Mvc\Model\Row::offsetGet()/offsetExists()throwingThe index does not exist in the rowwhen accessing a column whose value isnull#17041 [doc] - Fixed
Phalcon\Mvc\Router::handle()falling back to a default catch-all route instead of matching an HTTP-method-constrained route attached afterward. #17062 [doc] - Fixed
Phalcon\Mvc\View::getContent()throwingTypeErrorafterView::start().start()was assigning$this->content = null#17041 [doc] - Fixed
Phalcon\Mvc\View\Engine\Volt\Compileremitting invalid PHP when a double-quoted Volt string contained literal single quotes (e.g."send_ga('Link', ...)"). Only un-escaped single quotes are now escaped, so the'Let\'s Encrypt'case from #17002 is preserved #17046 [doc] - Fixed warning in
Phalcon\Auth\ManagerFactoryemitted in tests (random commit but had to be fixed) #17066
Removed
- Removed unused
Phalcon\Contracts\Container\Service\Lifetime#17066 - Reverted the
Phalcon\Mvc\Model\Query::executeUpdate()named-placeholder substitution introduced for #16976. The substitution path was triggering a use-after-free in the model update flow under PostgreSQL (#17042). Issue #16976 is reopened and will be addressed with a different approach. [doc]