Page MenuHomePhabricator

Register new email: Cannot format velocity template com/google/gerrit/server/mail/RegisterNewEmail.vm
Closed, ResolvedPublic

Description

Trying to go to

Settings > Contact Information > Register New Email

Enter some email address

Result:

Cannot format velocity template com/google/gerrit/server/mail/RegisterNewEmail.vm

Cannot find this bug upstream, maybe our .war got botched (or didn't unpack properly in $HOME/.gerritcodereview?


Version: unspecified
Severity: normal
URL: http://code.google.com/p/gerrit/issues/detail?id=1436

Details

Reference
bz36632

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 12:20 AM
bzimport added projects: Gerrit, Upstream.
bzimport set Reference to bz36632.
bzimport added a subscriber: Unknown Object (MLST).

Hrm, we haven't customized any of the templates so this is presumably an upstream bug :(

This doesn't seem to be affecting master as far as I can tell. Need to check 2.4. If it's not fixed there, maybe we can ask for a backport to the 2.3 or 2.4 branch.

Can't repo on a fresh new Gerrit 2.4 install.

The content of the gerrit logs/error.log file should be checked to get more information.

Removing upstream as the bug is unconfirmed in a upstream LDAP installation.

Can't be confirmed in 2.4 or 2.5 (master). Presumably this will be solved on upgrade, so adding the dependency.

Looks like a regression. I successfully added a new Email address before we upgraded to 2.3.

(In reply to comment #6)

Looks like a regression. I successfully added a new Email address before we
upgraded to 2.3.

Regression in 2.3, perhaps. Since I can't replicate in 2.4 or 2.5, presumably it was fixed.

I don't see any specific mention in the release notes[0], but that doesn't mean it wasn't done.

[0] http://gerrit-documentation.googlecode.com/svn/ReleaseNotes/ReleaseNotes-2.4.html

Not sure if there were any substantial changes in the file in the project history.

Maybe it's an integration problem (wrong velocity library version) or something went wrong when packing JARs together?

$ git log --format="%H (%ci) %s" -- gerrit-server/src/main/resources/com/google/gerrit/server/mail/RegisterNewEmail.vm

d6bd00b5eb834e90b53ad954e32c4a4ba6d77e5e (2012-01-23 11:13:47 -0800) Improve validation of email registration tokens
392ef85e0cad3d2de00d009cb4919d94b984f732 (2011-10-18 12:18:19 -0700) Correct example typo
6ba66e0c9d37ce4b65dce7f47a38f2ac53e255e2 (2011-06-27 09:59:27 -0700) Modernize URLs to be shorter and consistent
679fc379c8d2f397d7e24445968f390d0e2f12b3 (2010-08-12 13:46:53 -0600) Convert 3 email classes to file based templates.

d6bd00b5eb834e90b53ad954e32c4a4ba6d77e5e is present in v2.3, v2.3-rc0 and v2.4-rc0 (as well as master)

6ba66e0c9d37ce4b65dce7f47a38f2ac53e255e2 was the last one in v2.2.2

Would be also good to check if we have something in $site_dir/etc/mail (or if putting a fresh RegisterEmail.vm there solves the problem)

(In reply to comment #9)

Would be also good to check if we have something in $site_dir/etc/mail (or if
putting a fresh RegisterEmail.vm there solves the problem)

We do not have anything currently in etc/mail, we're relying on the compiled defaults.

I'd rather not put a new template in production just yet--let's downgrade the labs install to 2.3 and attempt to replicate it first.