Posted by jschlick on March 1, 2012 at 10:10pm
20 followers
| Project: | Entity cache |
| Version: | 7.x-1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | needs work |
Issue Summary
When I edit a node (any content type) and attempt to add a translation, a duplicated version of the content is created and is not linked to the original node. (Editing the original node shows that the "translation" is not actually linked.)
Strangely, I believe this was working correctly at one point on the site in question. Anyone experienced a similar issue? Could it be the database?
Comments
#1
Yes, I'm experiences the same. The nodes are not linked together.
UPDATE: I disabled the Synchronize translations module, and then everything works as expected. It looks like some of the fields I have specified have problems with synchronizing, and the linking is therefore not completed. I will investigate some more.
#2
Has there been and progress with this?
#3
We need to know about which fiels cause this with i18n_sync.
#4
Closing, no follow up. Please reopen when you can post the missing information (which fields).
#5
i can confirm it. i am testing now what fields cause that and report back. it seems it happens if you chose body . i created a node and translated it. source EN, to DE. then i turned on sync body. returned to the node and switched from EN to DE (language switcher) then connection is lost between the two.
#6
Notes:
1.) Enable translation for Basic Page, save
2.) Create a node of this type in EN (EN is default language)
3.) Hit translate tab and click "add translation" (this case german), save node.
Checking the node object of the translated node(DE): http://www.root.artwaves.de/screensnapr/1338400760-jr6EFk.jpg
now at the url of the translated node de/page/deeee the language switcher block shows to languages EN/DE, hit EN. Language switcher now only shows EN.
Checking node object: http://www.root.artwaves.de/screensnapr/1338401226-GeqfCD.jpg
Question
The source node should have tnid = nid? meaning pointing to itself (see above image, its not)
http://www.root.artwaves.de/screensnapr/1338401161-J4k6ha.jpg
#7
Solution
Disable entity cache for nodes! #1360042: Make Entity Cache configurable?
Thanks to webflo
Related too: #1405234: Implement update hooks for node translation sets. Clean-up node translation sets.
#8
As e-anima says, the source node should have its own nid as tnid. Once I figured out that this was the cause of the problem, the solution was actually quite simple and Entity Cache can still be enabled. I created a patch for this which seems to work well, read more about how I solved it at http://storleden.se/blogg/solution-fundamental-tnid-issue-i18n
#9
The last submitted patch, fixtnid-1463402-8.patch, failed testing.
#10
Wow, it certainly is not easy to create a patch that passes automated testing!
#11
So how is this proceeding? Still having this issue.
#12
I don't think there's been any more progress on this. The patch failed testing on:
Would be good to find someone to rebuild the patch with new test cases though.
#13
In the meanwhile patch #8 solved this problem :-)
#14
Re-test on dev branch.
#15
#8: fixtnid-1463402-8.patch queued for re-testing.
#16
The last submitted patch, fixtnid-1463402-8.patch, failed testing.
#17
Ok, so we need to adjust the i18n_node.test on line 50 & 62 so that I18nNodeTestCase->testAddContentToTranslationSet() returns the correct value.
This patch has been sitting there since June. Can someone please re-roll another one against the current dev version of the code?
#18
I have some concerns about this patch...I think the solution should be in entity cache and not i18n. We encountered this issue recenty and in looking into it the tnid getting set on the translation group is being done by the core translation module. Going in with a hook and re-writing it after seems like a bit of a workaround for a more systemic problem that exists within entity cache which causes a problem with core translation.
#19
Agree with #18
Since this is something between Content translation (core module) and Entity cache, moving to Entity cache module.