Edgewall Software
Modify

Opened 18 years ago

Closed 17 years ago

#3693 closed defect (duplicate)

Improve error message when authentication isn't setup yet (instead of traceback)

Reported by: jeffwong@… Owned by: Jonas Borgström
Priority: normal Milestone:
Component: general Version: 0.10b1
Severity: normal Keywords: authentication
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description

I created a new project but I forgot to setup authentication in the Apache config file.

When I try to log in, I get the following error:

Traceback (most recent call last):
  File "/usr/lib/python2.4/site-packages/trac/web/main.py", line 335, in dispatch_request
    dispatcher.dispatch(req)
  File "/usr/lib/python2.4/site-packages/trac/web/main.py", line 220, in dispatch
    resp = chosen_handler.process_request(req)
  File "/usr/lib/python2.4/site-packages/trac/web/auth.py", line 95, in process_request
    self._do_login(req)
  File "/usr/lib/python2.4/site-packages/trac/web/auth.py", line 116, in _do_login
    assert req.remote_user, 'Authentication information not available.'
AssertionError: Authentication information not available.

It would be nice to have a friendlier error message like "You can't log in because authentication is not setup yet. Please ask the adminstrator of your Trac system or your system adminstrator to set up authentication."

Another solution might be to hide or disable the login link, but I like the idea of being able to find out what you can do about the situation if authentication is not enabled.

Showing the traceback right now is mystifying to the user. Even for an adminstrator, it takes a bit of work to figure out what caused the problem.

Attachments (0)

Change History (3)

comment:1 by Matthew Good, 18 years ago

The login link cannot be automatically disabled because Trac has no way of knowing whether you've configured authentication on your server or not.

comment:2 by sid, 17 years ago

Keywords: authentication added
Summary: Crash when trying to log in and authentication isn't setup yetImprove error message when authentication isn't setup yet (instead of traceback)

A friendlier error message for this specific case would be nice though. It seems to be quite common. There are 26 tickets on t.e.o. about this error, and nearly 350 hits when doing a google search on it.

comment:3 by Emmanuel Blot, 17 years ago

Resolution: duplicate
Status: newclosed

I think christian has already improved the error message some time ago, see #3839.

Feel free to re-open if you think the message is not explicit enough.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Jonas Borgström.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Jonas Borgström to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.