If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

Status

Websites Graveyard
opentochoice.org
P1
normal
RESOLVED FIXED
8 years ago
7 years ago

People

(Reporter: Francois, Assigned: Javier Morales)

Tracking

Details

(Whiteboard: [wiki], URL)

Attachments

(1 attachment)

(Reporter)

Description

8 years ago
User-Agent:       Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2) Gecko/20100115 Firefox/3.6
Build Identifier: 

comments duplicated either in Dutch or as error message: "Machine translation failed. retry". Might be linked to bug 551290


Reproducible: Always
(Assignee)

Comment 1

8 years ago
I tried this in live and were able to replicate it on stage. It is not related with bug 551290. Apparently it is caused by a feature in WPML that enables the admin of a site to have the comments automatically translated to his own language. Those translations should not be shown to the not logged users, but for some reason they are being shown at the moment. 

You can see the problem replicated in stage2 at http://opentochoice2.stage.mozilla.com/2010/02/web-browser-choice-matters/
Status: UNCONFIRMED → NEW
Ever confirmed: true
(Assignee)

Updated

8 years ago
Assignee: nobody → javier.morales
(Assignee)

Comment 2

8 years ago
Created attachment 432002 [details]
SQL script that removes the duplicated comments inserted by WPML

I discover the cause of the problem. When a registered user selects in his profile to see the comments translated to his language, and goes to the single view of an article, WPML contacts google to translate the comments and add a new comment on the Wordpress comments table. Using a WPML table call wp_icl_translations we can tell which comments were translated and delete them from the comments table. 

The attached script removes the duplicate comments, but please note that if another user selects to translate comments it might happen again and the script will have to be re-executed.
(In reply to comment #2)
> Created an attachment (id=432002) [details]
> SQL script that removes the duplicated comments inserted by WPML
> 
> I discover the cause of the problem. When a registered user selects in his
> profile to see the comments translated to his language, and goes to the single
> view of an article, WPML contacts google to translate the comments and add a
> new comment on the Wordpress comments table. Using a WPML table call
> wp_icl_translations we can tell which comments were translated and delete them
> from the comments table. 
> 
> The attached script removes the duplicate comments, but please note that if
> another user selects to translate comments it might happen again and the script
> will have to be re-executed.

Filed bug 552438 to run the SQL on *stage*

Is there a way to disable this "feature" so it doesn't happen again?  We shouldn't fix this problem more than once :)
Priority: -- → P1
(Assignee)

Comment 4

8 years ago
I have not find a way to disable it Alex, I will revisit this later this week but we should run the script on production as soon as we can. 
I recommend creating a backup or a dump before running it just in case something goes wrong.
file bug 552564 to run the SQL on production.

Thanks Javier
(Assignee)

Comment 6

8 years ago
No problem Alex :)
Marking fixed and adding the [wiki] whiteboard status so that we remember to document this.
Status: NEW → RESOLVED
Last Resolved: 8 years ago
Resolution: --- → FIXED
Whiteboard: [wiki]

Updated

7 years ago
Component: opentochoice.org → opentochoice.org
Product: Websites → Websites Graveyard
You need to log in before you can comment on or make changes to this bug.