If I use the builtin wiki feature and turn on record versioning, I get error when I delete a wiki page which has a tag. Is there a way around this issue?
Recipe to duplicate the error in web2py 2.9.5: 1) Create a new application. Call it 'test_wiki'. 2) Make the following modifications: add the following two lines to the end of db.py: auth.wiki(resolve=False) auth.enable_record_versioning(db) replace the index function in default.py with: def index(): return auth.wiki() To simplify testing, comment out @auth.requires_signature() on the data function. #@auth.requires_signature() def data(): ... 3) Open the application and register as a new user: http://127.0.0.1:8000/test_wiki/default/user/register 4) Create a new page: http://127.0.0.1:8000/test_wiki/default/index/_create/index , then hit create from slug 5) Add a tag 6) Hit submit 7) Delete the wiki page using http://127.0.0.1:8000/test_wiki/default/data/delete/wiki_page/1 . This fails. It results in an internal error and a ticket. The error is "<type 'exceptions.AttributeError'> 'NoneType' object has no attribute 'id'" with a traceback of: 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. 16. Traceback (most recent call last): File "/home/mdipierro/make_web2py/web2py/gluon/restricted.py", line 220, in restricted File "D:/_PA/web2py_win/web2py/applications/test_wiki/controllers/default.py" <http://127.0.0.1:8000/admin/default/edit/test_wiki/controllers/default.py>, line 78, in <module> File "/home/mdipierro/make_web2py/web2py/gluon/globals.py", line 385, in <lambda> File "D:/_PA/web2py_win/web2py/applications/test_wiki/controllers/default.py" <http://127.0.0.1:8000/admin/default/edit/test_wiki/controllers/default.py>, line 76, in data return dict(form=crud()) File "/home/mdipierro/make_web2py/web2py/gluon/tools.py", line 3813, in __call__ File "/home/mdipierro/make_web2py/web2py/gluon/tools.py", line 4047, in delete File "/home/mdipierro/make_web2py/web2py/gluon/dal.py", line 8982, in __delitem__ File "/home/mdipierro/make_web2py/web2py/gluon/dal.py", line 10534, in delete File "/home/mdipierro/make_web2py/web2py/gluon/dal.py", line 10534, in <genexpr> File "/home/mdipierro/make_web2py/web2py/gluon/dal.py", line 8822, in <lambda> File "/home/mdipierro/make_web2py/web2py/gluon/dal.py", line 10550, in update File "/home/mdipierro/make_web2py/web2py/gluon/tools.py", line 5440, in update_tags_update AttributeError -- 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 the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.