Needs work
Project:
UUID Features Integration
Version:
6.x-1.x-dev
Component:
uuid_node
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
3 Feb 2011 at 12:03 UTC
Updated:
1 Jul 2014 at 15:08 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
chaps2 commentedComment #2
ryan_courtnage commentedReroll attached.
Edit: this patch has a bug - see below for newer version
Comment #3
ryan_courtnage commentedMy last upload had a bug. Attached is the proper patch.
Comment #4
ryan_courtnage commentedRerolling this patch has actually turned out to be more difficult that I thought. Implementations of the "rebuild_complete" hook can make changes to the nodes and call node_save (such as #1041932: Export node translations does). This causes a problem with nodes appearing as overridden due to timestamps - something that was fixed in #1008496: Node timestamps, options overridden and cause uuuid_node components to appear modified.
The attached patch moves #1008496's logic that updates node timestamps into it's own function. This makes uuid_node_features_rebuild() easier to read, and also allows it to handle the node timestamp updates *after* implementations of hook_uuid_node_features_rebuild_complete() are called.
Could someone please review and flag RTBC?
Comment #5
scottrigby@ryan_courtnage haven't been able to fully test this, but the db_update() in _uuid_node_features_update_node_values() should wrap $table in double braces for database prefixes:
Comment #6
scottrigbyComment #7
scottrigbyalso Ryan, I'm using your patch in #4 in combo with #1048470-4: Book export, and almost everything is working… Except have you noticed a regression of #1008496: Node timestamps, options overridden and cause uuuid_node components to appear modified with this patch? I'm now seeing 'changed', 'date', 'revision_timestamp', and 'revision_uuid' in my features diff – not sure where that's coming from yet
Comment #8
ryan_courtnage commented@scottrigby, regarding:
_uuid_node_features_update_node_values() should wrap $table in double braces for database prefixes
Not sure I've ever seen this done before. Why double braces?
Comment #9
ryan_courtnage commented@scottrigby, in response to #7, I am not having problems with timestamps in my features diff. Are you using my patch from #4 (uuid_features_rebuilt_hook-1049760-4.patch), unmodified?
The Book Export patch/comment you reference calls for the patch in comment #1 by chaps2. That patch (uuid_features-1049760.patch) will most certainly cause the timestamp problems you are seeing, as explained in my comment #4.
Comment #10
das-peter commentedI've just introduced this or better a similar hook for #1048470-15: Book export
The current implementation doesn't deal with timestamps yet. I've first to get familiar with the issue,
However, this definitely needs a re-roll anyway, so back to needs work ;)