We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I think it is related to this change in web2py: http://code.google.com/p/web2py/source/detail?r=a942e058c684987c211f13739b32f6308941f521
I updated web2py and accessing a book's index (via the menu) throws a format error in default.py line no. 101
I fixed the book error by using an int 0 by default for the chapter number instead of the "0" string:
diff --git a/controllers/default.py b/controllers/default.py index 594eab2..c363439 100644 --- a/controllers/default.py +++ b/controllers/default.py @@ -94,7 +94,7 @@ def calc_date(now=request.utcnow.date()): return now.strftime(format) def chapter(): - book_id, chapter_id = request.args(0), request.args(1,cast=int,default='0') + book_id, chapter_id = request.args(0), request.args(1, cast=int, default=0) subfolder = get_subfolder(book_id) info = cache.ram('info_%s' % subfolder, lambda: get_info(subfolder), time_expire=TIME_EXPIRE) chapters = cache.ram('chapters_%s' % subfolder, lambda: get_chapters(subfolder), time_expire=TIME_EXPIRE)
The text was updated successfully, but these errors were encountered:
fixed by Alan
Sorry, something went wrong.
No branches or pull requests
I think it is related to this change in web2py:
http://code.google.com/p/web2py/source/detail?r=a942e058c684987c211f13739b32f6308941f521
I updated web2py and accessing a book's index (via the menu) throws a format error in default.py line no. 101
I fixed the book error by using an int 0 by default for the chapter number instead of the "0" string:
The text was updated successfully, but these errors were encountered: