[web2py] Re: Unsigned int in DAL

2012-11-17 Thread Joseph.Piron
2 21:46:09 UTC+1, Niphlod a écrit : > > > > On Friday, November 16, 2012 9:23:33 PM UTC+1, Joseph.Piron wrote: >> >> No I can't, here I have to stock and let the user enter 2**31 and not >> 2**31-1 >> As everything else is possible, shouldn't it be pos

[web2py] Re: Unsigned int in DAL

2012-11-16 Thread Joseph.Piron
ay, November 16, 2012 4:12:45 PM UTC, Joseph.Piron wrote: >> >> Hi all! >> >> I have quite a problematic issue, I would like to know how to define a >> Field as unsigned in the DAL ? >> I tested: >> Field('triggerValue', 'unsigned integ

[web2py] Unsigned int in DAL

2012-11-16 Thread Joseph.Piron
Hi all! I have quite a problematic issue, I would like to know how to define a Field as unsigned in the DAL ? I tested: Field('triggerValue', 'unsigned integer', requires=IS_NOT_EMPTY(),notnull =True), and Field('triggerValue', 'integer', unsigned=True, requires=IS_NOT_EMPTY(),notnull =

[web2py] Re: Add count in db.parse_as_rest output

2012-05-18 Thread Joseph.Piron
Isn't it possible ? :( Le lundi 23 avril 2012 10:26:35 UTC+2, Joseph.Piron a écrit : > > Hi guys! > > I am using the wonderful db.parse_as_rest function in my development and > like to ask if it is possible to push a modification in the trunk as as to > be able to go

[web2py] Add count in db.parse_as_rest output

2012-04-23 Thread Joseph.Piron
Hi guys! I am using the wonderful db.parse_as_rest function in my development and like to ask if it is possible to push a modification in the trunk as as to be able to go on without custom code maintenance :) For paging purposes, I would need the output of this function to contain the total nu

[web2py] Validating row

2012-04-22 Thread Joseph.Piron
Hi guys, I just wondered how I am supposed to add a row validator in db models ? I looked at the code of validate function but it seems each validator is only passed the value of the field it is bound to. I am looking for this as I have to validate the value of one field based on other fields v

[web2py] Content-type header for HTTP exception incorrectly set ?

2012-04-16 Thread Joseph.Piron
Hi gents ! I was working on an extjs client intended to discuss with web2py when I stumbled upon this weird behaviour: with my client calling "PUT /defaut/api/alarms/1.json", I want the server to respond a 409 error code with good json return {success: false, errors: {...}} and use raise HTTP(

[web2py] Re: Login form, can't login..

2012-04-02 Thread Joseph.Piron
Ok, it seems it is Chrome related.. :| I tried with Firefox and Safari and they hit the server only once. Could someone please confirm he has the same problem with Chrome (build 18.0.8025.142) ?? Le lundi 2 avril 2012 15:31:23 UTC+2, Joseph.Piron a écrit : > > Hi all, > > I

[web2py] Login form, can't login..

2012-04-02 Thread Joseph.Piron
Hi all, I got another problem (today's not my day it seems.. :'( ) I am trying to login through ldap but can't and nailed down another problem: On a simple login form url "default/user/login?_next=/app/default/index" I get the classic login html form but can't succeed to log in. Indeed, I traced

[web2py] Re: Routes.py parameter, rewrite rules and redirect

2012-04-02 Thread Joseph.Piron
Ah, and another simple question, maybe dull.. :) Does the domains option have any use when web2py's app is served from a apache or nginx frontend by wsgi ? Le lundi 2 avril 2012 11:57:37 UTC+2, Joseph.Piron a écrit : > > Hi all, > > For one of my applications, I use web2py

[web2py] Routes.py parameter, rewrite rules and redirect

2012-04-02 Thread Joseph.Piron
Hi all, For one of my applications, I use web2py as a rest backend for a extjs application. So, in order to redirect to this app, I have def index(): """ example action using the internationalization operator T and flash rendered by views/default/index.html or views/generic.html

[web2py] Re: More Details on RESTful web2py?

2011-09-15 Thread Joseph.Piron
Hmm quite the same question as David G: I use the auto pattern feature (really nice) but I don't see how to provide an index for a resource. Am I missing something ? Thanks ! On Aug 9, 12:11 am, David G wrote: > I have a similar question as Web2py Newbie.  I want to return all the > rows from a

[web2py] Re: No generic.json support anymore ?

2011-08-17 Thread Joseph.Piron
y enable it for that > controller/function) > > Note, the current 'welcome' app enables all generic views, but only for > local requests (there is a line in db.py that does this). > > Anthony > > > > > > > > On Wednesday, August 17, 2011 9:46:47 AM UTC

[web2py] No generic.json support anymore ?

2011-08-17 Thread Joseph.Piron
Hi guys, quite a weirdo right here :) I was on web2py 1.95.2 and everything was fine with my applications in production. To stay put, I have deciced to uppgrade to the last one 1.98.2 and validate everything works.. and ... it doesn't .. :'( I have a controller serving db information through a si

[web2py] Re: versioning and uploads

2011-06-02 Thread Joseph.Piron
The one created in the application folder when using the web interface versioning option. Haven't even noticed the distro one. What is its purpose ? On May 31, 5:19 pm, pbreit wrote: > Which .hgignore? The main distro includes: > applications/*/uploads/* > > http://code.google.com/p/web2py/source

[web2py] Re: Versioning bug with wsgi

2011-06-02 Thread Joseph.Piron
Sorry for the delay, yes it works. On May 27, 4:24 pm, Massimo Di Pierro wrote: > In wsgihandler if you add: > > sys.stdout=sys.stderr > > does it solve the problem? If so I will add this to trunk. > > On May 27, 9:04 am, "Joseph.Piron" wrote: > > > >

[web2py] versioning and uploads

2011-05-31 Thread Joseph.Piron
Hi all, I wonder if the uploads directory shouldn't be added in the .hgignore file by the versioning command live databases, cache and so on. What do you think ?

[web2py] Versioning bug with wsgi

2011-05-27 Thread Joseph.Piron
Hi all, a little annoying bug I encountered a minute ago: I tried the commit in mercurial versioning for an application running apache+wgsi_mod, and I got a ticket and this error embedded: IOError: sys.stdout access restricted by mod_wsgi: sys.stdout access restricted by mod_wsgi A quick check

[web2py] Re: domain and download function problem

2011-05-27 Thread Joseph.Piron
Ok I'm not alone on this server and someone had created an alias / download in the conf.d apache directory... Life's tough sometimes.. :) On May 26, 3:31 pm, Anthony wrote: > On Wednesday, May 25, 2011 5:24:49 AM UTC-4, Joseph.Piron wrote: > > > routers = dict( > &

[web2py] Re: domain and download function problem

2011-05-27 Thread Joseph.Piron
ally don't understand ?? On May 26, 3:31 pm, Anthony wrote: > On Wednesday, May 25, 2011 5:24:49 AM UTC-4, Joseph.Piron wrote: > > > routers = dict( > > BASE = dict( > > domains = { > > 'stock': 'stock' > > } > > ) > > ) >

[web2py] Re: domain and download function problem

2011-05-26 Thread Joseph.Piron
ike when http://stock is accessed, so with the controller.. could it be the problem ? On May 25, 11:24 am, "Joseph.Piron" wrote: > Hi guys, > > i got a strange problem, I have made a simple application picking up > data from a database, including an upload field for sma

[web2py] Re: domain and download function problem

2011-05-26 Thread Joseph.Piron
nobody's got a clue ? :) On May 25, 11:24 am, "Joseph.Piron" wrote: > Hi guys, > > i got a strange problem, I have made a simple application picking up > data from a database, including an upload field for small photos. > This works perfectly if hosted in the

[web2py] domain and download function problem

2011-05-25 Thread Joseph.Piron
Hi guys, i got a strange problem, I have made a simple application picking up data from a database, including an upload field for small photos. This works perfectly if hosted in the classic way, for example if my server name is stock and the application is stock (...), if I access http://stock/sto

[web2py] Re: Logging of user actions

2011-05-20 Thread Joseph.Piron
Ah nice trick also, didn't think about the cache, but where do you put the code to defie the _init_log ? On May 19, 11:23 pm, pbreit wrote: > I got this from here awhile back: > > def _init_log(): >     import os,logging,logging.handlers,time >     logger = logging.getLogger(request.application)

[web2py] Re: Logging of user actions

2011-05-19 Thread Joseph.Piron
Oh, the auth.log_event I didn't know.. maybe interesting, but i don't want to log in the db, I need to use my logger config. But I can't possibly believe it's rare to log what users do.. Imagine, I have a db of specifications, I want to know who modified which field at what time.. What should be t

[web2py] Re: Logging of user actions

2011-05-18 Thread Joseph.Piron
Has noone ever had this king of need ?? On May 17, 11:59 pm, "Joseph.Piron" wrote: > Hi all, > > I was wondering what would be the best way to log actions with the > username of the logger user. > I found several leads but none very conclusive. > > For examp

[web2py] Logging of user actions

2011-05-17 Thread Joseph.Piron
Hi all, I was wondering what would be the best way to log actions with the username of the logger user. I found several leads but none very conclusive. For example, define a filter in my model: import logging class ContextFilter(logging.Filter): def filter(self, record): record.user

[web2py] Re: little bug ldap_auth

2011-05-17 Thread Joseph.Piron
does, it should be changed. > > On May 17, 6:51 am, José Luis Redrejo wrote: > > > > > > > > > 2011/5/17 Joseph.Piron : > > > > Hi all, > > > > I think there's a little bug in ldap_auth.py, indeed for the parameter > > > filterst

[web2py] little bug ldap_auth

2011-05-17 Thread Joseph.Piron
Hi all, I think there's a little bug in ldap_auth.py, indeed for the parameter filterstr of ldap_auth(..) (line 10), the default value is set to (objectClass=*) and during the call of search_ext_s (line 97), the filter argument is constructed with "(&(sAMAccountName=%s)(%s))" % (username_bare, fil

[web2py] Re: SOLVED

2011-02-23 Thread Joseph.Piron
Oups wrong place, it goes with http://groups.google.com/group/web2py/browse_thread/thread/e7bc06a9efeb76e4 On Feb 23, 11:33 am, "Joseph.Piron" wrote: > Indeed, it's really.. something. > > Let's explain with an example: > If I have an application called

[web2py] SOLVED

2011-02-23 Thread Joseph.Piron
Indeed, it's really.. something. Let's explain with an example: If I have an application called Alfred (mind the 'A'), and I put 'alfred' or 'aLfred' or else in the browser, the breakpoints are omitted, but if I use the right casing 'Alfred', breakpoints work! Good to know! But I wonder why :)

[web2py] HTTP_RANGE support for streaming to iDevices

2011-02-21 Thread Joseph.Piron
Hi all, I was trying to create a plugin for VideoJS html 5 player for web2py. Everything was nice with the demo video from VideoJS server when I tried with my own. It works with Chrome, IE, Safari, Firefox and ... doesn't with iPhone.. (nor FlowPlayer flash player) After some research, it appears

[web2py] Debug somtimes works, sometimes doesn't..

2011-02-21 Thread Joseph.Piron
Hi all, I have a weird issue here.. I'm working with eclipse and pydev and I have defined a project with the full web2py folder. The problem is I can debug several applications such as the welcome or example app, or even the code in web2py.py, but my own apps (created with fast new app options in

[web2py] Re: Unicity condition and database update

2011-02-04 Thread Joseph.Piron
gename. > You are not passing triggername when you do the update_rector and > web2y does not do what to do. web2py wants you to be explicit: > > row=db.alarms(2) > row.update_record(message='rz',triggerName=row.triggerName) > > On Feb 3, 4:40 am, "Joseph.Piron&q

[web2py] Unicity condition and database update

2011-02-03 Thread Joseph.Piron
Hi guys, I'm currently facing a strange thing :) I make use of datatables (jquery datatables.net) and jeditable to update values in my db. If the user clicks on a value, he changes it and sends it, thus, only the value of this field. On the server part, i then do a db.alarms[request.vars.id].upda