Wiki.auth 401 error

178 views
Skip to first unread message

jimbo

unread,
Dec 22, 2013, 2:54:25 PM12/22/13
to web...@googlegroups.com
This used to work, activate the built in wiki, then register, log in and I got the wiki available. Now when I try to make a new wiki I get 401 even though it lets me log on.

Tried today and I get a 401 error when app accesses /default/index/_create/index


Thanks, Jimmy

Alan Etkin

unread,
Dec 22, 2013, 4:06:00 PM12/22/13
to web...@googlegroups.com

This used to work, activate the built in wiki, then register, log in and I got the wiki available. Now when I try to make a new wiki I get 401 even though it lets me log on.

With what version?

jimbo

unread,
Dec 22, 2013, 6:01:26 PM12/22/13
to web...@googlegroups.com
Hi Alan, it's 2.8.2   Thanks

Alan Etkin

unread,
Dec 23, 2013, 1:05:06 PM12/23/13
to web...@googlegroups.com
Hi Alan, it's 2.8.2

I think we need to see the source; I tried to reproduce it, but couldn't.

My system environment:
2.8.2-stable+timestamp.2013.12.20.15.08.47
(Running on Rocket 1.2.6, Python 2.7.3)

jimbo

unread,
Dec 23, 2013, 6:37:41 PM12/23/13
to web...@googlegroups.com
Thanks again Alan, will play about with it over Xmas. I am running on Pythonanywhere.

As I said, the built in Wiki worked when I tried it several months ago.

Cheers!

On Sunday, 22 December 2013 19:54:25 UTC, jimbo wrote:

wale...@gmail.com

unread,
Jan 8, 2014, 5:12:54 PM1/8/14
to web...@googlegroups.com
Jim and Alan,

I have the exact same problem, and exact same error.  my setup is simple: using the latest "web2py_win" (as of December 2013) and followed the book "web2py_manual_5th".  The instructions in section 3.5 will guide you to use the built in wiki, and if you follow these instructions you will get the same error mentioned here.

I played around with it and I have not been able to figure out why.  A fix would be nice.....please post an update if you figure it out.

Regards,
Waleed

Alan Etkin

unread,
Jan 8, 2014, 6:07:31 PM1/8/14
to web...@googlegroups.com
Jim and Alan,

I have the exact same problem, and exact same error.  my setup is simple: using the latest "web2py_win" (as of December 2013) and followed the book "web2py_manual_5th".  The instructions in section 3.5 will guide you to use the built in wiki, and if you follow these instructions you will get the same error mentioned here.

Could you try the example with trunk, i.e. the latest repo source code version? This way we can confirm it was "fixed" (or better, cannot be reproduced) in future versions. As of now, I cannot test the book howto with a win machine. Perhaps this is just reproducible with windows.

jimbo

unread,
Jan 10, 2014, 7:50:46 PM1/10/14
to web...@googlegroups.com
Pretty much give up on this, the wiki looked very promising when i first tried it, seems to be dead now,


Which is a pity as it looked a very good option when it was working.


On Sunday, 22 December 2013 19:54:25 UTC, jimbo wrote:

Alan Etkin

unread,
Jan 11, 2014, 6:06:14 AM1/11/14
to web...@googlegroups.com
Pretty much give up on this, the wiki looked very promising when i first tried it, seems to be dead now,

Still unable to reproduce the issue with Version 2.8.2-stable+timestamp.2014.01.09.11.46.01 in development.

Mind that you must have permission to create wikis. Check that there is a wiki_editor or wiki_author membership in the app database applied to your user. Also check that when creating the app in development, you have access to the admin app, otherwise the automatic permission creation can fail.

If you think this is an environment specific problem, file an issue at http://code.google.com/p/web2py and we'll try to fix it asap.

galoshes

unread,
Jan 28, 2014, 6:28:51 PM1/28/14
to web...@googlegroups.com
I also got the 401 error (version 2.8.2, Windows) when I first installed the wiki.

After comparing with a previous version (2.7.4), it looks like in version 2.8.2, the wiki_editor group is not automatically created in db.auth_group.
The wiki works fine when the group is added in and the user is assigned membership to the group (through appadmin).

Waleed A

unread,
Jan 28, 2014, 11:08:03 PM1/28/14
to web...@googlegroups.com, web...@googlegroups.com
 Any chance for steps on how to do that ? (For us that are new o web2py)

-wa
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
---
You received this message because you are subscribed to a topic in the Google Groups "web2py-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/web2py/IUjoJrddE4Y/unsubscribe.
To unsubscribe from this group and all its topics, send an email to web2py+un...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Alan Etkin

unread,
Jan 29, 2014, 4:46:25 AM1/29/14
to web...@googlegroups.com
 Any chance for steps on how to do that ? (For us that are new o web2py)

- Start the rocket built-in server (see the manual for instructions for windows)
- Open the admin app and authenticate
- Go to the app base address at http://localhost:8000/<app name> and register

web2py should now have created a wiki_editor and assigned the new user to the editor group. If not:

- Go to http://localhost:8000/<app name>/appadmin
- Click in the auth_group table (it opens a view of the table)
- Check that there is a group named wiki_editor, otherwise create it (by clicking in the new record button)
- Go to appadmin again and open the auth_membership view
- Create a membership record that links the wiki_editor group and your auth_user id

Mirek Zvolský

unread,
Jan 15, 2016, 5:51:18 AM1/15/16
to web2py-users
2 years later I receive same error 401 UNAUTHORIZED at http://localhost:8000/<application>/activity/wiki/_create/index
I made about 6 new empty applications and made some testing with auth.settings.create_user_groups and .extra_fields, but with no catch yet - always wiki works fine.
But fails with my relative new/empty application. I will work on it later and I hope I will find the reason, because it must be something very interesting...





Dne neděle 22. prosince 2013 20:54:25 UTC+1 jimbo napsal(a):

Mirek Zvolský

unread,
Jan 18, 2016, 3:53:18 AM1/18/16
to web2py-users
Now I am sure that this behavior has nothing common with Web2py/wiki code.

If you have an application with Sqlite database, please be patient if you play with it and decide recreate it so that you delete the content of database/ folder completly.
In such case delete always sessions/ folder too.

If you start with old sessions/, this will cause this error with auth.wiki and maybe lot of additional strange errors.

As next step for auth.wiki remember to create the view if you move the wiki to different controller as default/index (it should containt only/at least {{=content}} - see book).

I undestand that this error with old sessions is basic thing.
But it can make lot of pain for novices.
Couldn't be possible to implement something into Web2py to prevent such situation: if database/ folder empty and session/ folder not empty then halt with message (or delete sessions/ automatically) ....?




Dne pátek 15. ledna 2016 11:51:18 UTC+1 Mirek Zvolský napsal(a):
Reply all
Reply to author
Forward
0 new messages