We are very happy to announce the release of Phalcon v4.0.6, a maintenance release.
This release focused mostly on bug fixes reported by the community, as our testing suite and release tasks.
This will be the last version we release from the v4.0.x series. Our next version will be in the v4.1.x.
Finally, we worked a bit more on v4.1, adding more components as per our roadmap. The work was mostly focused on the Data Mapper implementation coming in later versions of v4. The bulk of the work being done in v4.1 comes from the NFR list that the community has voted on.
Huge thanks to our contributors that reported issues, offered input as well as submitted pull requests with additions and corrections!
NOTE: You can always check our roadmap and the status of our active sprint in our project page: https://github.com/orgs/phalcon/projects/4
Changed
- Changed
Volt::convertEncodingto no longer usingiconvfor a fallback since it causes issues with macOS #14912 - Changed schema manipulation in
Phalcon\Db\Dialect\Mysql- unquote numerical defaults #14888, #14974 - Changed the default ACL access level from boolean
FALSEtoEnum::DENY#14974 - Changed the way
Phalcon\Http\Response::__constructcheckscontentdata type. Now aTypeErrorwill be thrown if incompatible data type was passed #14983 - Changed return type hints of the following
Phalcon\Flash\FlashInterface’s methods:error,message,notice,successandwarning#14994 - Changed return type hint for
Phalcon\Mvc\ModelInterface::sum#15000 - Changed return type for
Phalcon\Mvc\Model\Criteria::getLimitso that integer, NULL or array will be returned #15004 - Changed return type hint for
Phalcon\Mvc\Model\Manager::getCustomEventsManagerto return NULL instead of boolean FALSE if there is no special events manager #15008 - Changed
Phalcon\Mvc\Model\MetaData::getDIso that now it will throw aPhalcon\Mvc\Model\Exceptionif there is noDiInterfaceinstance #15011 - Changed
Phalcon\Http\Request::getJsonRawBodyto usejson_decodeinstead ofPhalcon\Json::decode#14936 - Changed
Phalcon\Factory\AbstractFactoryto exposegetServicewhich will throw an exception if it does not exist. RemovedcheckServiceand adjusted all references innewInstance()calls. #15038 - Changed the visibility of methods and properties in
Phalcon\Http\Message\Response,Phalcon\Http\Message\ServerRequestandPhalcon\Http\Message\Urito work withclone. #15040
Fixed
- Fixed
Phalcon\Mvc\Model\Query\Builder::getPhqlto add single quote between string value on a simple condition #14874 - Fixed recognizing language operators inside Volt’s echo mode (
{{}}) #14476 - Fixed
Tag::friendlyTitleto correctly convert titles under MacOS and Windows #14866 - Fixed the Volt compiler to no longer parse
cachefragments and thus searching for theviewCacheservice (deprecated for v4) #14907 - Fixed
INoperator precedence in Volt #14816 - Fixed testing suite to work with PHPUnit 9 when we upgrade #14837
- Fixed return type hints of the following
Phalcon\Acl\AbstractAdapter’s methods:getActiveAccess,getActiveRoleandgetActiveComponent#14974 - Fixed default value of the following
Phalcon\Annotations\Annotation’s properties:$argumentsand$exprArguments#14977 - Fixed return type hints of the following
Phalcon\Annotations\Annotation’s methods:getArgument,getNameandgetNamedArgument#14977 - Fixed incorrect return type hint for
Phalcon\Http\Response\Cookies::setSignKey#14982 - Fixed return type hints for
Phalcon\Config\ConfigFactory::loadandPhalcon\Config\ConfigFactory::newInstanceto explicitly indicate the return type asPhalcon\Configinstance #14978 - Fixed return type hints for the following methods #14987:
Phalcon\Dispatcher\AbstractDispatcher::dispatchPhalcon\Dispatcher\DispatcherInterface::dispatchPhalcon\Filter::getPhalcon\Http\Message\AbstractCommon::cloneInstancePhalcon\Http\Message\AbstractCommon::processWithPhalcon\Http\Message\AbstractMessage::withAddedHeaderPhalcon\Http\Message\AbstractMessage::withBodyPhalcon\Http\Message\AbstractMessage::withHeaderPhalcon\Http\Message\AbstractMessage::withProtocolVersionPhalcon\Http\Message\AbstractMessage::withoutHeaderPhalcon\Http\Message\AbstractRequest::withMethodPhalcon\Http\Message\AbstractRequest::withRequestTargetPhalcon\Http\Message\AbstractRequest::withUriPhalcon\Mvc\Model\Binder::findBoundModelPhalcon\Validation::getEntityPhalcon\Validation\ValidationInterface::getEntity
- Fixed default value of
Phalcon\Crypt::$keyto satisfy the interface #14989 - Fixed return type hint for
Phalcon\Di::getInternalEventsManager#14992 - Fixed return type hints of the following
Phalcon\Flash\AbstractFlash’s methods:error,notice,successandwarning#14994 - Fixed return type hint for
Phalcon\Translate\InterpolatorFactory::newInstance#14996 - Fixed return type hint for
Phalcon\Mvc\Model::sum#15000 - Fixed return type hint for
Phalcon\Mvc\Model\CriteriaInterface::getLimitandPhalcon\Mvc\Model\Criteria::getLimitto follow documentation and original purpose #15004 - Fixed return type hint for
Phalcon\Mvc\Model::countandPhalcon\Mvc\ModelInterface::countto reflect original behavior #15006 - Fixed return type hint for
Phalcon\Mvc\Model::getEventsManagerto reflect original behavior #15008 - Fixed return type hint for
Phalcon\Mvc\Model::averageandPhalcon\Mvc\ModelInterface::averageto reflect original behavior #15013 - Fixed return type hint for
Phalcon\Mvc\Model\MetaData::getColumnMapandPhalcon\Mvc\Model\MetaData::getReverseColumnMapto reflect original behavior #15015 - Fixed return type hint for
Phalcon\Mvc\Model\MetaDataInterface::getColumnMapandPhalcon\Mvc\Model\MetaDataInterface::getReverseColumnMapto reflect original behavior #15015 - Fixed return type hint for
Phalcon\Mvc\Model\CriteriaInterface::getColumnsandPhalcon\Mvc\Model\Criteria::getColumnsto reflect original behavior #15017 - Fixed return type hint for
Phalcon\Db\Column::getSizeandPhalcon\Db\ColumnInterface::getSizeto reflect original behavior #15019 - Fixed return type hint for
Phalcon\Db\Column::getAfterPositionandPhalcon\Db\ColumnInterface::getAfterPositionto reflect original behavior #15021 - Fixed return type hint for
Phalcon\Mvc\Model\Manager::executeQueryandPhalcon\Mvc\Model\Manager::ManagerInterfaceto reflect original behavior #15024 - Fixed return type hint for
Phalcon\Mvc\Model\Resultset::getFirstandPhalcon\Mvc\Model\ResultsetInterface::getFirstto reflect original behavior #15027 - Rollback the regression changes for
Phalcon\Mvc\Model\Query::_prepareSelectto properly prepare a SQLSELECTstatement from a PHQL one #14657 - Fixed
SerializerInterfaceusage forPhalcon\Mvc\Model\Resultset\Complex::unserializeas well asPhalcon\Mvc\Model\Resultset\Complex::unserialize#14942
Removed
- Removed
Phalcon\Translate\InterpolatorFactory::$mapperas well asPhalcon\Translate\InterpolatorFactory::$servicesin favor ofPhalcon\Factory\AbstractFactoryones #15036
Installation/Upgrade
The packages in packagecloud.io are being updated (at the time of this post) and will be ready soon. You will need to use the mainline repository to install v4.0.6. You can also download the zip file, as well as DLLs for Windows, from our release page here.
You can also clone the repository and checkout the tag, and then run
zephir fullclean
zephir build
to install the new extension. Detailed installation instructions can be found in our documentation page.
Note: It might take a bit of time for the DEB and RPM packages to be built from when this blog post is published.
Thank you
Once again a huge thank you to all of our contributors! You guys have helped us a lot. You can help us even more by installing this version and testing it. If you find bugs, please report them in our Github Issues page. Alternatively you can always join us in our Discord server or our Forum.
Chat - Q&A
Support
Social Media
Videos
<3 Phalcon Team