The 3.10 development started during August, with two
important patches: one on the repository / entity API, another one on the boxes /
content navigation components unification (more on this later). Then it somewhat came to a halt, as more work was done on other projects and to stabilize the
3.9 branch. We finally got back on it during September, adding several other major
changes or enhancements.
Cleanup of the repository side entity API, i.e. the API you may use when
writing hooks. Beside simple namespace cleanup (a few renamings), the API has
been modified to move out attributes being edited from the read cache. So now:
- entities do not inherit from dict anymore; access to the dict protocol on an
entity will raise deprecation warnings
- the attributes cache is now a cw_attr_cache dictionary on the entity
- edited attributes are in a cw_edited attribute special object, which is only
available in hooks for a modified entity (i.e.
'[before|after]_[add|update]_entity', you should use the dict protocol on that object to get
modified attributes or to modify what is edited (in 'before' hooks only, and
this is now enforced). This deprecates the former edited_attributes attribute.
Unification of 'boxes' / 'contentnavigation' registries and base classes, into
"contextual components" stored in the 'ctxcomponents' registry. This implied the
introduction of "layout" objects which are appobjects responsible of displaying
the components according to the context they are displayed in.
This separation of content / layout and some css cleanups allows us to move former
boxes and content components into each other's place in the user interface: for
instance, go to your preferences pages and try to move the search box. You now have many
more different locations available. Though one component may not go anywhere, so
forthcoming releases should tweak this to avoid proposing dumb choices. But the hot
stuff is there!
Also, a cache has been set on the registry to avoid recomputing possible
components for each context (place in the ui).
Upgraded jQuery and jQuery UI respectively to version 1.4.2 and 1.8. Removed
jquery.autocomplete.js since jQuery UI provides its own autocomplete
plugin. A cwautocomplete plugin was added in order to keep widgets
as backward compatible as possible. If you used custom autocomplete feature,
you should take a look at this guide.
The RelationFacet base class now automatically proposes to search for
entities without the relation if this is allowed by the schema and if there
are some in current results. Example: search for tickets which are not planned in a version.
Data sources have been modeled as CubicWeb entity type CWSource. The
'sources' file is still there but will now only contains definition of the
system source, as well as default manager account login and password. This
implied changes in instance initialization commands, introduction of a new
'add-source' command to cubicweb-ctl, as well as change in the repository
startup. Also, on a multi-sources instance, we can now search using a facet on
the cw_source relation (a new mandatory metadata relation on each entities)
to filter according to the data source entities are coming from.
Although introduced during 3.9 releases, it's worth mentioning the new support
for multi-columns unicity constraint through yams's __unique_together__
entity type attribute, allowing for unicity constraint enforced by the
underlying database instead of CubicWeb hooks. This is limited and doesn't
work in every configuration, but is a must have when running several distributed
CubicWeb instance of the same application (hence database).
Also as usual, the 3.10 includes a bunch of other minor enhancements, refactorings
and bug fixes. Every introduced change should be backward compatible, except
probably some minor ui details due to the css box simplification. That's it.
So please download and install CubicWeb 3.10 and report us any problem on the