Ask Your Question

'AnonymousUser' object has no attribute 'tenant_id'

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

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,


edit retag flag offensive close merge delete

2 answers

Sort by » oldest newest most voted

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

rafadurancastaneda gravatar image


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

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

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


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

Seen: 183 times

Last updated: Mar 15 '12