Ask Your Question
0

'AnonymousUser' object has no attribute 'tenant_id'

asked 2012-03-14 01:48:25 -0500

michael-lin gravatar image

Dear all,

I'm trying to develop my own dashboard by myself.

(Using devstack for develop)

I only rewrite the web page splash.html -> index.html, and reuse Horizon views.

But I got this error msg.

'AnonymousUser' object has no attribute 'tenant_id'

Has anyone meat this msg. before or someone can help to solve this question.

Thanks & BR,

Michael

edit retag flag offensive close merge delete

2 answers

Sort by » oldest newest most voted
0

answered 2012-03-14 09:12:18 -0500

rafadurancastaneda gravatar image

Hi,

Do you have 'horizon.middleware.HorizonMiddleware' in your MIDDLEWARE_CLASSES?? This middleware sets the user class, so it will have tenant_id=None for unanthenticated user.

HTH, Rafael

edit flag offensive delete link more
0

answered 2012-03-15 05:53:57 -0500

michael-lin gravatar image

Thanks Rafael Durán Castañeda, that solved my question.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2012-03-14 01:48:25 -0500

Seen: 112 times

Last updated: Mar 15 '12