[web2py] exec_environment('applications/.../models/db.py') failing, thread._local no attr. request

2014-07-13 Thread Tim Richardson
I am trying do some multiprocessing in a scheduler job. This is web2py trunk from about ten days ago. Things in current don't seem to be inherited by the spawn process (this is on windows) So I thought I'd learn about exec_environment to see if I can set up the DAL in a python process. exec_en

Re: [web2py] Recompute all instances of a computed field

2014-07-13 Thread Johann Spies
On 10 July 2014 15:50, Fabiano Almeida wrote: > > Congratulations! > Thanks but I do not deserve the congratulation. I was helped by somebody on this list years ago to update computed fields. Unfortunately I cannot recall the name now. I think I just added the counter for my own purposes. Re

Re: [web2py] SQLFORM: 'str' object has no attribute 'writable' error

2014-07-13 Thread Manuele Pesenti
Il 14/07/14 02:27, Don O'Hara ha scritto: > I'm experimenting with the various field types (mysql) to learn more > about web2py. > I'm not sure why I got this error > > 'str' object has no attribute > 'writable' > > Version > web2py^(TM)Version 2.9.5-trunk+timestamp.2014.07.03.12.21.52 > > > Give

[web2py] Beginner question: Plain HTML file for landing page instead of web2py app

2014-07-13 Thread Alex Glaros
Are there reasons for not using a plain HTML page for user landing page and having links from it to the w2p app? Index.html would be normal HTML file, not within w2p \...\web2py\applications\myProgram\views\default folder. Main reason I'm considering this that carousel is easier to set up

[web2py] Table column/cell width not specified, unable to continue

2014-07-13 Thread 'sasogeek' via web2py-users
I'm trying to render a list of all first names in my auth_user table in a pdf but an error (the one in this question's title) slaps me in the face! Need some help figuring out how to resolve it. Controller def finish(): users = db().select(db.auth_user.ALL) return dict(users=users) View

[web2py] SQLFORM: 'str' object has no attribute 'writable' error

2014-07-13 Thread Don O'Hara
I'm experimenting with the various field types (mysql) to learn more about web2py. I'm not sure why I got this error 'str' object has no attribute 'writable' Version web2py(tm) Version 2.9.5-trunk+timestamp.2014.07.03.12.21.52 Given this table: db.define_table('test_all_fields',

[web2py] pythonanywhere

2014-07-13 Thread eric cuver
Hello, I want to run one web2py instance where each web2py application will be mapped to different domain and with ability to map some urls differently in different domains. i tried without succes -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/

[web2py] Using Selectable option in SQLFORM.grid causes grid to shrink

2014-07-13 Thread Kenwyn Pilgrim
Hi The *selectable* option works as expected, except that my grid *shrinks *from taking up the entire width of the screen to shrinking to something less than half the original width. This behaviour is seen in Chrome, Firefox & Opera. Once I remove the selectable option, the grid goes back to its

Re: [web2py] ¿How to hide app, controller and function from url?

2014-07-13 Thread Anthony
Use the parameter-based router: BASE = dict( default_application = 'init', default_controller = 'default', default_function = 'index', functions = ['list', 'of', 'functions', 'in', 'default', 'controller'] ) If you want to exclude the default function in cases where there are

Re: [web2py] Re: My gulpjs experiment to allow coffeescript jade and stylus inside web2py

2014-07-13 Thread António Ramos
maybe this helps a litle more https://github.com/ramstein74/Coffee_Jade_Stylus_inside_web2py 2014-07-13 9:17 GMT+01:00 Massimo Di Pierro : > Can you explain this to us slowly? ;-) > > > > On Saturday, 12 July 2014 17:59:10 UTC-5, Ramos wrote: >> >> after learning about gulp.js i had to do this

[web2py] Re: How can I update a row dynamically from vars?

2014-07-13 Thread Najtsirk
No, this does not work. Best, Kristjan On Sunday, 13 July 2014 08:12:57 UTC+2, Annet wrote: > > Doesn't this work? > > db.post(id=ID).update_record(FIELD=VALUE) > > > Regards, > > Annet > > -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web

Re: [web2py] How can I update a row dynamically from vars?

2014-07-13 Thread Najtsirk
Thanks! This works. On Sunday, 13 July 2014 04:05:23 UTC+2, viniciusban wrote: > > You can create a dict and pass to update: > > > def post_update(): > ID = request.vars.id > FIELD = request.vars.field > VALUE = request.vars.value > data = {FIELD: VALUE} > > db(db.post.id==ID).up

Re: [web2py] ¿How to hide app, controller and function from url?

2014-07-13 Thread Lisandro Rostagno
Thanks for the answer. I should've clarified that I knew that I had to use routes, but I'm having difficult to find the regular expression that works for this case. I suppose I have to use pattern based system, because in addition, I still want to handle "init" as the default application, "default"

[web2py] Re: My gulpjs experiment to allow coffeescript jade and stylus inside web2py

2014-07-13 Thread Massimo Di Pierro
Can you explain this to us slowly? ;-) On Saturday, 12 July 2014 17:59:10 UTC-5, Ramos wrote: > > after learning about gulp.js i had to do this > > https://www.youtube.com/watch?v=zt5gnKk40Zw > > my Gulpfile.coffee > > gulp = require 'gulp' > stylus = require 'gulp-stylus' > prefix

[web2py] Re: Enhancement : show_if in SQLFORM.factory

2014-07-13 Thread Massimo Di Pierro
please submit a bug report and we'll fix it. On Saturday, 12 July 2014 13:02:45 UTC-5, Louis Amon wrote: > > Not sure if somebody noticed before, but the show_if syntax (backed by > web2py.js) is actually breaking if you use SQLFORM.factory to generate your > form. > > > Example: > > db.define_t