We are very happy to announce the release of Phalcon v5.0.0 Alpha 7!
This release requires PHP 7.4 or PHP 8.0
This release is packed with changes - a lot of them breaking backwards compatibility. A lot of classes were moved, some components were removed or replaced with others, and we have increased code coverage significantly. Additionally we resolved over 50 cards in our project (bugs, NFRs etc.)
This will be the last alpha version
We have less than 10 cards to address for this release and 8 classes to move from the top namespace to their future βhomesβ. The next version will be a beta, at which point we will concentrate on any bugs reported, documentation as well as supporting applications (devtools, incubator, invo etc.).
We have also aligned all the tests between cphalcon
(v5) and phalcon
(v6), ensuring that we do not reinvent the wheel or lose functionality/code coverage.
Quite a bit of work left but we are getting there!
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 for v5 in our project page: https://github.com/orgs/phalcon/projects/4
Changelog
[5.0.0alpha7]
Changed
- Changes to the
Phalcon\Acl
:- Renamed
Phalcon\Acl\ComponentAware
toPhalcon\Acl\ComponentAwareInterface
- Renamed
Phalcon\Acl\RoleAware
toPhalcon\Acl\RoleAwareInterface
#15691
- Renamed
- Changed
require
torequire_once
inPhalcon\Loader
to avoid conflicts with other loaders #15489 - Changed
require
torequire_once
inPhalcon\Cli\Console
andPhalcon\Mvc\Application
for a bit of extra performance #15489 -
Phalcon\Collection
has been moved under theSupport
namespace:- Renamed
Phalcon\Collection
toPhalcon\Support\Collection
- Renamed
Phalcon\Collection\Exception
toPhalcon\Support\Collection\Exception
- Renamed
Phalcon\Collection\ReadOnly
toPhalcon\Support\Collection\ReadOnly
- Renamed
Phalcon\Collection
toPhalcon\Support\Collection
#15700
- Renamed
- Changes to
Phalcon\Session\Bag
:- Changed
Phalcon\Session\Bag::construct
to accept a container instead of internally calling the default - Changed
Phalcon\Session\Bag::construct
to throw an exception if the container is not specified - Changed
Phalcon\Session\Bag::init
to store the data in the session #15494
- Changed
- Changed
Phalcon\Events\Event::construct()
to allowsource
to be nullable #15133 - Changes to
Phalcon\Crypt
- Moved
Phalcon\Crypt\Exception
toPhalcon\Crypt\Exception\Exception
- Moved
Phalcon\Crypt\Mismatch
toPhalcon\Crypt\Exception\Mismatch
- Changed the ccm/gcm modes to store the
authTag
with the encryption string and process it with the decryption string #15717
- Moved
- Created new namespace
Phalcon\Encryption
- Moved
Phalcon\Crypt
toPhalcon\Encryption\Crypt
- Moved
Phalcon\Security
toPhalcon\Encryption\Security
- Moved the whole
Security
namespace underEncryption
-
Security\JWT\Exceptions\UnsupportedAlgorithmException
toEncryption\Security\JWT\Exceptions\UnsupportedAlgorithmException
-
Security\JWT\Exceptions\ValidatorException
toEncryption\Security\JWT\Exceptions\ValidatorException
-
Security\JWT\Signer\AbstractSigner
toEncryption\Security\JWT\Signer\AbstractSigner
-
Security\JWT\Signer\Hmac
toEncryption\Security\JWT\Signer\Hmac
-
Security\JWT\Signer\None
toEncryption\Security\JWT\Signer\None
-
Security\JWT\Signer\SignerInterface
toEncryption\Security\JWT\Signer\SignerInterface
-
Security\JWT\Token\AbstractItem
toEncryption\Security\JWT\Token\AbstractItem
-
Security\JWT\Token\Enum
toEncryption\Security\JWT\Token\Enum
-
Security\JWT\Token\Item
toEncryption\Security\JWT\Token\Item
-
Security\JWT\Token\Parser
toEncryption\Security\JWT\Token\Parser
-
Security\JWT\Token\Signature
toEncryption\Security\JWT\Token\Signature
-
Security\JWT\Token\Token
toEncryption\Security\JWT\Token\Token
-
Security\JWT\Builder
toEncryption\Security\JWT\Builder
-
Security\JWT\Validator
toEncryption\Security\JWT\Validator
-
Security\JWT\Validator
toEncryption\Security\JWT\Validator
-
Security\Exception
toEncryption\Security\Exception
-
Security\Random
toEncryption\Security\Random
#15729
- Moved
- Renamed
-
Phalcon\Crypt\Crypt::getHashAlgo()
toPhalcon\Crypt\Crypt::getHashAlgorithm()
-
Phalcon\Crypt\Crypt::getAvailableHashAlgos()
toPhalcon\Crypt\Crypt::getAvailableHashAlgorithms()
-
Phalcon\Crypt\Crypt::setHashAlgo()
toPhalcon\Crypt\Crypt::setHashAlgorithm()
#15717
-
- Renamed
Phalcon\Factory\AdapterFactory::getAdapters()
toPhalcon\Factory\AdapterFactory::getServices()
#15717 - Changed
Phalcon\Crypt\Crypt::__construct()
to haveuseSigning
set totrue
by default #15717 - Changes to
Phalcon\Config
- Moved
Phalcon\Config
toPhalcon\Config\Config
- Changed
Phalcon\Config\Config::path
by making thedelimiter
parameter astring
- Changed
Phalcon\Config\Adapter\Ini::__construct
to not acceptnull
as the mode. The default is nowINI_SCANNER_NORMAL
(2) - Refactored the code for more efficiency and speed #15720
- Moved
- Changed
Phalcon\Db\Adapter\AdapterInterface::getInternalHandler()
andPhalcon\Db\Adapter\Pdo\AbstractPdo::getInternalHandler()
to returnvar
instead of\PDO
for custom adapters with different engines #15119 - Moved
Phalcon\Filter
toPhalcon\Filter\Filter
; added more tests #15726 - Changed
Phalcon\Mvc\Model::getPreparedQuery()
to returnQueryInterface
instead ofQuery
#15562 - Moved
Phalcon\Cache
toPhalcon\Cache\Cache
#15728 - Changed
Phalcon\Factory\AdapterFactory
to define the factory exception ingetExceptionClass()
instead of a property. #15728 - Renamed
Phalcon\Db\Adapter\AbstractAdapter::getSqlVariables()
toPhalcon\Db\Adapter\AbstractAdapter::getSQLVariables()
to align with the rest of thegetSQL*
methods #15637 - Moved
Phalcon\Logger
toPhalcon\Logger\Logger
#15727 - Changes to
Phalcon\Escaper
- Moved
Phalcon\Escaper
toPhalcon\Html\Escaper
- Moved
Phalcon\Escaper\EscaperInterface
toPhalcon\Html\Escaper\EscaperInterface
- Moved
Phalcon\Escaper\Exception
toPhalcon\Html\Escaper\Exception
- Deprecated methods (to be removed at a future version)
-
escapeCss()
becomescss()
-
escapeJs()
, becomesjs()
-
escapeHtml()
becomeshtml()
-
escapeHtmlAttr()
becomesattributes()
-
escapeUrl()
becomesurl()
-
setHtmlQuoteType()
becomessetFlags()
#15757
- Moved
- Changed
Phalcon\Encryption\Security::hash()
to also usepassword_hash()
and acceptARGON2*
algorithms #15731 - Removed uncamelize of
realClassName
inPhalcon\Mvc\Router\Route::getRoutePaths()
if definition is string to make processing same as if array definition #15067 - Changed
Phalcon\Validation::getValue()
behavior to get value fromdata
if not found inentity
. #14203 - Changed
Phalcon\Forms\Form::isValid()
signature: addedwhitelist
argument. #14203 - Changed
Phalcon\Support\Collection\ReadOnly
toPhalcon\Support\Collection\ReadOnlyCollection
to avoid conflicts with the read-only feature in PHP 8.1 #15767 - Removed
Phalcon\Text
- replaced byPhalcon\Support\Helper\Str*
#15776 - Removed
Phalcon\Helper\Arr
- replaced byPhalcon\Support\Helper\Arr*
#15776 - Removed
Phalcon\Helper\File
- replaced byPhalcon\Support\Helper\File*
#15776 - Removed
Phalcon\Helper\Json
- replaced byPhalcon\Support\Helper\Json*
#15776 - Removed
Phalcon\Helper\Number
- replaced byPhalcon\Support\Helper\Number*
#15776 - Removed
Phalcon\Helper\Str
- replaced byPhalcon\Support\Helper\Str*
#15776 - Removed references to
Phalcon\Text
,Phacon\Helper*
from the code replacing it withPhalcon\Support\Helper*
#15776 - Synchronized tests with
phalcon/phalcon
thus increasing coverage #15776 - Changed
Phalcon\Assets\Manager
to require aPhalcon\Html\TagFactory
in its constructor #15776
Added
- Added more tests in the suite for additional code coverage #15691
- Added
Phalcon\Events\AbstractEventsAware
class to handle the Events Manager when necessary #15691 - Added
Phalcon\Acl\Adapter\AdapterInterface::getInheritedRoles()
andPhalcon\Acl\Adapter\Memory::getInheritedRoles()
that returns the inherited roles based on a passed role name (or all if no parameter supplied) #15154 - Changes to
Phalcon\Crypt
- Added
Phalcon\Crypt\Padding\PadInteface
and padding adapters Phalcon\Crypt\Padding\Ansi
Phalcon\Crypt\Padding\Iso10126
Phalcon\Crypt\Padding\IsoIek
Phalcon\Crypt\Padding\Noop
Phalcon\Crypt\Padding\PadInterface
Phalcon\Crypt\Padding\Pkcs7
Phalcon\Crypt\Padding\Space
Phalcon\Crypt\Padding\Zero
- Added
Phalcon\Crypt\PadFactory
to easily create padding adapters - Added more tests increasing coverage #15717
- Added
- Added
Phalcon\Cache\Adapter*::setForever()
andPhalcon\Storage\Adapter*::setForever()
to allow storing a key forever #15485 - Added
Phalcon\Encryption\Security::getHashInformation()
to return information for a hash #15731 - Added constants
Phalcon\Encryption\Security::CRYPT_ARGON2I
andPhalcon\Encryption\Security::CRYPT_ARGON2ID
#15731 - Added
allowEmpty
checks to common validators #15515 - Added
Phalcon\Forms\Form::getFilteredValue()
to get filtered value without providing entity #15438 - Added
Phalcon\Forms\Form::setWhitelist()
andPhalcon\Forms\Form::getWhitelist()
#14203 - Added
dirtyState
serialization inPhalcon\Mvc\Model
#15571 - Added short versions of helpers for
Phalcon\Html\TagFactory
(call service as a method) #15776 - Added short versions of helpers for
Phalcon\Support\HelperFactory
(call service as a method) #15776 - Added
Phalcon\Html\Helper\Doctype
helper fordoctype
generation #15776 - Added
style
orlink
tag option forPhalcon\Html\Helper\Style
#15776
Fixed
- Fixed
Query::getExpression()
return type #15553 - Fixed
Phalcon\Mvc\Model::getRelated()
to correctly return relationships (cached or not) when the foreign key has changed #15649 - Fixed
Phalcon\Db\Adapter\Pdo\*
,Phalcon\Mvc\Model
andPhalcon\Mvc\Model\MetaData\Strategy\Annotations
to treatBIGINT
numbers as string #15632 - Fixed
Phalcon\Crypt\Crypt::decrypt()
to correctly calculate the hash when using signed mode #15717 - Fixed
Phalcon\Mvc\Model\Manager::isVisibleModelProperty()
to correctly check if setting property is visible #15276 - Fixed
Phalcon\Config\Config::merge
to retain numeric indexes in deep merges #14705 - Fixed globals (Zephir change) to correctly display string values for global settings in
phpinfo()
#15269 - Fixed
Phalcon\Storage\Adapter\Redis::getAdapter()
andPhalcon\Cache\Adapter\Redis::getAdapter()
to accept the connection timeout in the constructoroptions
#15744 - Fixed
Phalcon\Db\Adapter\AbstractAdapter::getSQLVariables()
to return an empty array when initialized #15637 - Fixed
Phalcon\Cache\Adapter\*
andPhalcon\Storage\Adapter\*
to delete a key whenset()
is called with a zero or negative TTL #15485 - Fixed
Phalcon\Db\Adapter\Pdo\Mysql
to not usePDO::ATTR_EMULATE_PREPARES
andPDO::ATTR_STRINGIFY_FETCHES
by default. This allows numbers to be returned with resultsets instead of strings for numeric fields #15361 - Fixed
Phalcon\Validation\Validator\File
to usemessageFileEmpty
#14928 - Fixed
Phalcon\Db\RawValue
usage bugs inPhalcon\Mvc\Model::doLowUpdate()
#15413 - Fixed
type
attribute for stylesheet links #15776 - Fixed
Phalcon\Debug
to not throw an exception if a URL service is not present #15381
Removed
- Removed
Phalcon\Kernel
- obsolete #15776
Top comments (0)