3.0.0-beta5

Base Distribution

[BUGFIX] Use more specific version of doctrine/migrations

This pins the version to a release candidate (~1.0.0 is specified in TYPO3.Flow) instead of the dev-master version that is implied by “@dev”.

TYPO3.Eel

[FEATURE] Path filter for Fizzle grammar

Until now only object identifiers or property names (both without slashes) could be matched. This change adds support for absolute and relative paths.

[TASK] Add I18n Eel helper to provide translation methods

The Eel helper provides 3 different entry points.

  • By calling translate, you can pass all options at once
  • By calling translate with a shorthand string (PackageKey:Source:trans-unit-id), you can pass all options at once
  • By calling id or value, an object is created, that allows you to collect these options via method chaining.

The object for collection translation options implements a __toString method, so that there is no need for a finishing method call.

[BUGFIX] Fix two unknown class usages

Fixes two places where Exception was used and did not resolve to a class.

(cherry picked from commit bc94d1283f6696a929af5f6764d2227508cbcc9c)

TYPO3.Flow

[TASK] Update references in documentation

See https://jenkins.neos.io/job/Flow%20-%20Release/57/

[FEATURE] Color support for core migrations

This change allows core migrations to output colored texts. This is especially useful for errors and warnings that are likely to be overlooked due to the verbosity of core migration output.

Note:

This feature requires the posix PHP extension to be active (ANSICON/ConEmuANSI support on Windows).

[BUGFIX] Allow core migrations to be applied to non-git-repositories

Allows core migrations to be applied to packages that are not under git version control.

With this change the log for core migrations is no longer tacked through the git log history but with a new section applied-flow-migrations in the extra property of the composer manifest. This allows for keeping track of the core migration log independently from a git repository.

The git log migration history is still respected and will be imported into the composer.json file of a package as soon as core migrations are executed.

This change also introduces a new flag --force that can be specified in order to apply migrations even if the affected package is not part of a git repository or contains local changes.

Background:

This is not marked FEATURE because it fixes a severe bug that prevented migrations to be applied when having multiple packages in the same git repository.

[BUGFIX] Value objects get cascade deleted by default

Value objects are by nature not bound to single parent entities and exist by their own. Currently, Flow automatically annotates relations to value objects as cascade=’all’ and orphanRemoval=true. Doctrine itself states that orphanRemoval should only be set when the related object is privately owned and not reused by other entities, which is not generally true for value objects. See http://doctrine-orm.readthedocs.org/en/latest/reference/working-with-associations.html#orphan-removal

This leads to exceptions when entities with a relation to an value object are deleted.

This change addresses that by setting cascading to ‘persist’ only for value objects and not setting orphanRemoval on relations to value objects by default.

[BUGFIX] Tabs should be allowed in front of classes

Currently the proxy class Compiler uses a regular expression that only allows spaces before the class keyword. So a class declaration:

abstract<TAB>class Example ...

will not be correctly detected and compiled. Changing the expression to allow any kind of whitespace character fixes these edgecases.

[BUGFIX] Fix permission of temporary files when importing resources

When importing a site on Microsoft Windows 7/8 an exception can be thrown due to insufficient file permissions. This change makes sure that the file permissions are fixed before a temporary resource file is moved to its final location.

(cherry picked from commit 3cdac302dd1d2e04346493cb9926a2ade82ce01a)

[BUGFIX] Don’t skip schema validation for empty configurations

When performing a configuration validation via:

./flow configuration:validate

The validation was interrupted with an exception if one of the parsed configuration types is empty (for example because no Views.yaml file existed). This patch fixes the issue by replacing the exception with a notice that can be outputted with the verbose flag.

(cherry picked from commit 3d937c392ef6dd15382ad442b63cf411d999d132)

[BUGFIX] Do not cast NULL to empty string in PropertyConditionGenerator

Due to the escaping of NULL values, the resulting SQL query did a check against an empty string, not NULL values.

The PropertyConditionGenerator now holds the raw parameter values to check against NULL values.

[TASK] Add example configuration to disable the routing cache

While developing route part handlers it is really useful to disable the routing cache temporarily. This change adds an example configuration in composer essentials installed using the installer. This can then easily be used to create a local Caches.yaml

[BUGFIX] Relax YAML schema to allow custom requestPatterns

When using the ./flow configuration:validate command to verify that the settings conform to the configuration schema, Flow complains with:

Settings.TYPO3.Flow.security.authentication.providers.Typo3BackendProvider.requestPatterns.<pattern>
-> This property is not allowed here, check the spelling if you think it belongs here.

when using custom requestPatterns.

This change relaxes the YAML schema to allow arbitrary requestPatterns.

(cherry picked from commit d40e4b349c893580a10fda379358ad8bc8aaf0d3)

[BUGFIX] Allow Aggregate Roots to extend non entity classes

When an entity with a repository (= Aggregate Root) extends a Plain Old PHP Class (no entity) the ReflectionService produced a Undefined index notice when building the Class Schema.

This change fixes this by skipping parent classes that are not persistable.

[BUGFIX] Prevent depletion of inodes during migration

Instead of moving all files to the legacy location, creating many folders, the migration now moves resources directly to the final destination.

The second migration is a fallback for Flow installations that are not fully migrated yet.

[BUGFIX] When moving resource files, check if expected file exists

The moving of resource files in migrations Version20150611154419 and Version20150611154421 did always happen, even if the expected target did already exist. This lead to bogus warnings when a file was used by more than one Resource instance.

On top of that, empty directories were never properly removed.

[BUGFIX] Better moving of files in migration

The migration that moves resource files around (Version20141118174722 for PostgreSQL) did not consider the case of multiple resources using the same file. This change adjusts the code so it behaves like the corresponding migration for MySQL, which has better handling for this.

[BUGFIX] Correctly close all streams opened from a Resource

The resource opens a stream (e.g. file handle for the file storage) when calling getStream() using the underyling storage. It’s the callers responsibility to close the stream after consuming the content.

This change adds some missing fclose() calls and adds an error check to the ArrayConverter that results in better error messages when dealing with broken resources.

[BUGFIX] Re-enable logging of Router::route() calls

With the implementation of HTTP Components we accidentally disabled logging for calls to Router::route().

This patch adds the log() calls again.

Background:

The regression has been introduced with “[FEATURE] HTTP components for handling requests” (Iac1bd27cd1f2869e597b696c896633f14703ec40).

[TASK] Do not proxy MethodPrivilege for performance

As the method privilege is used rather often in a request even simple method calls add up. The (unecessary) proxy for the MethodPrivilege adds some overhead in form of array_key_exists calls in the __constructor inherited from the AbstractPrivilege. Disabling the proxy removes this overhead.

[TASK] Make PHP the default language for code blocks

The documentation now uses PHP as default language for code blocks, so that even when using just two colons to start a code-block it is highlighted.

[BUGFIX] Behat Subprocess command should be properly escaped

The behat subprocess command should be properly escaped to work with paths that contain special characters.

[BUGFIX] Throw 404 exception when updating a non-existing resource

Specifying a non-existing identity when converting a persistent object using the PersistentObjectConverter the PropertyMapper tries to apply conversions on the TargetNotFoundError instead of returning the error directly.

Background: The reason for this regression is the new TargetNotFoundError that has been introduced with I5231ccddaef1a6b49e62bb29bdd3ff99dc2bb994 in order to be able to handle that case more gracefully. Previously an exception was thrown directly.

[TASK] Add support for sphinx-autobuild in docs

This adds support for sphinx-autobuild, which watches the Documentation directory and automatically re-renders docs when changed. This allows for a livepreview while editing the docs. It also serves the pages via the python-livereload server so they will be automatically refreshed when the docs are re-rendered.

To use it, install sphinx-autobuild:

pip install sphinx-autobuild

To use livepreview just run make livehtml instead of make html. Then, visit http://127.0.0.1:8000 to see the livereload version of the docs.

make livehtml renders the docs exactly the same as make html does. A livereload.js script does get injected, but not by the rendering process. The script gets injected on the fly by python-livereload when serving the pages.

[TASK] Make PHP highlighting work for snippets

This adds the “official” hack to turn on startinline for all php codeblocks whether they’re a snippet or a full file.

Sphinx and docutils don’t support setting the startinline option for pygments. That means that snippets of PHP code that don’t have “<?php ?>” don’t get highlighted. The hack was documented here: http://mbless.de/blog/2015/03/02/php-syntax-highlighting-in-sphinx.html https://github.com/fabpot/sphinx-php

[TASK] Use a separate logger for I18n and missing translations

This change introduces a separate logger for I18n related messages, especially when translation labels are missing.

TYPO3.Fluid

[TASK] Detect and warn about usage of “format.json” and “uri.*” ViewHelpers

The “Consistent escaping behavior” change (FLOW-26) comes with a code migration that adjusts custom ViewHelpers to disable escaping in order to stay backwards compatible.

But the behavior of some core ViewHelpers has changed. Especially f:format.json and f:uri.* ViewHelpers now apply htmlspecialchars to their output for security and consistency reasons.

This change adds a warning for every HTML file that makes use of one of those ViewHelpers to give the developer a heads-up.

[TASK] Allow arbitrary characters in array/object keys

Allow arbitrary characters in array/object keys to support more possible keys, e.g. @action argument for the link view helper.

TYPO3.Kickstart

No changes

TYPO3.Welcome

No changes