[web2py] web2py + gae + google:sql : Not authorized to access (database) instance

2014-02-28 Thread Christian Foster Howes
It's been some time since I connected to cloud SQL myself, but I would suggest triple check the connection string and permissions. You should not have to connect with any other client first. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/w

[web2py] Passing a Variable into a Query

2014-02-28 Thread Travis May
First of all, be easy on me, I'm new to coding and new to web2py. I am trying to get some data from the database with the following function: def db_query(db_name, db_record, db_field, length): query = (db.db_name.Financial_Institution==auth.user.id)&(db.db_name.Completed==1) db_record

[web2py] Re: SQLFORM.grid pagination and messed up URL

2014-02-28 Thread Anthony
If the base URL for the grid includes args, you have to tell the grid to preserve those args when it generates its own URLs. For example: grid = SQLFORM.grid(..., args=request.args[:2]) Anthony On Friday, February 28, 2014 8:18:04 PM UTC-5, horridohobbyist wrote: > > I have a SQLFORM.grid with

[web2py] SQLFORM.grid pagination and messed up URL

2014-02-28 Thread horridohobbyist
I have a SQLFORM.grid with pagination. It's in a webpage with the following URL: https://mydomain.com/myapp/admin/view_client/auth_user/3 When you go to the next page of the grid, the URL becomes: https://mydomain.com/myapp/admin/view_client?page=2 However, this is patently wrong! The URL shou

[web2py] Re: postgres beginner questions: passwords, peer authentication, dev/production

2014-02-28 Thread Dave S
On Wednesday, February 26, 2014 8:14:55 PM UTC-8, Dave S wrote: > > > > On Wednesday, February 26, 2014 7:51:20 PM UTC-8, Dave S wrote: >> >> >> >> On Wednesday, February 19, 2014 12:15:20 PM UTC-8, Joe Barnhart wrote: >>> >>> I have a model file "0_globals.py" which I have under source control.

[web2py] Re: SQLFORM.grid to update page

2014-02-28 Thread Tim Richardson
In my slice on inline-editable grid (http://www.web2pyslices.com/slice/show/1928/basic-inline-editing-in-sqlformgrid-no-plugin-no-javascript) I do this to reload redirect(URL('default','editable_grid',vars=request._get_vars)), ) #preserving _get_vars means user goes back to same grid page, same s

[web2py] Re: Retrieve Membership information for User

2014-02-28 Thread Julio F Schwarzbeck
Awesome, exactly what I was looking for Anthony, thanks! On 02/28/2014 09:42 AM, Anthony wrote: auth.user_groups should be a dict like {group id: role, ...} Anthony On Friday, February 28, 2014 12:03:45 PM UTC-5, Julio F. Schwarzbeck wrote: Folks, is there an API (couldn't find it)

[web2py] Re: pythonanyware Tornado connection refused

2014-02-28 Thread António Ramos
ERRORThe requested URL could not be retrieved -- The following error was encountered while trying to retrieve the URL: http://ramstein74.pythonanywhere.com:/ *Connection to 50.19.109.98 failed.* The system returned: *(110) Connection timed out* The remote host or

[web2py] pythonanyware Tornado connection refused

2014-02-28 Thread António Ramos
Hello i´m trying pythonanywhere and i cannot connect my client to tornado messaging console. I did what i normaly do in \gluon\contrib python websocket_messaging.py -k mykey -p when i load my page i see in the console that the connection was refused. What am i missing? Thank you António

[web2py] Re: run web2y scheduler instances on 2 or more servers

2014-02-28 Thread Andrey K
Thank Niphlod for your answer. it is already great if it is possible even theoretically! Regarding implementation. Correct me please if I am wrong in following understanding - am I right that I need to: 1)copy the whole web2py and myapp with necessary libs to another server . 2)set up db connecti

[web2py] Re: need help with query

2014-02-28 Thread Niphlod
your request kinda "sound" bad. if you want to: - filter by id_status - group by id_reperaties - count lines then it's fine. "That have the newest item" is the part that doesn't sound right. "The newest item" is always going to be one and only one, so counting would just return 1 for every g

[web2py] Re: Weird truncate performance problem after upgrade to 2.8.2

2014-02-28 Thread Niphlod
wait a second... - DROP - TRUNCATE - DELETE what are you doing in web2py and what are you issuing via sqlite3 cmdline exactly ? On Thursday, February 27, 2014 8:57:43 PM UTC+1, Rene Dohmen wrote: > > We now did a drop outside of web2py. That's very fast. > > In the web2py logs we only see: >

[web2py] Re: FYI: DAL accepts a variety of connection strings based on the underlying driver

2014-02-28 Thread Niphlod
it's like that only for pyodbc drivers. On Thursday, February 27, 2014 11:20:56 PM UTC+1, dlypka wrote: > > FYI. Although few if any examples are documented, it is possible to for > example to connect to Microsoft SQLExpress this way > > connStr = ( > r'Driver={SQL Server};' + >

[web2py] Re: How to install some old version of web2py?

2014-02-28 Thread Niphlod
+1 for git but one doesn't need knowledge just to download versions. github serves out 29 releases up until 2.0.2 (2 years ago) and google code to 1.77.1 (whoa, 4 years ago) Just "tested" it, takes for github - 1 click on this link https://github.com/web2py/web2py/releases - 1 click on the provi

[web2py] Re: run web2y scheduler instances on 2 or more servers

2014-02-28 Thread Niphlod
the scheduler is designed also to support such cases. You can spin off whatever no. of workers you want from wherever you'd like. The only thing that needs to be reachable is the database where the scheduler tables are. you'll just have to copy your web2py folder (all the framework, plus the app

Re: [web2py] workflow recipe

2014-02-28 Thread Richard Vézina
https://groups.google.com/forum/#!msg/web2py/Ww-dcs3xTOM/dflPZ0SlXxMJ Like tools Niphold as propose and Cliff answer is true... Richard On Fri, Feb 28, 2014 at 11:53 AM, Kiran Subbaraman < subbaraman.ki...@gmail.com> wrote: > Manuele, > This is something that I would find useful - this sort of

Re: [web2py] Re: Best practices for using mercurial within web2py

2014-02-28 Thread Dave S
On Friday, February 28, 2014 9:27:50 AM UTC-8, Mark Graves wrote: > > Thanks for the replies. > > I am using web2py as a front end for bitbucket and mercurial. Mercurial > is managing multiple repos on my site. I click a button to pull new code > in from bitbucket. > > The way I am currently

[web2py] Re: Retrieve Membership information for User

2014-02-28 Thread Anthony
auth.user_groups should be a dict like {group id: role, ...} Anthony On Friday, February 28, 2014 12:03:45 PM UTC-5, Julio F. Schwarzbeck wrote: > > Folks, > > is there an API (couldn't find it) it Auth that returns the memberships > that the user belong to?, I guess something like: > > member

[web2py] SQLFORM.grid to update page

2014-02-28 Thread horridohobbyist
I have a SQLFORM.grid and I would like to add a link or function to each row that will do something and immediately refresh/update the webpage. Is this possible? Thanks. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) -

Re: [web2py] Re: Best practices for using mercurial within web2py

2014-02-28 Thread Mark Graves
Thanks for the replies. I am using web2py as a front end for bitbucket and mercurial. Mercurial is managing multiple repos on my site. I click a button to pull new code in from bitbucket. The way I am currently doing it is passing a path into a subprocess which runs mercurial commands to do the

[web2py] input validation

2014-02-28 Thread Asimionese Alexandru
hi, it's possible to validate an input after ai inserted it in a form? auth_form = auth.register() auth_form.custom.widget.ebayusername = INPUT(_name='ebayusername', _type='text', requires=IS_NOT_EMPTY()) auth_form[0].insert(-1, auth_form.custom.widget.ebayusername) response.view = 'registrat

[web2py] Retrieve Membership information for User

2014-02-28 Thread Julio F Schwarzbeck
Folks, is there an API (couldn't find it) it Auth that returns the memberships that the user belong to?, I guess something like: memberships = auth.get_memberships() Returning a list or dict of objects/tuples/etc with ids and names or something similar.. I understand that this could be acc

Re: [web2py] workflow recipe

2014-02-28 Thread Kiran Subbaraman
Manuele, This is something that I would find useful - this sort of document workflow is useful in content-management scenarios. Took a look at the recipe - got a general idea of what you have done. Still building up my competency in Python to better understand this. I was wondering if something

Re: [web2py] 9.1 sql no bufferspace error

2014-02-28 Thread Richard Vézina
Use a Linux box :-P Richard On Thu, Feb 27, 2014 at 2:47 AM, shivakrishna paloju < shivakrishnapol...@gmail.com> wrote: > > am getting error as no buffer space available and is the server running on > host 172.-.-.-. and tcp/ip connections on port 5432? > iam using xp os and 9.1 sql server > >

[web2py] Issue with scheduler documentation

2014-02-28 Thread Rémy Reche
Hello, There is an issue with the parameter prevent_drift from the method scheduler.queue_task. This paramater does not exist in the current version although it is mentionned in the doucmentation. According to the git repository, it was added in trunk after the release 2.8.2 (see https://g

[web2py] Re: AJAX component reload problem using .html vs .load

2014-02-28 Thread Dan M
I abridged the code to make it easier to diagnose. Yes, at the beginning of the controller a0=request.args(0). Sorry, the click handler is vestigial, as AJAX reload obviates the need for it. TIP_APP as well is just old and haven't cleaned that up. Thank you for pointing these out! Your resp

[web2py] Re: Website + Web2py

2014-02-28 Thread fsp
Hi, there are multiple ways.. This are the two easiest ways.. 1) Use PHP -> write a index.php and put it on a webserver http://www.wherever.com/'); ?> 2) Use apache mod_rewrite (redirect permanent) king regards fsp -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) -

[web2py] 9.1 sql no bufferspace error

2014-02-28 Thread shivakrishna paloju
am getting error as no buffer space available and is the server running on host 172.-.-.-. and tcp/ip connections on port 5432? iam using xp os and 9.1 sql server -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - http

[web2py] Re: bug in dbnew part of ticket-system fixed

2014-02-28 Thread Rémy Reche
Hello, this bug still exists in the version 2.8.2 (line 1518 now). On Tuesday, August 21, 2012 3:06:37 PM UTC+2, Massimo Di Pierro wrote: > > This should already be fixed in trunk. Thanks for reporting it. > > On Tuesday, 21 August 2012 05:25:49 UTC-5, sunny wrote: >> >> hi, >> >> i came acros

[web2py] web2py + gae + google:sql : Not authorized to access (database) instance

2014-02-28 Thread Mike England
I have started working with web2py + gae and a Cloud SQL database. The application db connection string is : db = DAL('google:sql://cloud1:ctm-manager/ctmdb') Logs on GAE show the following: File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/storage/speckle/python/api/rdb

[web2py] need help with query

2014-02-28 Thread servicepunt . drachten
Hi, I have the following table: db.define_table("track_trace", Field("id_reparaties", "reference reparaties", requires=[IS_IN_DB(db, 'reparaties.id')]), Field("id_status", "reference status"), Field("opmerking", "string", default=""),

[web2py] Re: Customizing SQLFORM.grid create, edit and update forms

2014-02-28 Thread Maciej S
Hi! I've created SQLFORM.grid like whowhywhat did. New elements have been added to the form, but there is one drawback, if I submit, all data from new fields is lost. What should I do to keep it during callbacks? Here is my code: def users(): grid = SQLFORM.grid(db.auth_user) i

[web2py] Problem to run Java applet on web2py server

2014-02-28 Thread Joel Couelier
Hi all, I am running web2py on a raspberry PI and i want to include the video stream of a dlink camera into a html page on my project. So , i have created a html page (test.html) on views/default and i have inserted the following code into this page : http://192.132.1.56:80"; archive="aplug.j

[web2py] Re: field inheritance

2014-02-28 Thread Anthony
db.mytable.myfield.clone(name='newname', ...) The .clone() method makes a copy of the Field object, and if you want to alter any of the attributes, they can be passed as keyword args (e.g., the above example changes the field name to "newname"). Anthony On Friday, February 28, 2014 4:04:59 AM

[web2py] parse_as_rest combined with accessible_query

2014-02-28 Thread Zbigniew Pomianowski
I know I can build standard queries, but is it possible to combine *parse_as_rest(patterns, args, vars)* with *auth.accessible_query(action, table)*? -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.

[web2py] workflow recipe

2014-02-28 Thread Manuele Pesenti
Hi, I noticed in the past some threads in this group about a workflow implementation for web2py framework... in theese two days I needed to understand in case I need a workflow engine for a web application how can it be realized inside web2py. I found that docflow[1] could be a nice solution to a

[web2py] Re: GAE / Memcache consistency minor change request.

2014-02-28 Thread Massimo Di Pierro
Can you please open a ticket so we will get this done asap? On Wednesday, 26 February 2014 15:15:39 UTC-6, Matt wrote: > > Hi there, > > I've noticed a small variation between two parts of web2py. > > The memcache client MemcacheClient in gluon.contrib.memcache.__init__.py > supports the ability

[web2py] run web2y scheduler instances on 2 or more servers

2014-02-28 Thread Andrey K
Good day, I am working on the application that requires run background scripts on user demand. At the moment I have implemented it as native web2py job scheduler. If the demand will be high enough my server would not be able deliver all tasks in reasonable time. Thus I am looking the way to dest

[web2py] Re: Where does Apache HTTP server stores incoming request's data

2014-02-28 Thread LightDot
Well, if files under /var/log/httpd are empty, then apache is either set up not to log anything or it's set up to log to another location. Third possibility would be that it isn't serving requests at all... No way of knowing really, without looking at apache configuration files. How do you have

[web2py] Where does Apache HTTP server stores incoming request's data

2014-02-28 Thread Gliese 581 g
I have Apache HTTP server configured on Linux machine. I am sending requests to it from my Windows machine. I want to check the contents of incoming request. Where does it stores the data of incoming request? I have checked it on my Windows machine where it uses *C:\Users\username\AppData\Local

[web2py] Re: Website + Web2py

2014-02-28 Thread Alex
I'd go with what's easier to maintain. If the static website is somehow related to your web2py app then I'd create it as a web2py static page. Should be less work :) Alex Am Donnerstag, 27. Februar 2014 02:56:12 UTC+1 schrieb Carlos Zenteno: > > I would like to have a website in front of web2p

[web2py] Re: field inheritance

2014-02-28 Thread mcamel
Has field inheritance been implemented?. I'd swear it was, but i cannot find it... Now i use dummy tables for this, but i have to define different dummies to get different combinations of names and amount of fields of these types on each table. Regards. El miércoles, 24 de agosto de 2011 17:

[web2py] Re: How to install some old version of web2py?

2014-02-28 Thread Tim Richardson
On Friday, 28 February 2014 06:39:07 UTC+11, Niphlod wrote: > > 1 year and a couple of months later still my recommendations are valid :P > In other words, learn git and then you can effortlessly move between any version you want. The time spent learning this is a huge payoff. mercurial is pro