It is not a bug. Quoting the book:
When a Field is marked with writable=False, the field is not shown in
create forms, and it is shown readonly in update forms. If a field is
marked as writable=False and readable=False, then the field is not
shown at all, not even in update forms.
This has nothing to do with the auto-(update, insert or delete)
operations performed by form.accepts
To update only the setting1 field you can do:
def edit1():
id = request.args(0)
db.mytable.setting2.readable = db.mytable.setting2.writable =
False
row = db.mytable(id)
form=SQLFORM(db.mytable, row)
if form.accepts(request.vars, formname='mytable_form',
dbio=False):
row.update_record(**form.vars)
logger.debug(db._lastsql)
return dict(form=form)
as explained in:
http://web2py.com/book/default/chapter/07#SQLFORM-without-database-IO
but it really makes no difference, except for some IO, the resulting
database record will be identical in both cases, so why bother?.