[pkg-php-pear] Bug#824175: Error: Class '...\PropertyAccess' not found

Antonio Ospite ao2 at ao2.it
Fri May 13 11:29:46 UTC 2016

Package: php-symfony-serializer
Version: 2.8.6+dfsg-1
Severity: normal

Dear Maintainer,

I installed php-symfony-serializer and tried the first example from the
documentation at
http://symfony.com/doc/current/components/serializer.html, the code is
like this:



use Symfony\Component\Serializer\Serializer;
use Symfony\Component\Serializer\Encoder\XmlEncoder;
use Symfony\Component\Serializer\Encoder\JsonEncoder;
use Symfony\Component\Serializer\Normalizer\ObjectNormalizer;

$encoders = array(new XmlEncoder(), new JsonEncoder());
$normalizers = array(new ObjectNormalizer());

$serializer = new Serializer($normalizers, $encoders);

And I get this error when running it:

PHP Fatal error:  Uncaught Error: Class 'Symfony\Component\PropertyAccess\PropertyAccess' not found in /usr/share/php/Symfony/Component/Serializer/Normalizer/ObjectNormalizer.php:40

Of course the error goes away if I install the
php-symfony-property-access package.

I see that php-symfony-property-access is a suggested package, but I was
wondering it if should be a dependency or a least a recommended

Maybe other users will run into the same error while following the
documentation when trying to use the component for the first time.


-- System Information:
Debian Release: stretch/sid
  APT prefers unstable
  APT policy: (900, 'unstable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.6.0-rc3-ao2 (SMP w/2 CPU cores)
Locale: LANG=it_IT.utf8, LC_CTYPE=it_IT.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
Init: systemd (via /run/systemd/system)

Versions of packages php-symfony-serializer depends on:
ii  php-common                  1:40
ii  php-symfony-polyfill-php55  1.1.1-1

php-symfony-serializer recommends no packages.

Versions of packages php-symfony-serializer suggests:
pn  php-doctrine-annotations     <none>
pn  php-doctrine-cache           <none>
pn  php-symfony-config           <none>
pn  php-symfony-property-access  <none>
ii  php-symfony-yaml             2.8.4+dfsg-1

-- no debconf information
Antonio Ospite

A: Because it messes up the order in which people normally read text.
   See http://en.wikipedia.org/wiki/Posting_style
Q: Why is top-posting such a bad thing?

More information about the pkg-php-pear mailing list