在我的当地机器测试时,我会发现一些奇怪的行为:
(1) 首先,在我签字时,我把我转往主页,我看到一个闪电:
"You have signed up successfully. However, we could not sign you in because your account is unconfirmed."
我认为,当用户仅仅走上创建账户的正确道路时,就难以看到一种警告性的信息。 我可以轻松地改变当地人/发展中国家的信息,但我只是想确认,这是设计的违约行为,而不是我设置的错误吗?
2) 我成功地收到一封附有确认链接的电子邮件:
<p>You can confirm your account through the link below:</p>
<p><a href="http://localhost:5000/accounts/confirmation?confirmation_token=MywxHuW3PWHvg6x2nUfG&format=">Confirm my account</a></p>
当我点击电子邮件确认链接时,我看到了一个空白网页。
发展记录显示:
Started GET "/accounts/confirmation?confirmation_token=MywxHuW3PWHvg6x2nUfG&format=" for 127.0.0.1 at 2011-09-28 09:41:55 -0700
Processing by Devise::ConfirmationsController#show as
Parameters: {"confirmation_token"=>"MywxHuW3PWHvg6x2nUfG"}
SQL (0.9ms) SELECT a.attname, format_type(a.atttypid, a.atttypmod), d.adsrc, a.attnotnull
FROM pg_attribute a LEFT JOIN pg_attrdef d
ON a.attrelid = d.adrelid AND a.attnum = d.adnum
WHERE a.attrelid = "artists" ::regclass
AND a.attnum > 0 AND NOT a.attisdropped
ORDER BY a.attnum
Artist Load (0.4ms) SELECT "artists".* FROM "artists" WHERE "artists"."confirmation_token" = MywxHuW3PWHvg6x2nUfG LIMIT 1
SQL (0.8ms) SELECT a.attname, format_type(a.atttypid, a.atttypmod), d.adsrc, a.attnotnull
FROM pg_attribute a LEFT JOIN pg_attrdef d
ON a.attrelid = d.adrelid AND a.attnum = d.adnum
WHERE a.attrelid = "artists" ::regclass
AND a.attnum > 0 AND NOT a.attisdropped
ORDER BY a.attnum
SQL (0.2ms) BEGIN
AREL (0.9ms) UPDATE "artists" SET "confirmation_token" = NULL, "confirmed_at" = 2011-09-28 16:41:55.894603 , "updated_at" = 2011-09-28 16:41:55.895467 WHERE "artists"."id" = 85
[paperclip] Saving attachments.
SQL (0.8ms) COMMIT
SQL (0.1ms) BEGIN
AREL (0.5ms) UPDATE "artists" SET "last_sign_in_at" = 2011-09-28 16:41:55.915779 , "current_sign_in_at" = 2011-09-28 16:41:55.915779 , "last_sign_in_ip" = 127.0.0.1 , "current_sign_in_ip" = 127.0.0.1 , "sign_in_count" = 1, "updated_at" = 2011-09-28 16:41:55.916532 WHERE "artists"."id" = 85
[paperclip] Saving attachments.
SQL (0.5ms) COMMIT
Completed 406 Not Acceptable in 231ms
它说的“不可接受” 这意味着什么? 它是否通过? 发生了什么?