Commit Graph

646 Commits

Author SHA1 Message Date
Nicolas Grekas 2dbfeb9db9 Merge branch '3.4' into 4.4
* 3.4:
  [FrameworkBundle] display actual target for error in AssetsInstallCommand
  Remove patches for Doctrine bugs and deprecations
  [DI][EventDispatcher] added contract for implementation
2020-05-08 11:58:40 +02:00
Grégoire Paris 2f305cdc83 Remove patches for Doctrine bugs and deprecations 2020-05-08 11:45:13 +02:00
Nicolas Grekas 02d9597a41 Merge branch '5.0'
* 5.0:
  Force doctrine/dbal <=2.10.2 when testing
2020-05-05 15:53:42 +02:00
Nicolas Grekas cd21c8208e Merge branch '4.4' into 5.0
* 4.4:
  Force doctrine/dbal <=2.10.2 when testing
2020-05-05 15:53:15 +02:00
Nicolas Grekas f8bedf4e79 Merge branch '3.4' into 4.4
* 3.4:
  Force doctrine/dbal <=2.10.2 when testing
2020-05-05 15:52:57 +02:00
Nicolas Grekas d1953d61cd Force doctrine/dbal <=2.10.2 when testing 2020-05-05 15:43:18 +02:00
Jérémy Derussé 7c4888eed1 [AmazonSqsMessenger] Use AsyncAws to handle SQS communication 2020-05-03 18:22:01 +02:00
Jérémy Derussé 21243874bc [Mailer] Use AsyncAws to handle SES requests 2020-05-03 16:23:41 +02:00
Nicolas Grekas 6dc7d8b211 Merge branch '5.0'
* 5.0:
  [PhpUnitBridge] add PolyfillTestCaseTrait::expectExceptionMessageMatches to provide FC with recent phpunit versions
  [Messenger] Make sure redis transports are initialized correctly
  Remove return type for Twig function workflow_metadata()
  [DI] fix typo
2020-04-15 18:09:08 +02:00
Nicolas Grekas 4f8f3747d3 Merge branch '4.4' into 5.0
* 4.4:
  [PhpUnitBridge] add PolyfillTestCaseTrait::expectExceptionMessageMatches to provide FC with recent phpunit versions
  [Messenger] Make sure redis transports are initialized correctly
  Remove return type for Twig function workflow_metadata()
  [DI] fix typo
2020-04-15 17:59:10 +02:00
soyuka cfd5a29eaf [PhpUnitBridge] add PolyfillTestCaseTrait::expectExceptionMessageMatches to provide FC with recent phpunit versions 2020-04-15 17:55:41 +02:00
Nicolas Grekas 53b0f63bc3 [String] leverage Stringable from PHP 8 2020-03-13 11:54:27 +01:00
Grégoire Pineau c3f14dd0f4 [UID] Added the component + Added support for UUID 2020-03-12 18:21:37 +01:00
Nicolas Grekas ef113feeb3 [HttpClient] Add portable HTTP/2 implementation based on Amp's HTTP client 2020-03-02 14:21:45 +01:00
Nicolas Grekas 3e35d8e9e3 Leverage trigger_deprecation() from symfony/deprecation-contracts 2020-02-08 15:04:50 +01:00
Nicolas Grekas e9f0cfe9db Merge branch '5.0'
* 5.0: (31 commits)
  [HttpClient] NativeHttpClient should not send >1.1 protocol version
  [HttpClient] fix support for non-blocking resource streams
  [Mailer] Make sure you can pass custom headers to Mailgun
  [Mailer] Remove line breaks in email attachment content
  Update links to documentation
  [Validator] Add the missing translations for the Arabic (ar) locale
  ensure to expect no validation for the right reasons
  [Security-Guard] fixed 35203 missing name tag in param docblock
  [HttpClient] fix casting responses to PHP streams
  [PhpUnitBridge] Add test case for @expectedDeprecation annotation
  [PhpUnitBridge][SymfonyTestsListenerTrait] Remove $testsWithWarnings stack
  [FrameworkBundle] Fix getUser() phpdoc in AbstractController
  [Mailer] Fix addresses management in Sendgrid API payload
  [Mailer][MailchimpBridge] Fix missing attachments when sending via Mandrill API
  [Mailer][MailchimpBridge] Fix incorrect sender address when sender has name
  [HttpClient] fix capturing SSL certificates with NativeHttpClient
  Update year in license files
  Update year in license files
  [TwigBridge][Form] Added missing help messages in form themes
  Update year in license files
  ...
2020-01-04 15:20:45 +01:00
Nicolas Grekas 4c790b0589 doctrine/doctrine-bundle ^1.5 is not compatible with Symfony 5 2019-12-30 18:22:15 +01:00
Nicolas Grekas 331765b95d Merge branch '5.0'
* 5.0:
  Fix leftover from doctrine/persistence < 1.3
  Require doctrine/persistence ^1.3
2019-12-12 16:10:59 +01:00
Nicolas Grekas 9a88f527a6 Merge branch '4.4' into 5.0
* 4.4:
  Fix leftover from doctrine/persistence < 1.3
  Require doctrine/persistence ^1.3
2019-12-12 16:09:39 +01:00
Nicolas Grekas 866de0fb8b Merge branch '4.3' into 4.4
* 4.3:
  Require doctrine/persistence ^1.3
2019-12-12 16:02:38 +01:00
Nicolas Grekas ce5dcb96c1 Require doctrine/persistence ^1.3 2019-12-12 15:53:41 +01:00
Nicolas Grekas 1b4ab81085 Merge branch '5.0'
* 5.0:
  [Routing] fix tests
  [DI] minor cleanup
  [Form] group constraints when calling the validator
  Remove wrong @group legacy annotations
  [DependencyInjection] Fix dumping multiple deprecated aliases
  allow button names to start with uppercase letter
  Allow PHP ^7.2.5
  States that the HttpClient provides a Http Async implementation
  [Routing] Fix ContainerLoader and ObjectLoaderTest
  [HttpKernel] Make ErrorListener::onKernelException()'s dispatcher argument explicit
  [HttpKernel] Drop deprecated ExceptionListener
  Removed extra whitespace
  [Security] Fix best encoder not wired using migrate_from
2019-11-21 08:02:52 +01:00
Nicolas Grekas 6194c2a96c Allow PHP ^7.2.5 2019-11-18 18:27:11 +01:00
Fabien Potencier e60a876201 updated version to 5.1 2019-11-17 19:31:35 +01:00
Nicolas Grekas cab859c4ae Merge branch '4.3' into 4.4
* 4.3:
  Add conflict rule for Monolog 2.
2019-11-17 15:08:02 +01:00
Nicolas Grekas 5188215fe9 Merge branch '3.4' into 4.3
* 3.4:
  Add conflict rule for Monolog 2.
2019-11-17 15:07:50 +01:00
Alexander M. Turek d53b91a45a Add conflict rule for Monolog 2. 2019-11-17 14:23:03 +01:00
Nicolas Grekas a3376918ba Merge branch '4.4'
* 4.4:
  [ErrorHandler] help finish the PR
  [ErrorHandler] merge and remove the ErrorRenderer component
2019-11-12 10:25:44 +01:00
Nicolas Grekas 6c9157bbc2 [ErrorHandler] merge and remove the ErrorRenderer component 2019-11-10 18:54:30 +01:00
Alexander M. Turek f2dc2d6d8b Disallow symfony/contracts v2. 2019-11-09 20:42:39 +01:00
Alexander M. Turek 4de3773979 Add parameter type declarations to contracts. 2019-11-09 10:18:34 +01:00
Nicolas Grekas e3261f4f7f [SecurityBundle] test with doctrine-bundle 2 2019-10-22 11:22:01 +02:00
Nicolas Grekas ff6078edd7 fix merge 2019-10-22 10:22:13 +02:00
Nicolas Grekas c4653e1f65 Restrict secrets management to sodium+filesystem 2019-10-19 20:26:39 +02:00
Nicolas Grekas 4e5c6ba0d3 Merge branch '4.4'
* 4.4:
  [travis] Fix build-packages script
  Add types to constructors and private/final/internal methods (Batch III)
  [HttpClient] Async HTTPlug client
  [Messenger] Allow to configure the db index on Redis transport
  [HttpClient] bugfix exploding values of headers
  [VarDumper] Made all casters final
  [VarDumper] Added a support for casting Ramsey/Uuid
  Remove useless testCanCheckIfTerminalIsInteractive test case
  [Validator] Add the missing translations for the Thai (\"th\") locale
  [Routing] gracefully handle docref_root ini setting
  [Validator] Fix ValidValidator group cascading usage
2019-10-07 14:45:39 +02:00
Nyholm 4fd593f869 [HttpClient] Async HTTPlug client 2019-10-07 13:21:57 +02:00
Fabien Potencier 7f97a3f11f [Notifier] added the component 2019-10-05 12:48:03 +02:00
Fabien Potencier 5d154fb304 feature #33553 [String] a new component for object-oriented strings management with an abstract unit system (nicolas-grekas, hhamon, gharlan)
This PR was merged into the 5.0-dev branch.

Discussion
----------

[String] a new component for object-oriented strings management with an abstract unit system

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

This is a reboot of #22184 (thanks @hhamon for working on it) and a generalization of my previous work on the topic ([patchwork/utf8](https://github.com/tchwork/utf8)). Unlike existing libraries (including `patchwork/utf8`), this component provides a unified API for the 3 unit systems of strings: bytes, code points and grapheme clusters.

The unified API is defined by the `AbstractString` class. It has 2 direct child classes: `BinaryString` and `AbstractUnicodeString`, itself extended by `Utf8String` and `GraphemeString`.

All objects are immutable and provide clear edge-case semantics, using exceptions and/or (nullable) types!

Two helper functions are provided to create such strings:
```php
new GraphemeString('foo') == u('foo'); // when dealing with Unicode, prefer grapheme units
new BinaryString('foo') == b('foo');
```

`GraphemeString` is the most linguistic-friendly variant of them, which means it's the one ppl should use most of the time *when dealing with written text*.

Future ideas:
 - improve tests
 - add more docblocks (only where they'd add value!)
 - consider adding more methods in the string API (`is*()?`, `*Encode()`?, etc.)
 - first class Emoji support
 - merge the Inflector component into this one
 - use `width()` to improve `truncate()` and `wordwrap()`
 - move method `slug()` to a dedicated locale-aware service class
 - propose your ideas (send PRs after merge)

Out of (current) scope:
 - what [intl](https://php.net/intl) provides (collations, transliterations, confusables, segmentation, etc)

Here is the unified API I'm proposing in this PR, borrowed from looking at many existing libraries, but also Java, Python, JavaScript and Go.

```php
function __construct(string $string = '');
static function unwrap(array $values): array
static function wrap(array $values): array
function after($needle, bool $includeNeedle = false, int $offset = 0): self;
function afterLast($needle, bool $includeNeedle = false, int $offset = 0): self;
function append(string ...$suffix): self;
function before($needle, bool $includeNeedle = false, int $offset = 0): self;
function beforeLast($needle, bool $includeNeedle = false, int $offset = 0): self;
function camel(): self;
function chunk(int $length = 1): array;
function collapseWhitespace(): self
function endsWith($suffix): bool;
function ensureEnd(string $suffix): self;
function ensureStart(string $prefix): self;
function equalsTo($string): bool;
function folded(): self;
function ignoreCase(): self;
function indexOf($needle, int $offset = 0): ?int;
function indexOfLast($needle, int $offset = 0): ?int;
function isEmpty(): bool;
function join(array $strings): self;
function jsonSerialize(): string;
function length(): int;
function lower(): self;
function match(string $pattern, int $flags = 0, int $offset = 0): array;
function padBoth(int $length, string $padStr = ' '): self;
function padEnd(int $length, string $padStr = ' '): self;
function padStart(int $length, string $padStr = ' '): self;
function prepend(string ...$prefix): self;
function repeat(int $multiplier): self;
function replace(string $from, string $to): self;
function replaceMatches(string $fromPattern, $to): self;
function slice(int $start = 0, int $length = null): self;
function snake(): self;
function splice(string $replacement, int $start = 0, int $length = null): self;
function split(string $delimiter, int $limit = null, int $flags = null): array;
function startsWith($prefix): bool;
function title(bool $allWords = false): self;
function toBinary(string $toEncoding = null): BinaryString;
function toGrapheme(): GraphemeString;
function toUtf8(): Utf8String;
function trim(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): self;
function trimEnd(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): self;
function trimStart(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): self;
function truncate(int $length, string $ellipsis = ''): self;
function upper(): self;
function width(bool $ignoreAnsiDecoration = true): int;
function wordwrap(int $width = 75, string $break = "\n", bool $cut = false): self;
function __clone();
function __toString(): string;
```

`AbstractUnicodeString` adds these:
```php
static function fromCodePoints(int ...$codes): self;
function ascii(array $rules = []): self;
function codePoint(int $index = 0): ?int;
function folded(bool $compat = true): parent;
function normalize(int $form = self::NFC): self;
function slug(string $separator = '-'): self;
```

and `BinaryString`:
```php
static function fromRandom(int $length = 16): self;
function byteCode(int $index = 0): ?int;
function isUtf8(): bool;
function toUtf8(string $fromEncoding = null): Utf8String;
function toGrapheme(string $fromEncoding = null): GraphemeString;
```

Case insensitive operations are done with the `ignoreCase()` method.
e.g. `b('abc')->ignoreCase()->indexOf('B')` will return `1`.

For reference, CLDR transliterations (used in the `ascii()` method) are defined here:
https://github.com/unicode-org/cldr/tree/master/common/transforms

Commits
-------

dd8745aced [String] add more tests
82a00956bc [String] add tests
012e92a772 [String] a new component for object-oriented strings management with an abstract unit system
2019-09-26 10:14:27 +02:00
Nicolas Grekas 012e92a772 [String] a new component for object-oriented strings management with an abstract unit system 2019-09-25 16:38:20 +02:00
Nicolas Grekas 2d877b1804 Merge branch '4.4'
* 4.4:
  [Security/Http] fix typo in deprecation message
  [Security] Deprecate isGranted()/decide() on more than one attribute
  Fixed a minor typo in the UPGRADE to 5.0 guide
  Various tweaks 3.4
  Various tweaks 4.3
  [Security] Make stateful firewalls turn responses private only when needed
  [PhpUnit] Fix usleep mock return value
  Revert \"feature #33507 [WebProfiler] Deprecated intercept_redirects in 4.4 (dorumd)\"
  [TwigBundle] typo
  [TwigBundle] fix test case
  [Lock] use Predis\ClientInterface instead of Predis\Client
  Allow Twig 3
  Minor tweaks
  Fix version typo in deprecation notice
  [Form][SubmitType] Add "validate" option
  hint to the --parse-tags when parsing tags fails
  Make legacy "wrong" RFC2047 encoding apply only to one header
2019-09-24 18:05:28 +02:00
Nicolas Grekas 09f4eb5cd8 Allow Twig 3 2019-09-23 16:04:59 +02:00
Nicolas Grekas 4442a3f2ac Merge branch '4.4'
* 4.4:
  Re-enable previously failing PHP 7.4 test cases
  [PhpUnitBridge] fix uninitialized variable
  [ErrorRenderer] fix Cannot use object of type ErrorException as array exception #33631
  [Twig] Add missing check
  Revert "bug #33618 fix tests depending on other components' tests (xabbuh)"
  install from source to include components tests
  Fix undefined constant and other minor issues
  [Twig] Add NotificationEmail
  ensure compatibility with type resolver 0.5
  Call AssertEquals with proper parameters
  [DependencyInjection] Allow binding iterable and tagged services
  [Twig] Fix Twig config extra keys
  fix tests depending on other components' tests
  Fix lint commands frozen on empty stdin
2019-09-19 18:03:37 +02:00
Fabien Potencier f6c6cf7dc9 [Twig] Add NotificationEmail 2019-09-18 17:08:12 +02:00
Fabien Potencier 20f2a34e8c Merge branch '4.4'
* 4.4:
  [WebProfiler] Deprecated intercept_redirects in 4.4
  bump required symfony/contracts version
2019-09-16 21:21:57 +02:00
Christian Flothmann 343d01f63b bump required symfony/contracts version 2019-09-16 16:43:57 +02:00
Nicolas Grekas 6b6562cf13 Merge branch '4.4'
* 4.4: (21 commits)
  [appveyor] exclude tty group
  [HttpFoundation] Add types to private/final/internal methods and constructors.
  Add types to private/final/internal methods and constructors.
  SCA: minor code tweaks
  Tweak output
  [FrameworkBundle] Added --sort option for TranslationUpdateCommand
  [HttpClient] fallbackto CURLMOPT_MAXCONNECTS when CURLMOPT_MAX_HOST_CONNECTIONS is not available
  [DI] generate preload.php file for PHP 7.4 in cache folder
  Allow version 2 of the contracts package.
  [Serializer] Allow multi-dimenstion object array in AbstractObjectNormalizer
  fixed typo
  [HttpKernel] Fix Apache mod_expires Session Cache-Control issue
  deprecated not passing dash symbol (-) to STDIN commands
  [VarDumper] display ellipsed FQCN for nested classes
  [VarDumper] Display fully qualified title
  [Mailer] Change the syntax for DSNs using failover or roundrobin
  Removed workaround introduced in 4.3
  [Console] Added support for definition list
  [OptionsResolver] Display full nested options hierarchy in exceptions
  New welcome page
  ...
2019-09-08 22:44:36 +02:00
Alexander M. Turek a1ee32039b Allow version 2 of the contracts package. 2019-09-08 12:38:38 +02:00
Nicolas Grekas bfdf79e25d Merge branch '4.4'
* 4.4:
  [MonologBridge] Bump min version for monolog ^1.25 and drop dead code
  [Bridge/Twig] use tty group on testLintDefaultPaths
  fix tests mocking final events
2019-09-06 18:03:39 +02:00
Grégoire Pineau 1e19c65b67 [MonologBridge] Bump min version for monolog ^1.25 and drop dead code 2019-09-06 16:22:32 +02:00
Nicolas Grekas 45f650ebda Merge branch '4.4'
* 4.4:
  [Routing] fix static route reordering when a previous dynamic route conflicts
  conflict with HttpKernel 5
  Return null as Expire header if it was set to null
  bug #33370 Fix import statement typo in NullCache (adrienbrault)
  [ProxyManager] remove ProxiedMethodReturnExpression polyfill
  fix dumping not inlined scalar tag values
  Fix import statement typo in NullCache
  [DoctrineBridge] Allow configuring class names through methods instead of class parameters
2019-08-30 14:51:40 +02:00
Nicolas Grekas 22ed6247fa Merge branch '4.3' into 4.4
* 4.3:
  [Routing] fix static route reordering when a previous dynamic route conflicts
  Return null as Expire header if it was set to null
  bug #33370 Fix import statement typo in NullCache (adrienbrault)
  [ProxyManager] remove ProxiedMethodReturnExpression polyfill
  fix dumping not inlined scalar tag values
2019-08-30 14:49:06 +02:00
Nicolas Grekas 247815d21c Merge branch '3.4' into 4.3
* 3.4:
  Return null as Expire header if it was set to null
  [ProxyManager] remove ProxiedMethodReturnExpression polyfill
  fix dumping not inlined scalar tag values
2019-08-30 14:41:22 +02:00
Nicolas Grekas 792f93018a [ProxyManager] remove ProxiedMethodReturnExpression polyfill 2019-08-29 16:54:55 +02:00
Nicolas Grekas 21b87024f0 Use PHP 7.4 on deps=low 2019-08-22 08:53:14 +02:00
Alexander M. Turek f30edcab65 Support for Twig 3. 2019-08-21 14:55:51 +02:00
Nicolas Grekas 2a6cd1578d Merge branch '4.4'
* 4.4:
  [WebLink] implement PSR-13 directly
2019-08-12 17:29:44 +02:00
Nicolas Grekas b570ee1103 [WebLink] implement PSR-13 directly 2019-08-12 15:51:36 +02:00
Nicolas Grekas 547b9b8fc3 Merge branch '4.4'
* 4.4:
  [HttpKernel] fixed class having a leading \ in a route controller
  [HttpKernel] trim the leading backslash in the controller init
  Bump minimal requirements
  Use PHPUnit 8.3 on Travis when possible
2019-08-09 14:41:16 +02:00
Nicolas Grekas 24858f2aee Merge branch '4.3' into 4.4
* 4.3:
  Bump minimal requirements
  Use PHPUnit 8.3 on Travis when possible
2019-08-09 14:40:26 +02:00
Nicolas Grekas 07cf927237 Merge branch '3.4' into 4.3
* 3.4:
  Bump minimal requirements
  Use PHPUnit 8.3 on Travis when possible
2019-08-09 14:37:48 +02:00
Jérémy Derussé 41d94c3226
Bump minimal requirements 2019-08-09 13:59:47 +02:00
Nicolas Grekas c6409da7ef Merge branch '4.4'
* 4.4:
  fix merge
  Fix inconsistent return points.
  pass translation parameters to the trans filter
  [Mime] fixed wrong mimetype
  [ProxyManagerBridge] Polyfill for unmaintained version
  [HttpClient] Declare `$active` first to prevent weird issue
  Remove deprecated assertContains
  [HttpClient] fix tests
  SCA: dropped unused mocks, duplicate import and a function alias usage
  Added correct plural for box -> boxes
  [Config] fix test
  Fix remaining tests
  fix getName() when transport is null
  [Console] Check for ErrorHandler classes
  Improve fa (persian) translation
2019-08-07 14:07:17 +02:00
Nicolas Grekas a0c2aa8302 Merge branch '4.3' into 4.4
* 4.3:
  Fix inconsistent return points.
  pass translation parameters to the trans filter
  [Mime] fixed wrong mimetype
  [ProxyManagerBridge] Polyfill for unmaintained version
  [HttpClient] Declare `$active` first to prevent weird issue
  Remove deprecated assertContains
  [HttpClient] fix tests
  SCA: dropped unused mocks, duplicate import and a function alias usage
  Added correct plural for box -> boxes
  [Config] fix test
  Fix remaining tests
  Improve fa (persian) translation
2019-08-07 14:00:28 +02:00
Nicolas Grekas 3cd7726d0d Merge branch '3.4' into 4.3
* 3.4:
  [ProxyManagerBridge] Polyfill for unmaintained version
  SCA: dropped unused mocks, duplicate import and a function alias usage
  [Config] fix test
  Improve fa (persian) translation
2019-08-07 10:30:22 +02:00
Jérémy Derussé 33f722d86e [ProxyManagerBridge] Polyfill for unmaintained version 2019-08-07 10:25:59 +02:00
Fabien Potencier c910095d09 minor #32600 [Debug] drop the component (nicolas-grekas)
This PR was merged into the 5.0-dev branch.

Discussion
----------

[Debug] drop the component

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Of course, the component will still exist, but 4.4 will be the last version.
Use ErrorHandler now instead.

We will also have to drop the master branch on the subtree split.

Commits
-------

bd056422bf [Debug] drop the component
2019-07-18 17:20:44 +02:00
Nicolas Grekas b52149fd2f [Security] drop the component 2019-07-18 16:32:31 +02:00
Nicolas Grekas bd056422bf [Debug] drop the component 2019-07-18 16:21:14 +02:00
Nicolas Grekas 36c306d0ed Merge branch '4.4'
* 4.4: (30 commits)
  fix merge
  fix merge
  [HttpClient] fix debug output added to stderr at shutdown
  fix cs
  [Mailer] fixed logic
  fixed missing license
  Add a new ErrorHandler component (mirror of the Debug component)
  Use mocks before replacing the error handler
  [Config] Do not use absolute path when computing the vendor freshness
  [Process] Path resolution for FCGI configuration
  Bump minimum version of symfony/phpunit-bridge
  Container*::getServiceIds() should return an array of string
  [Config][ReflectionClassResource] Use ternary instead of null coaelscing operator
  [Validator] Add missing Russian and Ukrainian translations
  [Translation] Use HTTPS and fix a url
  [Config] Fix for signatures of typed properties
  [Validator] Add missing Hungarian translations
  [Validator] Add Lithuanian translation for Range validator
  Add HTTPS to a URL
  sync translation files
  ...
2019-07-18 12:46:32 +02:00
Nicolas Grekas fcb330905d fix merge 2019-07-18 12:43:22 +02:00
Nicolas Grekas ed0b361d6f Merge branch '4.3' into 4.4
* 4.3: (25 commits)
  fix merge
  [HttpClient] fix debug output added to stderr at shutdown
  fix cs
  Use mocks before replacing the error handler
  [Config] Do not use absolute path when computing the vendor freshness
  Bump minimum version of symfony/phpunit-bridge
  Container*::getServiceIds() should return an array of string
  [Config][ReflectionClassResource] Use ternary instead of null coaelscing operator
  [Validator] Add missing Russian and Ukrainian translations
  [Translation] Use HTTPS and fix a url
  [Config] Fix for signatures of typed properties
  [Validator] Add missing Hungarian translations
  [Validator] Add Lithuanian translation for Range validator
  Add HTTPS to a URL
  sync translation files
  PHPDoc fixes
  Add notInRange translation
  Add danish translation for Range validator
  Add german translation for Range validator
  Update validators.es.xlf
  ...
2019-07-18 12:38:27 +02:00
Nicolas Grekas 61ce400807 Merge branch '4.2' into 4.3
* 4.2: (23 commits)
  fix cs
  Use mocks before replacing the error handler
  [Config] Do not use absolute path when computing the vendor freshness
  Bump minimum version of symfony/phpunit-bridge
  Container*::getServiceIds() should return an array of string
  [Config][ReflectionClassResource] Use ternary instead of null coaelscing operator
  [Validator] Add missing Russian and Ukrainian translations
  [Translation] Use HTTPS and fix a url
  [Config] Fix for signatures of typed properties
  [Validator] Add missing Hungarian translations
  [Validator] Add Lithuanian translation for Range validator
  Add HTTPS to a URL
  sync translation files
  PHPDoc fixes
  Add notInRange translation
  Add danish translation for Range validator
  Add german translation for Range validator
  Update validators.es.xlf
  [Validator] Add missing en and fr translation ids from 4.4
  [Debug][DebugClassLoader] Don't check class if the included file don't exist
  ...
2019-07-18 12:34:59 +02:00
Nicolas Grekas dc11777afa Merge branch '3.4' into 4.2
* 3.4: (23 commits)
  fix cs
  Use mocks before replacing the error handler
  [Config] Do not use absolute path when computing the vendor freshness
  Bump minimum version of symfony/phpunit-bridge
  Container*::getServiceIds() should return an array of string
  [Config][ReflectionClassResource] Use ternary instead of null coaelscing operator
  [Validator] Add missing Russian and Ukrainian translations
  [Translation] Use HTTPS and fix a url
  [Config] Fix for signatures of typed properties
  [Validator] Add missing Hungarian translations
  [Validator] Add Lithuanian translation for Range validator
  Add HTTPS to a URL
  sync translation files
  PHPDoc fixes
  Add notInRange translation
  Add danish translation for Range validator
  Add german translation for Range validator
  Update validators.es.xlf
  [Validator] Add missing en and fr translation ids from 4.4
  [Debug][DebugClassLoader] Don't check class if the included file don't exist
  ...
2019-07-18 12:29:22 +02:00
Thomas Calvet 04e0f3c575 Bump minimum version of symfony/phpunit-bridge 2019-07-17 12:41:35 +02:00
Nicolas Grekas 448c777039 Merge branch '4.4'
* 4.4:
  Fix root composer.json
2019-07-11 10:52:55 +02:00
Nicolas Grekas ea92f38c52 Fix root composer.json 2019-07-11 10:52:50 +02:00
Fabien Potencier 906b3ca89a removed support for Twig 1.x 2019-07-09 13:27:30 +02:00
Alexander M. Turek ca1cfec6a9 Monolog 2 compatibility. 2019-07-01 11:46:50 +02:00
Fabien Potencier bef96ee884 Merge branch '4.4'
* 4.4:
  renamed the ErrorHandler component to ErrorCatcher
2019-06-27 19:56:41 +02:00
Fabien Potencier b6eac3f861 renamed the ErrorHandler component to ErrorCatcher 2019-06-27 19:38:50 +02:00
Nicolas Grekas 7f7c142a3b Merge branch '4.4'
* 4.4:
  [Mailer] fixed tests on Windows
  [PhpUnitBridge] fix tests
  [Mailer] fixed error message when connecting to a stream raises an error before connect()
  [Mailer] fixed timeout type hint
  improve error messages in the event dispatcher
  [Security/Core] work around sodium_compat issue
  bumped Symfony version to 4.3.3
  updated VERSION for 4.3.2
  updated CHANGELOG for 4.3.2
  bumped Symfony version to 4.2.11
  updated VERSION for 4.2.10
  updated CHANGELOG for 4.2.10
  bumped Symfony version to 3.4.30
  updated VERSION for 3.4.29
  update CONTRIBUTORS for 3.4.29
  updated CHANGELOG for 3.4.29
  Fixed type annotation.
2019-06-27 18:53:23 +02:00
Fabien Potencier 4d8c473fd3 Merge branch '4.3' into 4.4
* 4.3:
  [Mailer] fixed tests on Windows
  [PhpUnitBridge] fix tests
  [Mailer] fixed error message when connecting to a stream raises an error before connect()
  [Mailer] fixed timeout type hint
  improve error messages in the event dispatcher
  [Security/Core] work around sodium_compat issue
  bumped Symfony version to 4.3.3
  updated VERSION for 4.3.2
  updated CHANGELOG for 4.3.2
  bumped Symfony version to 4.2.11
  updated VERSION for 4.2.10
  updated CHANGELOG for 4.2.10
  bumped Symfony version to 3.4.30
  updated VERSION for 3.4.29
  update CONTRIBUTORS for 3.4.29
  updated CHANGELOG for 3.4.29
  Fixed type annotation.
2019-06-27 18:48:03 +02:00
Nicolas Grekas 9b69dc651a [PhpUnitBridge] fix tests 2019-06-27 18:09:32 +02:00
Nicolas Grekas 01c096022c Merge branch '4.4'
* 4.4:
  Reject phpunit-bridge v5 for now
  Revert "Revert "bug #31730 [PhpUnitBridge] More accurate grouping (greg0ire)""
2019-06-26 14:22:13 +02:00
Nicolas Grekas 80e28a0acd Merge branch '4.3' into 4.4
* 4.3:
  Reject phpunit-bridge v5 for now
  Revert "Revert "bug #31730 [PhpUnitBridge] More accurate grouping (greg0ire)""
2019-06-26 14:22:07 +02:00
Nicolas Grekas e24e948a42 Reject phpunit-bridge v5 for now 2019-06-26 14:21:28 +02:00
Nicolas Grekas 0c90809ebd Merge branch '4.4'
* 4.4:
  Bump phpunit-bridge
2019-06-26 12:04:44 +02:00
Nicolas Grekas 5f60bc9536 Merge branch '4.3' into 4.4
* 4.3:
  Bump phpunit-bridge
2019-06-26 12:04:36 +02:00
Nicolas Grekas ac3ae812d3 Merge branch '4.2' into 4.3
* 4.2:
  Bump phpunit-bridge
2019-06-26 12:04:29 +02:00
Nicolas Grekas 37118bdcd6 Merge branch '3.4' into 4.2
* 3.4:
  Bump phpunit-bridge
2019-06-26 12:03:39 +02:00
Nicolas Grekas 85ac1a6dd5 Bump phpunit-bridge 2019-06-26 12:03:25 +02:00
Nicolas Grekas fdc2c9cbb9 Allow doctrine-bundle ^2 2019-06-13 16:30:45 +02:00
Fabien Potencier c449e6368c Merge branch '4.4'
* 4.4:
  fixed CS
  fixed CS
  fixed CS
  fixed CS
  Do not log or call the proxy function when the locale is the same
  Added missing required dependencies on psr/cache and psr/container in symfony/cache-contracts and symfony/service-contracts respectively.
  [HttpClient] fix closing debug stream prematurely
  [Mailer] made code more robust
  Restore compatibility with php 5.5
  fixed sender/recipients in SMTP Envelope
  collect called listeners information only once
  [HttpClient] add HttplugClient for compat with libs that need httplug v1 or v2
  [HttpKernel] Remove TestEventDispatcher.
2019-06-13 13:15:36 +02:00
Nicolas Grekas 28674b1e30 [HttpClient] add HttplugClient for compat with libs that need httplug v1 or v2 2019-06-11 17:49:07 +02:00
Fabien Potencier bd8d8a2cfd Merge branch '4.4'
* 4.4:
  Fix wrong requirements for ocramius/proxy-manager in root composer.json
  Change IntlTimeZone to DateTimeZone
2019-06-06 15:01:42 +02:00
Fabien Potencier 6dd72dedaa Merge branch '4.3' into 4.4
* 4.3:
  Fix wrong requirements for ocramius/proxy-manager in root composer.json
  Change IntlTimeZone to DateTimeZone
2019-06-06 15:01:21 +02:00
Fabien Potencier 495f6a3b0b Merge branch '4.2' into 4.3
* 4.2:
  Fix wrong requirements for ocramius/proxy-manager in root composer.json
  Change IntlTimeZone to DateTimeZone
2019-06-06 15:00:51 +02:00
Henrik Volmer ee98786365 Fix wrong requirements for ocramius/proxy-manager in root composer.json 2019-06-06 14:58:37 +02:00
Nicolas Grekas c0e3f27a18 Merge branch '4.4'
* 4.4:
  [Cache] Fixed undefined variable in ArrayTrait
  [HttpClient] revert bad logic around JSON_THROW_ON_ERROR
  [HttpKernel] Fix handling non-catchable fatal errors
  Fix json-encoding when JSON_THROW_ON_ERROR is used
  [HttpFoundation] work around PHP 7.3 bug related to json_encode()
  [HttpClient] add $response->cancel()
  [Security] added support for updated \"distinguished name\" format in x509 authentication
2019-06-05 15:28:50 +02:00
Nicolas Grekas d3055814ad Merge branch '4.3' into 4.4
* 4.3:
  [Cache] Fixed undefined variable in ArrayTrait
  [HttpClient] revert bad logic around JSON_THROW_ON_ERROR
  [HttpKernel] Fix handling non-catchable fatal errors
  Fix json-encoding when JSON_THROW_ON_ERROR is used
  [HttpFoundation] work around PHP 7.3 bug related to json_encode()
  [HttpClient] add $response->cancel()
  [Security] added support for updated \"distinguished name\" format in x509 authentication
2019-06-05 15:27:25 +02:00
Nicolas Grekas c402418723 [HttpClient] add $response->cancel() 2019-06-04 13:36:30 +02:00
Nicolas Grekas 80f5850939 Merge branch '4.4'
* 4.4:
  fix typo
  [Translation] fix dep
2019-05-29 10:56:48 +02:00
Nicolas Grekas d94d9d792c Bump Symfony 5.0 to PHP 7.2 2019-05-28 18:49:20 +02:00
Fabien Potencier 8869eb3521 updated version to 5.0 2019-05-28 14:18:42 +02:00
Nicolas Grekas 2c9a1960a1 Merge branch '4.3'
* 4.3:
  fix deps
  bumped Symfony version to 3.4.29
  updated VERSION for 3.4.28
  update CONTRIBUTORS for 3.4.28
  updated CHANGELOG for 3.4.28
  fix tests
2019-05-28 11:50:43 +02:00
Nicolas Grekas 08d9d43a0b Merge branch '4.2' into 4.3
* 4.2:
  fix deps
  bumped Symfony version to 3.4.29
  updated VERSION for 3.4.28
  update CONTRIBUTORS for 3.4.28
  updated CHANGELOG for 3.4.28
2019-05-28 11:50:37 +02:00
Nicolas Grekas 5bc84778f9 fix deps 2019-05-28 11:47:34 +02:00
Grégoire Pineau 519ba3cddb Merge remote-tracking branch 'origin/4.3'
* origin/4.3:
  deprecate calling createChildContext without the format parameter
  [EventDispatcher] Fix interface name used in error messages
  [FrameworkBundle] Add cache configuration for PropertyInfo
  Update dependencies in the main component
  Drop useless executable bit
  [Doctrine][PropertyInfo] Detect if the ID is writeable
  Add transport in subscriber's phpdoc
  [Validator] Autovalidation: skip readonly props
  [DI] default to service id - *not* FQCN - when building tagged locators
  [Cache] Log a more readable error message when saving into cache fails
  Update WorkflowEvents.php
  [Messenger] On failure retry, make message appear received from original sender
  [Messenger] remove send_and_handle option which can be achieved with SyncTransport
  Fixing tests - passing pdo is not wrapped for some reason in dbal
  Changing how RoutableMessageBus fallback bus works
  [Serializer] Fix BC break: DEPTH_KEY_PATTERN must be public
  [FrameworkBundle] Fixed issue when a parameter container a '%'
  Fix the interface incompatibility of EventDispatchers
  [TwigBundle] fixed Mailer integration in Twig
  [Form] Add intl/choice_translation_locale option to TimezoneType
2019-05-16 11:31:29 +02:00
David Prévot 96f4626952 Update dependencies in the main component 2019-05-13 07:53:09 +02:00
Fabien Potencier e19db439d8 Merge branch '4.3'
* 4.3:
  removed deprecated usage of some Twig features
2019-05-10 09:14:12 +02:00
Fabien Potencier e75ed98979 Merge branch '4.2' into 4.3
* 4.2:
  removed deprecated usage of some Twig features
2019-05-10 09:13:57 +02:00
Fabien Potencier 74afcd6777 removed deprecated usage of some Twig features 2019-05-10 08:54:47 +02:00
Fabien Potencier 387207f6c4 updated version to 4.4 2019-05-09 09:23:25 +02:00
Fabien Potencier e9aaaafbbb Merge branch '4.2'
* 4.2:
  [TwigBridge] Require twig ^1.40|^2.9
  [Serializer] Fix tests
  Use the apply tag instead of the filter tag
  Updated some translation files
  [Translator] Preserve default domain when extracting strings from php files
2019-04-28 08:09:58 +01:00
Fabien Potencier 454574b0a3 Merge branch '3.4' into 4.2
* 3.4:
  [TwigBridge] Require twig ^1.40|^2.9
  [Serializer] Fix tests
  Use the apply tag instead of the filter tag
  Updated some translation files
  [Translator] Preserve default domain when extracting strings from php files
2019-04-28 08:09:27 +01:00
Grégoire Paris 9c11b98d0a
Use the apply tag instead of the filter tag
The filter has been deprecated in favor of the apply tag since Twig 2.9,
see https://twig.symfony.com/doc/2.x/tags/filter.html (apply does not
seem to have its own documentation page yet).
2019-04-27 20:55:44 +02:00
Titouan Galopin 4050ec4257 [DomCrawler] Optionally use html5-php to parse HTML 2019-04-03 15:17:16 +02:00
Nicolas Grekas aabd1d455e [HttpClient] add ResponseInterface::toArray() 2019-03-09 17:49:48 +01:00
Nicolas Grekas fc83120691 [HttpClient] Add Psr18Client - aka a PSR-18 adapter 2019-03-07 17:16:39 +01:00
Nicolas Grekas 8610668c1c [HttpClient] introduce the component 2019-03-07 17:16:39 +01:00
Fabien Potencier ee787d17b4 [Mime] added classes for generating MIME messages 2019-03-02 15:10:47 +01:00
Robin Chalas 9429face97 feature #29753 [Console] Add an iterate method to the ProgressBar class (jvasseur)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[Console] Add an iterate method to the ProgressBar class

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        | https://github.com/symfony/symfony-docs/pull/10949

Add an iterate method to the `ProgressBar` class that simplify updating the progress bar when iterating over an `iterable`.

Before:
```php
$bar->start();
foreach ($iterable as $value) {
    // Process $value

    $bar->advance();
}
$bar->finish();
```

After:
```php
foreach ($bar->iterate($iterable) as $value) {
    // Process $value
}
```

Additionally if `$iterable` is countable, the progress bar max step will automatically set to its count. If it isn't countable, nothing is done (instead of setting it to 0) to allow passing a max independently before calling `iterate`.

I will try to do the doc PR soon.

Commits
-------

eb355314b0 Add an iterate method to the ProgressBar class
2019-01-31 10:53:43 +01:00
Jérôme Vasseur eb355314b0 Add an iterate method to the ProgressBar class 2019-01-30 21:33:07 +01:00
Nicolas Grekas e8a7a0e2fc Dont advertize what symfony/symfony "provides" 2019-01-24 23:02:27 +01:00
Fabien Potencier 74ca91deaa [Mime] added the component 2019-01-16 23:56:01 +01:00
Nicolas Grekas ee337dd761 Merge branch '4.2'
* 4.2:
  [Security\Http] detect bad redirect targets using backslashes
  [Form] Filter file uploads out of regular form types
  Fix CI
  minor #28258 [travis] fix composer.lock invalidation for deps=low (nicolas-grekas)
  [travis] fix composer.lock invalidation for PRs patching several components
  [travis] fix composer.lock invalidation for deps=low
  minor #28199 [travis][appveyor] use symfony/flex to accelerate builds (nicolas-grekas)
  [travis] ignore ordering when validating composer.lock files for deps=low
  minor #28146 [travis] cache composer.lock files for deps=low (nicolas-grekas)
  fix ci
  [travis] fix requiring mongodb/mongodb before composer up
  minor #28114 [travis] merge "same Symfony version" jobs in one (nicolas-grekas)
  [2.7] Make CI green
  updated VERSION for 2.7.49
  updated CHANGELOG for 2.7.49
  [HttpKernel] fix trusted headers management in HttpCache and InlineFragmentRenderer
  [HttpFoundation] Remove support for legacy and risky HTTP headers
  updated VERSION for 2.7.48
  update CONTRIBUTORS for 2.7.48
  updated CHANGELOG for 2.7.48
2018-12-06 11:37:20 +00:00
Nicolas Grekas 95e4edba92 Merge branch '4.1' into 4.2
* 4.1:
  [Security\Http] detect bad redirect targets using backslashes
  [Form] Filter file uploads out of regular form types
  Fix CI
  minor #28258 [travis] fix composer.lock invalidation for deps=low (nicolas-grekas)
  [travis] fix composer.lock invalidation for PRs patching several components
  [travis] fix composer.lock invalidation for deps=low
  minor #28199 [travis][appveyor] use symfony/flex to accelerate builds (nicolas-grekas)
  [travis] ignore ordering when validating composer.lock files for deps=low
  minor #28146 [travis] cache composer.lock files for deps=low (nicolas-grekas)
  fix ci
  [travis] fix requiring mongodb/mongodb before composer up
  minor #28114 [travis] merge "same Symfony version" jobs in one (nicolas-grekas)
  [2.7] Make CI green
  updated VERSION for 2.7.49
  updated CHANGELOG for 2.7.49
  [HttpKernel] fix trusted headers management in HttpCache and InlineFragmentRenderer
  [HttpFoundation] Remove support for legacy and risky HTTP headers
  updated VERSION for 2.7.48
  update CONTRIBUTORS for 2.7.48
  updated CHANGELOG for 2.7.48
2018-12-06 11:36:58 +00:00
Fabien Potencier 534b83f080 updated version to 4.3 2018-11-26 17:19:01 +01:00
Nicolas Grekas a42e8774d6 [Cache] added support for connecting to Redis clusters via DSN 2018-10-10 06:45:03 -07:00
Nicolas Grekas 0a1220fd96 [Cache] leverage Contracts\Cache 2018-09-04 09:24:06 +02:00
Nicolas Grekas de6329a7d9 Autoload symfony/contracts from the local repository 2018-09-01 18:41:38 +02:00
Fabien Potencier da0ef24744 feature #28231 [VarExporter] a new component to serialize values to plain PHP code (nicolas-grekas)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[VarExporter] a new component to serialize values to plain PHP code

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

This PR proposes moving what is currently the `PhpMarshaller` class in the Cache component to a separate component.

This component would provide only one public static method:
`VarExporter::export($value, bool &$isStaticValue = null): string`.

This method returns `$value` serialized as plain PHP code. Running this code creates the same exact data structure that `$value` contained. This is exactly like `serialize()` and `unserialize()`, from which all semantics are preserved (`__sleep`, `__wakeup` and `Serializable`).

The reason to use this method *vs* `serialize()` or even igbinary is performance: thanks to OPcache, the resulting code is significantly faster and more memory efficient than using `unserialize()` or `igbinary_unserialize()`.

Unlike `var_export()`, this works on any serializable PHP value.

It also provides a few improvements over `var_export()`/`serialize()`:
- the output is PSR-2 compatible
- the output can be re-indented without messing up with any `\r` or `\n` in the data
- missing classes throw a `ReflectionException` instead of being unserialized to a `PHP_Incomplete_Class` object
- references involving `SplObjectStorage`, `ArrayObject` or `ArrayIterator` instances are preserved
- `Reflection*`, `IteratorIterator` and `RecursiveIteratorIterator` classes throw an exception when being serialized (their unserialized version is broken anyway, see  https://bugs.php.net/76737.)

Commits
-------

7831ad75e5 [VarExporter] a new component to serialize values to plain PHP code
2018-08-27 18:42:24 +02:00
Nicolas Grekas 7831ad75e5 [VarExporter] a new component to serialize values to plain PHP code 2018-08-27 18:34:07 +02:00
Nicolas Grekas 7b4e5cc50b Don't "replace" symfony/contracts 2018-08-22 08:18:58 +02:00
Nicolas Grekas d0a97b40ae Merge branch '3.4' into 4.1
* 3.4:
  [DoctrineBridge] allow dev versions of Doctrine again
  bumped Symfony version to 3.4.15
  updated VERSION for 3.4.14
  updated CHANGELOG for 3.4.14
  bumped Symfony version to 2.8.45
  updated VERSION for 2.8.44
  update CONTRIBUTORS for 2.8.44
  updated CHANGELOG for 2.8.44
2018-08-01 18:22:14 +02:00
Nicolas Grekas 83dcbe9096 [DoctrineBridge] allow dev versions of Doctrine again 2018-08-01 17:25:41 +02:00
Michael Moravec cb91cdef91 Remove direct dependencies on doctrine/common 2018-08-01 14:08:31 +02:00
Fabien Potencier c1f23c859e Merge branch '4.1'
* 4.1:
  Fix tests
2018-07-19 08:48:32 +02:00
Fabien Potencier 480bf7e937 Merge branch '4.0' into 4.1
* 4.0:
  Fix tests
2018-07-19 08:48:25 +02:00
Fabien Potencier 62bb68d758 Merge branch '3.4' into 4.0
* 3.4:
  Fix tests
2018-07-19 08:48:16 +02:00
Fabien Potencier 682836da9c renamed Contract to Contracts 2018-07-13 19:06:58 +02:00
Kévin Dunglas aaf7e889f7
Fix tests 2018-07-13 14:52:14 +02:00
Nicolas Grekas 898203649f Added symfony/contracts: a set of abstractions extracted out of the components 2018-07-11 10:17:42 +02:00
Nicolas Grekas a32393ba37 Merge branch '4.1'
* 4.1:
  Add color support for Hyper terminal .
  [HttpFoundation] Fix tests: new message for status 425
  [Doctrine Bridge] Fixed usage of wrong variable when tagged subscriber is invalid
  [Workflow] Update phpdoc to fit a used className
  [PropertyInfo] added handling of nullable types in PhpDoc
  [HttpKernel] Make AbstractTestSessionListener compatible with CookieClearingLogoutHandler
  [Cache] provider does not respect option maxIdLength with versioning enabled
  [Form] Fix fixtures for forward compat
  [Lock] Fix SemaphoreStoreTest on OS X
  Ensure the class discriminator mechanism works with serialization groups as well
  fix handling of empty DI extension configs
2018-07-03 20:14:13 +02:00
Nicolas Grekas 6500560000 Merge branch '4.0' into 4.1
* 4.0:
  Add color support for Hyper terminal .
  [HttpFoundation] Fix tests: new message for status 425
  [Doctrine Bridge] Fixed usage of wrong variable when tagged subscriber is invalid
  [PropertyInfo] added handling of nullable types in PhpDoc
  [HttpKernel] Make AbstractTestSessionListener compatible with CookieClearingLogoutHandler
  [Cache] provider does not respect option maxIdLength with versioning enabled
2018-07-03 19:58:50 +02:00
Nicolas Grekas 4ce5a1bbc0 Merge branch '3.4' into 4.0
* 3.4:
  Add color support for Hyper terminal .
  [HttpFoundation] Fix tests: new message for status 425
  [Doctrine Bridge] Fixed usage of wrong variable when tagged subscriber is invalid
  [PropertyInfo] added handling of nullable types in PhpDoc
  [HttpKernel] Make AbstractTestSessionListener compatible with CookieClearingLogoutHandler
  [Cache] provider does not respect option maxIdLength with versioning enabled
2018-07-03 19:50:16 +02:00
Fabien Potencier 1aae2333d8 bug #27618 [PropertyInfo] added handling of nullable types in PhpDoc (oxan)
This PR was merged into the 3.4 branch.

Discussion
----------

[PropertyInfo] added handling of nullable types in PhpDoc

While not specified in PSR-5, PhpDocumentor does support parsing nullable types in the PHP 7.1 syntax (i.e. `?string`), and returns those in a `Nullable` wrapper type. We currently don't handle this and neither throw an error, which results in all kind of weird breakage when this syntax is used (e.g. "class string|int not found").

Correctly parse this syntax into a nullable type.

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Commits
-------

38b369be3f [PropertyInfo] added handling of nullable types in PhpDoc
2018-07-02 14:52:55 +02:00
Oxan van Leeuwen 38b369be3f [PropertyInfo] added handling of nullable types in PhpDoc
While not specified in PSR-5, PhpDocumentor does support parsing
nullable types in the PHP 7.1 syntax (i.e. ?string), and returns those
in a Nullable wrapper. We currently don't handle this and neither throw
an error, which results in all kind of weird breakage when this syntax
is used (e.g. "class string|int not found").

Correctly parse this syntax into a nullable type.
2018-07-01 23:26:09 +02:00
Nicolas Grekas 5fe78a33d8 Revert "minor #27609 Remove direct dependencies on doctrine/common (Majkl578)"
This reverts commit 92c37b9711, reversing
changes made to bc8d4f627e.
2018-06-25 13:45:21 +02:00
Nicolas Grekas 0cfbed1bbb Merge branch '4.0' into 4.1
* 4.0:
  [DoctrineBridge] blacklist doctrine/common@dev
2018-06-25 13:31:22 +02:00