purplecat: Hand Drawn picture of a Toy Cat (Default)
purplecat ([personal profile] purplecat) wrote in [site community profile] dw_dev_training2012-05-13 04:04 pm
Entry tags:

Updating the Database via changes to en.dat

Me again :/ Still on bug 2152.

I wanted to change some of the labels in the settings for display. I found these in en.dat, changed them, updated the database and everything was working fine. But, all of a sudden, any new changes I make in en.dat don't appear to be getting picked up - this includes resetting everything using patch -R and updating the database* - I'm still getting my new labels turning up rather than the old ones.

What might I have done? (I did have a play with the test suites following some discussion recently and [staff profile] denise (I think) mentioned these can corrupt the database in some way).

I'm using a dreamhack, in case that's relevant.

*stop-apache

$LJHOME/bin/upgrading/update-db.pl -r -p --innodb
$LJHOME/bin/upgrading/update-db.pl -r --cluster=all --innodb
$LJHOME/bin/upgrading/texttool.pl load

start-apache
ninetydegrees: Photo: bingo chips (bingo)

[personal profile] ninetydegrees 2012-05-13 08:15 pm (UTC)(link)
Can't say why it happens or how this can be fixed but it seems to me it's a bit of a known issue which is why you're supposed to create new strings instead of editing existing ones when you want to change text. Not helpful to you now but maybe in the future.
denise: Image: Me, facing away from camera, on top of the Castel Sant'Angelo in Rome (Default)

[staff profile] denise 2012-05-13 11:41 pm (UTC)(link)
Yup, changes to existing strings aren't ever read in from en.dat and from .text files unless you run texttool.pl with a particular flag, which we don't do because it overwrites all the work that's been done on site copy through the onsite /admin/translate tool.

Convention is to remove string.name, add string.name2, and put string.name in deadphrases.dat.