Closed Bug 445248 Opened 16 years ago Closed 16 years ago

Litmus Admin Interface - prefs not sticking

Categories

(Webtools Graveyard :: Litmus, defect, P2)

defect

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: marcia, Assigned: coop)

References

Details

Attachments

(3 files)

Seen while trying to add privs for a user.

1. Query Litmus for User Name
2. Add privs to be a testday admin

User cannot see the necessary menus in order to edit testcases.

coop is on vacation but checked and says the permissions look a bit screwy. cc'ing zach for some help.
More info:

To give some more information I can add following: I saw the
additional admin menu on the left side after a re-login. But then I
went back in the history to the testcase I had opened before. Now the
menu was gone and we weren't able to get it back. Further re-logins
don't show any change. No idea if there is something wrong with cookie
handling or something else. It would be great if you could have a look
at this. If you have further questions you can also reach me on IRC.

This isn't super critical to have and could wait until coop returns from vacation, but it would nice to figure out what is going on with the admin interface.
As coop said this code is maintained by zach. So I think it's ok to assign this bug to him. YFI the person who is affected by this issue its me.
Assignee: nobody → zach
OS: Mac OS X → All
Hardware: PC → All
I'll look into this when I get home tonight. 
Status: NEW → ASSIGNED
I'm unable to reproduce this with a test account. I created a new account, and then from another browser gave that account super-user privs. I was then able to immediately see the admin menu, and nothing I did would make it go away. 

Henrik: can you try deleting your litmus_login cookie, quitting and relaunching the browser, and going back to litmus and logging in? Let me know if the admin menu is still missing for you; the appropriate bits are definitely set on your account. 
Zach, I removed my cookies for litmus and did a login but the appropriate admin menu and other stuff isn't visible. It's also happen with Safari. So I don't think that a cookie is responsible for that? 
Attached image screenshot
also no reproducible with a test account. 

Hendrik, after the login you should see the admin menu on the left side (see Screenshot) - from there you should be able to edit testcases etc.
I logged me in again and no, the menus aren't still there. See the attached screenshot. Cookies were completely deleted before.
A test with Firefox 3 on Windows shows the menu one time. But after I did a re-login it's also gone there. 
That's even more strange. Today I did a test at work. Everything was fine even after multiple logins in sequence. Perhaps I should try to take my profile at home to have a test there.
Zach, I'm here a couple more hours on IRC and can perhaps help recreate. I'm not seeing "manage users" which tracy said I should see.  I'm really in need of ability to vet and validate tests (which don't show). 

I deleted cookies. And tried with IE. No change.

Related?
- not able to manage testgroup and subgroups - "edit" is not enabled.
- Intermittently, loading the manage subgroup page, the selection choices are not selectable (missing data?).
er, I am able to edit + add testcases fine (only had one fail out of a dozen or so)
There is a session component that is stored on the database-side which may also be at fault. 

Is anyone who's had this happen to them running Litmus on multiple machines at the same time perhaps?
That could probably the cause. I also tested with different browsers at the same time on the same machine. But the really first time I used the bf cache to go back to a testcase from a former session.

Steps:
1. Open https://litmus.mozilla.org/show_test.cgi?id=5044
2. Logout
3. Set more rights for the user
4. Login again
5. Open history and go back to step 1

After step 4 I saw the admin menu but going some history entries back the admin menu was gone and doesn't appear again. Hopefully this information will help you to identify the cause.
(In reply to comment #13)
> There is a session component that is stored on the database-side which may also
> be at fault. 
> 
> Is anyone who's had this happen to them running Litmus on multiple machines at
> the same time perhaps?

litmus is active on my laptop and home. and I'm on here at work.
I did write some caching stuff that attempts to cache group permissions, but that cache is supposed to only last for one request and not persist across requests. I just rebooted the web server, which should definitely clear this cache. Any change now? 

Looking in the db, it appears all the relevant permission bits are set properly. (I only have the super-user bit set on my account and I can see the admin menu consistently.) 

I'll be on IRC around 6pm PT Friday if that didn't do the trick.
reboot did the trick. I now see all bits.  thanks zach.
Great. Henrik: does it work for you too?

There's clearly a broader issue here with Litmus::Memoize not working as intended. I'll file a separate bug on that.
Zach, yes it works for now. But I believe that similar issues will raise when rights are modified again. So we should mark this bug as depending on your newly filed bug, Zach.

I hope that we will get it correctly, but can you please remove the additional admin rights I don't need, Marcia? Or is it fine that way? I don't want to run into the same problem again. ;)
Attached patch Patch v1Splinter Review
Here's a patch that fixes this issue, at least in testing on my local machine. It ensures that the cleanup handler is set for Memoized variables. I also cleaned up a few nits in the INSTALL file while I was at it.
Attachment #331643 - Flags: review?
Attachment #331643 - Flags: review? → review?(ccooper)
Attachment #331643 - Flags: review?(ccooper) → review+
Fix checked in and production site updated. Thanks for your help everyone in figuring out what was going on here.
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Marcia, can we try to verify this fix during the Summit?
Zach: Henrik and were just testing. We removed all his privs and confirmed that they were gone. He then logged out of Litmus and I unchecked all his privs. I then went back in added his as a "Firefox Administrator." When he logged back in he does not see the menu choices to manage testcases. Can we please connect here at the Summit and try to figure out what is going on?
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Sure. Want to meet at 2 in the mozcafe? 
Zach: how important is the Memoize stuff? Would we lose much/any performance if we just ripped it out?
encountered today with thunderbird volunteeer nONoNonO
I have not heard anything from Zach on this, so I'll take a little time this afternoon and rip out the Memoize calls to see whether that fixes things. I'm not convinced it's helping us at all anyway.
Assignee: zach → ccooper
Status: REOPENED → ASSIGNED
Priority: -- → P2
Fix has landed. This entailed a web server restart, so the permissions should be fixed regardless, but I'd be interested to know whether permissions stick the next time someone tries to promote someone.
Status: ASSIGNED → RESOLVED
Closed: 16 years ago16 years ago
Resolution: --- → FIXED
Chris, many thanks for getting this in! I've tested it with the help of Marcia. All the steps I did when seeing this the first time doesn't show up the issue anymore. Looks like we have really fixed this issue! v.
Status: RESOLVED → VERIFIED
from a limted test I did earlier today, double verified
Product: Webtools → Webtools Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: