Re: [web2py] Re: HELP!! Another upgrading failed for Apache running web2py

2015-01-26 Thread Niphlod
uhm. apache is relly something nasty when it comes to a few things like https://code.google.com/p/modwsgi/wiki/ApplicationIssues and https://code.google.com/p/modwsgi/wiki/IssuesWithPickleModule wondering if it's a problem-per-se or not. On Friday, January 23, 2015 at 11:46:08 PM

[web2py] Re: represents currency format

2015-01-26 Thread Niphlod
if you're not using web2py's facilities (SQLTABLE, grid, rows.render(), etc), you have to call represent directly {{=db.KR_Product.UnitPrice.represent(list.UnitPrice)}} On Monday, January 26, 2015 at 11:39:07 PM UTC+1, Omi Chiba wrote: I want to show the UnitPrice like $1,000,00 but it

[web2py] Re: IMPORTANT - DO NOT POST ISSUE ON GOOGLE CODE

2015-01-26 Thread Niphlod
migration completed. You can find in the original googlecode issue a last message by me linking to the newly migrated issue on github, and on the github issue the link to the original issue on googlecode. From now on: - googlecode issues WON'T be looked at - please post ONLY issues on

Re: [web2py] Re: represents currency format

2015-01-26 Thread Niphlod
in the view, you have td style=text-align: right;{{=list.UnitPrice}}/td use instead td style=text-align: right;{{=db.KR_Product.UnitPrice.represent(list.UnitPrice)}}/td should work without issues. or read about render() here

[web2py] Re: web2py 2.9.12 is OUT

2015-01-25 Thread Niphlod
headers accepts a dict, fields instead must be a list. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are

[web2py] Does Web2py DAL have something similar to Rails Active Record Associations?

2015-01-24 Thread Niphlod
From what I see on ruby's docs, Dal has it thanks to references. Don't know what are you specifically asking, though -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report

[web2py] Re: Grid order for reference fields

2015-01-22 Thread Niphlod
On Thursday, January 22, 2015 at 10:59:28 AM UTC+1, Gael Princivalle wrote: Thanks Niphlod I understand that the web2py grid cannot do all that users would like to, but for my use it's quite to. Viewing, sorting, editing, creating new rows, I like it. For my needs it just miss a way

[web2py] Re: Grid order for reference fields

2015-01-21 Thread Niphlod
irregardless of the business logic there's a simple caveat with web2py grid (and reference fields in general). for a field to be ordered (or searched, as it poses the exact same deal) correctly, web2py would have to fetch for each row of the table (not the page, the entire table) the reference

[web2py] Re: HELP!! One click upgrade failed for pythonanywhere site

2015-01-21 Thread Niphlod
in this case it's not platform-dependency the issue: it's the method web2py uses for the upgrade-in-place. We should label it CLEARLY as things can go wrong if you press this button and live with it: there are just too much moving parts around an upgrade. Most of the times it works (and it

[web2py] Re: After update 2.9.12, response.json is messing the screen

2015-01-21 Thread Niphlod
pretty undocumented feature (so its not a bug per se) response.json() is clearly NOT meant to be used in views just use json(whatever) instead. on the can I call it a bug of not matter, that seems to surface every once in a while, please take the following as a word of caution (from

[web2py] Re: stoping database insert in onvalidation

2015-01-21 Thread Niphlod
read the book about onvalidation http://web2py.com/books/default/chapter/29/07/forms-and-validators#onvalidation . If you want to stop the form from being processed, you have to fill form.errors.some_field with something. -- Resources: - http://web2py.com - http://web2py.com/book

[web2py] Re: Having db().select() return rows with only one instance with a particular value for a given field?

2015-01-21 Thread Niphlod
seems like a job for distinct=True (or a groupby) . Docs are here http://web2py.com/books/default/chapter/29/06/the-database-abstraction-layer#orderby--groupby--limitby--distinct--having-orderby_on_limitby-left-cache On Wednesday, January 21, 2015 at 7:09:41 PM UTC+1, Spokes wrote: I'd like a

[web2py] Re: SQLFORM - field_id - not work

2015-01-21 Thread Niphlod
it's not a matter of read-only. Grid uses urls like /app/controller/function/tablename/id for many things. Imagine what happens when id is really something like https://www.google.com/?gfe_rd=crei=mAjAVNLgGo2DcPzrgXAgws_rd=ssl#q=web2py; ... -- Resources: - http://web2py.com -

Re: [web2py] Re: After update 2.9.12, response.json is messing the screen

2015-01-21 Thread Niphlod
On Wednesday, January 21, 2015 at 9:36:09 PM UTC+1, André Kablu wrote: I was expecting someone tell me that I am using it wrong :) Since it was there and I was using it (wrong or not) for past 2 years... I was not expecting its behavior to change... And I always consider testing my apps

[web2py] Re: HELP!! One click upgrade failed for pythonanywhere site

2015-01-21 Thread Niphlod
IMHO the issue with upgrading in place (always an HARD thing to do) is that the upgrade method doesn't take into consideration to prune the directory BEFORE installing the new version. When no modules in gluon change (or when things gets added), there is no issue however, this time with

[web2py] Re: Having db().select() return rows with only one instance with a particular value for a given field?

2015-01-21 Thread Niphlod
I don't think there's a T-SQL statement for it. If you strongly need it, performance-wise, it's still best to distinct/groupby on the backend and randomize on the frontend (via python). You can also randomize limitby parameters if you're feeling random at this level (limiting correctly with

[web2py] Re: Apache + web2py.exe as daemon or servise + nssm

2015-01-20 Thread Niphlod
if you need to run web2py behind apache you need the source version On Tuesday, January 20, 2015 at 7:53:23 AM UTC+1, Dmitry Ermolaev wrote: Apache 2.2 + wsgi_mod in http.conf:: LoadModule wsgi_module modules\mod_wsgi.so if I use web2py/wsgihandler.py in apache config: VirtualHost *:80

[web2py] Re: SQLFORM - field_id - not work

2015-01-20 Thread Niphlod
field_id MUST be a pkey, so an integer: there's no support for string-like keys in grid, because it's used as an argument. On Tuesday, January 20, 2015 at 6:15:21 AM UTC+1, Dmitry Ermolaev wrote: I need that ID become URL on view info of this record - same as View field понедельник, 25

Re: [web2py] Re: Windows \ 2.9.12 \ Error3 \ cache

2015-01-20 Thread Niphlod
my bad. rebuilding now. On Tuesday, January 20, 2015 at 7:22:54 PM UTC+1, Kiran Subbaraman wrote: Thanks, will do. Opened an issue to track this to closure: https://code.google.com/p/web2py/issues/detail?id=2035 Kiran

Re: [web2py] Re: Windows \ 2.9.12 \ Error3 \ cache

2015-01-20 Thread Niphlod
try this please https://www.dropbox.com/s/jmdy2qtt71i0snb/web2py_win.zip?dl=0 . On Tuesday, January 20, 2015 at 9:23:41 PM UTC+1, Niphlod wrote: my bad. rebuilding now. On Tuesday, January 20, 2015 at 7:22:54 PM UTC+1, Kiran Subbaraman wrote: Thanks, will do. Opened an issue to track

Re: [web2py] Re: Windows \ 2.9.12 \ Error3 \ cache

2015-01-20 Thread Niphlod
easy - stop the executable - download https://www.dropbox.com/s/vf83tc5kasv5o6k/cache.pyc?dl=0 - replace library.zip/gluon/cache.pyc with the downloaded file - start the executable -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py

[web2py] Re: Mixing pydal with web2py - how to manage the non-web2py setup

2015-01-19 Thread Niphlod
On Monday, January 19, 2015 at 6:23:24 PM UTC+1, Tom Stratton wrote: Hi - Thanks for the response. I did find the documentation and set migrate=False and was able to get it working. However, the follow up question is, what to do if I do want to change the tables? EG: What if I want to

[web2py] Re: how to select the last row in sql database using dal

2015-01-19 Thread Niphlod
db(db.table.id 0).select(orderby=~db.table.id, limitby=(0,1)).first() On Monday, January 19, 2015 at 10:35:19 PM UTC+1, chuan wrote: I would like to access last row of any database table in a general way, do I have to first count all the rows, then access the last row? This is effectively 2

[web2py] Re: request.now - one day

2015-01-19 Thread Niphlod
slightly incorrect ... either from datetime import timedelta yesterday = request.now - timedelta(days=1) or import datetime yesterday = request.now - datetime.timedelta(days=1) -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py

[web2py] Re: Mixing pydal with web2py - how to manage the non-web2py setup

2015-01-18 Thread Niphlod
if it exist already you don't need .table at all. just set migrate=False. .table files are web2py way of tracking what is supposed to be already in the database for two reasons: - if you define a table that doesn't exist, create it - if you changed the definition of a table (e.g. added a field),

[web2py] Re: Error in Eclipse kepler for Web2py source: generics.xml

2015-01-14 Thread Niphlod
if you have set up eclipse to be foolish you can't follow the warnings it outputs. It's treating generic.xml as something with valid XML markup inside, while web2py's generic.xml is filled with templating functions that are NOT static xml. On Tuesday, January 13, 2015 at 10:38:00 AM UTC+1,

[web2py] Re: How can I have optional, or vairable buttons in a sqlform.smartgrid 'links' ?

2015-01-14 Thread Niphlod
easy-peasy... given myfunc(row) something that returns True only if the button needs to be generated. lambda row: myfunc(row) and themarkup_to_generate_the_button or '' -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source

[web2py] Re: Don't use 64 bit ODBC with Web2Py and SQL Server

2015-01-14 Thread Niphlod
first and foremost, web2py doesn't need an odbc source defined at system level. That being said, it can, but if you're running the source with a 32-bit python or the executable (32-bit too) it's pretty obvious that a 64-bit defined odbc source won't be available... On Wednesday, January 14,

Re: [web2py] Re: Login to web2py from external script

2015-01-14 Thread Niphlod
On Wednesday, January 14, 2015 at 1:27:59 AM UTC+1, Richard Penman wrote: http is stateless do you mean because the decoding is handled at the server layer before reaches web2py? I mean that web2py doesn't store anywhere how to send the data in. As long as it's valid, it's parsed.

Re: [web2py] Re: Login to web2py from external script

2015-01-13 Thread Niphlod
http is stateless. On Tuesday, January 13, 2015 at 6:12:27 AM UTC+1, Richard Penman wrote: Yeah same data of course, but different encoding than form specifies so I expected back end to reject it. why it shouldn't be ? it's just different encodings to send the same data over the wire.

[web2py] Re: how to compare dates with dal

2015-01-13 Thread Niphlod
On Monday, January 12, 2015 at 8:31:53 AM UTC+1, Rohit Raj Sharma wrote: i am trying to compare date with database. i am not able to get record. nov_pending = c_pcdt= db( (db.tracker.client_owner==auth.user.email ) (db.tracker.Compliance_Area == 1) (db.tracker.periodicity_due_date =

Re: [web2py] Re: Updated appliances or web2py blog?

2015-01-13 Thread Niphlod
the solution to the problem is investigating what leads to a foreign key error, not to work with an inconsistent backend On Tuesday, January 13, 2015 at 12:17:06 PM UTC+1, Paolo Valleri wrote: Movuca hasn't received updated for a while. Recent web2py forces sqlite with PRAGMA

[web2py] Re: Login to web2py from external script

2015-01-12 Thread Niphlod
why it shouldn't be ? it's just different encodings to send the same data over the wire. On Monday, January 12, 2015 at 3:36:12 AM UTC+1, Richard Penman wrote: Strangely I found that the login forms works even when encode the data as usual for application/x-www-form-urlencoded: cj =

[web2py] Re: built-in wiki

2015-01-11 Thread Niphlod
http://web2py.com/books/default/chapter/29/03/overview#Extending-the-auth-wiki-feature On Sunday, January 11, 2015 at 5:50:24 PM UTC+1, mweissen wrote: I want to use the built-in wiki. Ok, it starts. But (silly question): where is the storage for the new pages. Is it a database table? But

[web2py] Re: Traceback with record versioning enabled and common_filter defined.

2015-01-10 Thread Niphlod
uhmbut record_versioning adds a common_filter per se, and is usually on the form of is_active == True. Did you try to set a different common_filter ? On Saturday, January 10, 2015 at 8:58:21 AM UTC+1, Jose C wrote: Bug reported:

[web2py] Re: Graphviz web2py not found

2015-01-10 Thread Niphlod
you need to install pygraphviz to have graphs On Saturday, January 10, 2015 at 4:15:32 PM UTC+1, Raphael Viana wrote: Hello everyone, I started very recently in web2py world, but i have a problem. when i use a graph model web2py return for me a error message graphviz library not found

[web2py] Re: Not getting expected results from a query

2015-01-09 Thread Niphlod
then do a def cost3(): jnum = request.args(0,cast=int) a = 0 thequery = db(db.PO.job_id==jnum)._select() results = db(db.PO.job_id==jnum).select() for row in results: a = a + row.mycost return dict(a=a, howmany=len(results), thequery=thequery) too see if the

Re: [web2py] Re: Please help us test the 2.9.12 binaries

2015-01-08 Thread Niphlod
all working fine in Windows . On Wednesday, January 7, 2015 at 9:10:26 PM UTC+1, Richard wrote: Most part of app seems to work... Is there some stuff I should check more then other, thing that you made change that you want to make sure it is not breaking backward compatibility? Richard

[web2py] Re: Web2Py on AWS EC2

2015-01-05 Thread Niphlod
maybe the the linux vm has a firewall on port 8000 by default security groups aren't configured for port 8000. if you're using the vanilla amazon ec2 instance, see the related documents on

[web2py] Re: Not getting expected results from a query

2015-01-05 Thread Niphlod
start with: def cost3(): jnum = request.args(0,cast=int) a = 0 results = db(db.PO.job_id==jnum).select() for row in results: a = a + row.mycost return dict(a=a, howmany=len(results)) so you can check how many rows are you actually selecting :P On Sunday, January

[web2py] Re: Mail don't send without errors

2015-01-05 Thread Niphlod
are you sure that the problem is not that the rejection happens after the SMTP accepted the mail ? web2py doesn't do too much magic in terms of return value...it uses sendmail() from smtplib and traps any exception. If you don't see exceptions, smtplib.sendmail isn't raising, so it means that

[web2py] Re: What is represent syntax for external url?

2015-01-05 Thread Niphlod
/ironic mode on/ why of all names choosing just something that closely resemble some web2py function? are you asking for troubles?!?! /ironic mode off/ URL() in web2py is a function to create urls (usually related to web2py applications). If you have an url that is complete (such as

[web2py] Re: models - session.py

2015-01-04 Thread Niphlod
don't know. it's not a file shipped with the scaffolding app On Sunday, January 4, 2015 2:26:54 PM UTC+1, Dmitry Ermolaev wrote: What does session.py http://127.0.0.1:8000/admin/default/peek/lite_merch/models/session.py?id=models__session__py in models? -- Resources: -

[web2py] Re: models: markmin.py

2015-01-04 Thread Niphlod
this is the second question on the same matter: open the file and read the docstrings, no ?! usually this file is not in the scaffolding app. the name suggest more a module in the gluon folder, which carries the markmin markup language routines: it's heavily documented in the book (and the book

Re: [web2py] Re: Rocket // HTTP 400 Bad Request - Body is incomplete

2015-01-04 Thread Niphlod
the point of routes_onerror is EXACTLY to intercept the error and somewhat process it to display a nicer page to the end-user. I'd guess at this point that your controller handling the error has some bugs in it: would you care to trim it to the bare minimum to see if the error is in handling

[web2py] Re: How can I from a celery task post a message in websocket_messaging.py?

2015-01-04 Thread Niphlod
usually using the same method you'd do in web2py... from gluon.contrib.websocket_messaging import websocket_send websocket_send('http://127.0.0.1:', 'Hello World', 'mykey', 'mygroup') On Saturday, January 3, 2015 9:27:17 PM UTC+1, Tito Garrido wrote: Hey Folks, I am studying

[web2py] Re: Web2Py on AWS EC2

2015-01-04 Thread Niphlod
://theipaddress_ofec2instance:8000 all you have to do is to start it with web2py.py -i 0.0.0.0 -a mypwd 0.0.0.0 is a meta-address that means listen on all interfaces. On Saturday, January 3, 2015 5:41:18 PM UTC+1, NeoToren wrote: My apologies Niphlod, 1. I didn't mention that the result of the command ... python

[web2py] Re: Web2Py on AWS EC2

2015-01-03 Thread Niphlod
AWS EC2 is nothing more of a linux server . to start executables listening on port 80 superuser permissions are needed, only high ports are allowed at normal user powers (that's why on production one usually deploys web2py BEHIND a real webserver). Enough of that said, starting with python

[web2py] Re: 2.9.11 migration

2015-01-02 Thread Niphlod
how did you upgrade ? On Wednesday, December 31, 2014 8:31:42 PM UTC+1, lucas wrote: hey everyone, i just upgraded from 2.9.5 to 2.9.11 web2py onto a new centos 6.5 server. is there any migration stuff i need to know because just doing admin in the url and apache is throwing back: Not

[web2py] Re: Content Security Policy (CSP) settings and calender.js

2014-12-31 Thread Niphlod
a different widget that is compatible with bs3 https://github.com/niphlod/cs_monitor_plugin -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received

Re: [web2py] database select from set encoding

2014-12-30 Thread Niphlod
let's tackle the problem from another side: if you avoid using DAL and resort to pure psycopg2, does it work ? If yes, can you post the code ? From there we can compare what DAL does and pinpoint the root cause accordingly. On Tuesday, December 30, 2014 8:41:56 AM UTC+1, Yebach wrote: Hello

Re: [web2py] Re: Rocket // HTTP 400 Bad Request - Body is incomplete

2014-12-30 Thread Niphlod
you're not very fair in debugging if you have something different that processes the error: please simplify it and let the application alone catch the error, then inspect what goes on with logging calls into copystream... -- Resources: - http://web2py.com - http://web2py.com/book

Re: [web2py] Re: Daily task on production: scheduler or cron?

2014-12-30 Thread Niphlod
that's really someone overcomplicating the setup... on the queue_task thing, use prevent_drift as explained before. Again, setting the heartbeat to 10 minutes kinda sucks, as there are too many things that can happen in 10 minutes. BTW: if you don't use cron, what are you planning to use to

[web2py] Re: Content Security Policy (CSP) settings and calender.js

2014-12-30 Thread Niphlod
I don't get what you're asking for. If you choose to create *your* own policy and part of *your* application uses something that *your* own policy discards, there's nothing *web2py* can do. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) -

[web2py] Re: Content Security Policy (CSP) settings and calender.js

2014-12-30 Thread Niphlod
On Tuesday, December 30, 2014 8:35:23 PM UTC+1, Dave S wrote: On Tuesday, December 30, 2014 7:32:15 AM UTC-8, Niphlod wrote: I don't get what you're asking for. If you choose to create *your* own policy and part of *your* application uses something that *your* own policy discards

Re: [web2py] Re: Stream cStringIO

2014-12-29 Thread Niphlod
? 2014-12-27 2:27 GMT+04:00 Niphlod nip...@gmail.com javascript:: the docstrings api on web2py.com/examples/epydoc are reeeally old and buggy. The new api documentation is on readthedocs http://web2py.readthedocs.org/en/latest/ Now... if you want to pass a StringIO to response.stream, you

[web2py] Re: Markmin Blockquote

2014-12-28 Thread Niphlod
sorry but I'm having problems understanding what's the issue...without proper newlines that will remain a single line and not a blockquote... -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) -

[web2py] Re: Markmin Blockquote

2014-12-28 Thread Niphlod
ok, this is far more helpful try with an empty line between - and This is a paragraph in a blockquote -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report

[web2py] Re: format does not work for SQLFORM

2014-12-28 Thread Niphlod
and that lambda row: is a function, exactly as foretold. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are

[web2py] Re: Rocket // HTTP 400 Bad Request - Body is incomplete

2014-12-27 Thread Niphlod
whoa, that seems to be an issue with copystream_progress (in gluon/globals.py), that is quite easy to debug. Usually due to some weird issue with really huge POSTs, or streaming ones that don't carry the content-length attribute, or something raaally really weird. -- Resources: -

[web2py] Re: Markmin Blockquote

2014-12-27 Thread Niphlod
if you don't paste your contents in a code block on the forum, it's impossible to tell you what's wrong because normal posts don't keep spacing and newlines On Saturday, December 27, 2014 2:53:02 PM UTC+1, lyn2py wrote: Hi guys I'm trying MARKMIN here and the block quotes I have look like

[web2py] Re: tool for making actions' diagrams

2014-12-27 Thread Niphlod
those are made with http://yuml.me/ . alternatives may be also http://www.nomnoml.com/ for hosted solutions if you want to do something similar within your app without using external services, there's https://github.com/knsv/mermaid On Saturday, December 27, 2014 9:23:33 AM UTC+1, Matt Bee

[web2py] Re: format does not work for SQLFORM

2014-12-27 Thread Niphlod
IMHO you can't have a format definition that needs values from different tables to be represented you need a separate function to do that. On Saturday, December 27, 2014 12:14:50 AM UTC+1, t_gle...@yahoo.com wrote: My application manages debits of hardware to personnel Here is my model:

[web2py] Re: get the iteration number from a scheduled task

2014-12-27 Thread Niphlod
uhm... there's not a stable API to do it, but you can access the relative scheduler_task record via W2P_TASK. From web2py 2.4.1, any task processed by the scheduler can access a global variable named W2P_TASK that is a Storage() holding the id and the uuid of the running task. this means

Re: [web2py] Re: Rocket // HTTP 400 Bad Request - Body is incomplete

2014-12-27 Thread Niphlod
put a few logging statements on copystream_progress and see where it explodes... -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this

[web2py] Re: Stream cStringIO

2014-12-26 Thread Niphlod
the docstrings api on web2py.com/examples/epydoc are reeeally old and buggy. The new api documentation is on readthedocs http://web2py.readthedocs.org/en/latest/ Now... if you want to pass a StringIO to response.stream, you have to rewind it to 0 before passing it s =

[web2py] Re: Upgrade issues with 2.9.11

2014-12-24 Thread Niphlod
since 2.1.0 (almost an year ago) we have static asset management (you can read about it here http://web2py.com/books/default/chapter/29/04/the-core?search=static_version#Static-asset-management) . you need to alter your AliasMatch ^/([^/]+)/static/(.*)

[web2py] Re: Daily task on production: scheduler or cron?

2014-12-24 Thread Niphlod
a) Some people never consider this as a possibility, but if you have 3 apps, e.g. app1, app2 and app3, you can run one scheduler for all applications. The default mode is built to process by default tasks coming from the same app that queues them, but the switch is still there:

Re: [web2py] Re: append script with no extension

2014-12-24 Thread Niphlod
No way to do it programmatically? unless you code something of your own, from that url (or any other without extension) web2py can't figure out what type of script to generate. on a totally (un)related note, this seems to work fine

[web2py] Re: caching model data

2014-12-24 Thread Niphlod
so, what's the issue you're facing ? On Wednesday, December 24, 2014 12:29:24 PM UTC+1, harsha tanguturi wrote: I would like to cache the model data i.e., caching the selects and update the cache whenever the data is updated. Putting simply a caching layer has to present before the database

[web2py] Re: unescaped HTML code in wiki page

2014-12-24 Thread Niphlod
How can avoid this? What I'm missing from the documentation? the render parameter ?! -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received

[web2py] Re: Datetime Grid Filtering ignores localized format and timezone

2014-12-23 Thread Niphlod
nope! the issue is that SQLFORM.build_query can't understand localized dates. On Tuesday, December 23, 2014 8:35:28 AM UTC+1, Paolo Valleri wrote: Hi, the issue is here https://github.com/web2py/web2py/blob/master/gluon/sqlhtml.py#L1830 can you try to replace that line with the following:

[web2py] Re: Dumb Question/Bug

2014-12-23 Thread Niphlod
are you aware that in web2py any HTTP is a subclass of exception ? Never, never, never use an exception without specifying what exception your code may raise. On Tuesday, December 23, 2014 7:34:45 PM UTC+1, Mark Billion wrote: Why are you using an except without specifying the exception?

[web2py] Re: wiki page contents

2014-12-22 Thread Niphlod
the db (wiki_* tables) On Monday, December 22, 2014 11:29:16 AM UTC+1, Manuele wrote: Hi *, I'm trying the auth.wiki for the first time and I cannot find where the pages contens is saved. on the db? somewhere on the fs? Thank you Manuele -- Resources: - http://web2py.com -

Re: [web2py] Re: wiki page contents

2014-12-22 Thread Niphlod
#The-built-in-web2py-wiki On Monday, December 22, 2014 2:46:03 PM UTC+1, Manuele wrote: Il 22/12/14 14:26, Niphlod ha scritto: the db (wiki_* tables) so why I cannot see them from the admin page? :) was exactly what I was expacting... and I looked for M. -- Resources: - http

[web2py] Re: pass query from client to sever

2014-12-22 Thread Niphlod
it is. it's just experimental. On Tuesday, December 23, 2014 5:45:11 AM UTC+1, Massimo Di Pierro wrote: something like that should be included in web2py. On Monday, 22 December 2014 00:07:18 UTC-6, Massimo Di Pierro wrote: We do not have a way to serialize queries in a server independent

[web2py] Re: Scheduler: tasks are always assigned to the same running worker.

2014-12-19 Thread Niphlod
file with the modifications: there's no breaking changes in the modification I did (or use this https://raw.githubusercontent.com/niphlod/web2py/scheduler/enhancement/gluon/scheduler.py). you just need to restart the scheduler to make the changes work. -- Resources: - http://web2py.com

[web2py] Re: Scheduler: tasks are always assigned to the same running worker.

2014-12-18 Thread Niphlod
Each time I click the link, one test task will be created. But if I click twice, the two initiated tasks are always assigned to the same worker, and I need to wait until one task to be completed to run the other one. I am not sure if it is a bug or not. Is there any way to make the

[web2py] Re: Scheduler: tasks are always assigned to the same running worker.

2014-12-18 Thread Niphlod
...several minutes later ... ;-P , I got the gist of it. First of all, testing something concurrent with sqlite isn't properly fair. SQLite sucks at being concurrent. That being said, assignment is sub-optimal (the gist of what you're trying to point at). Clicking here and there with 3

[web2py] Re: Scheduler: tasks are always assigned to the same running worker.

2014-12-18 Thread Niphlod
ok, got it, all tests pass. PR ready at https://github.com/web2py/web2py/pull/565 In the meantime, if you want to verify the better assignment, all you have to do is applying this https://github.com/web2py/web2py/pull/565/files#diff-1cbb9c488bb09b40aff4560078808c79R1091 to the scheduler

[web2py] Re: web2py on a dedicated server

2014-12-18 Thread Niphlod
I guess the easiest thing to do is fetch the errors from the server, save them on your development server, read them. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list

[web2py] Re: Scheduler: tasks are always assigned to the same running worker.

2014-12-17 Thread Niphlod
ok, so it's not a problem of the algorithm of dispatching tasks of the scheduler . Try adding small bits of your code to the test_task to pinpoint the root cause of the original misbehaviour. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) -

[web2py] Re: Maximum size session variable

2014-12-16 Thread Niphlod
sessions are by default stored in pickles saved into the sessions/ folder. Aside from being something that pickle itself can't handle in your environment, no limits are enforced on web2py's side. On Monday, December 15, 2014 4:20:13 PM UTC+1, Richard D wrote: Hi, We have strange behaviour

[web2py] Re: Scheduler: tasks are always assigned to the same running worker.

2014-12-16 Thread Niphlod
Uhm, really strange. Keep things simple to reproduce: queue tasks that are something like import time def testtask(): time.sleep(60) return 1 and see if the behaviour is reproducible. Here I don't see anything wrong: 5861 is ACTIVE (meaning there's nothing actively running on it, or

[web2py] Re: migrate and fake_migrate

2014-12-16 Thread Niphlod
Run the model for the *second* time. It works well. Run the model for the *third* time. Fails: *OperationalError: duplicate column name: f5* entirely different issue here, thrown at database level rather than previous ones that were raised from web2py code this is a well-known gotcha

[web2py] Re: migrate and fake_migrate

2014-12-14 Thread Niphlod
On Friday, December 12, 2014 4:40:59 PM UTC+1, Tom Øyvind Hogstad wrote: I have probably the same issue. After it popped up and I couldn't resolve it I have manually added the fields to postgre. As I understand fake migrate it will regenerate the data needed for migrate. nope.

[web2py] Re: ERR_CACHE_MISS while working with SQLFORM.factory()

2014-12-14 Thread Niphlod
it's standard behaviour for modern browsers. You can't go back to something that was generated by a POST (the form submission) without a warning, because it's like having the form submitted twice (POST isn't idempotent). -- Resources: - http://web2py.com - http://web2py.com/book

[web2py] Re: A helper and delete argument

2014-12-14 Thread Niphlod
A(, noconfirm=True) On Friday, December 12, 2014 2:09:59 PM UTC+1, Pavel wrote: I have another question: Example from works fine. But, how to prevent showing popup message with warning about deleting object from page? Thanks -- Resources: - http://web2py.com -

[web2py] Re: exe file for web2py app

2014-12-14 Thread Niphlod
you download the binary, extract it somewhere, put your app into applications (optionally renaming it as init as this will be the default application), remove examples and welcome, recompress to an archive and distrubute it. On Friday, December 12, 2014 5:58:59 AM UTC+1, kanchan wrote:

[web2py] Re: summing fields

2014-12-14 Thread Niphlod
http://web2py.com/books/default/chapter/29/06/the-database-abstraction-layer#sum--avg--min--max-and-len On Thursday, December 11, 2014 8:32:03 AM UTC+1, Anthony Smith wrote: Hi I have the following sql which returns what I want , but losted on how to use in my web2py controller. any

[web2py] Re: migrate and fake_migrate

2014-12-12 Thread Niphlod
nope, can't reproduce the issue. Something very weird is going on on your development system. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You

[web2py] Re: migrate and fake_migrate

2014-12-11 Thread Niphlod
ProgrammingError: column f2 of relation mi_tabla does not exist Once again.. this exception is raised when some piece of code references f2 from mi_tabla. I'd be happy to find that piece of code for you if you pack an app that reproduces the issue. -- Resources: -

[web2py] Re: How do you handle audits?

2014-12-11 Thread Niphlod
depends on what you need to track, and what report you need to run on user activity. If you need to store the info about who changed what at what time, it's not going to be easier than simply using the battery-included versioning. If instead you want to show something as userA started following

[web2py] Re: web2py on a dedicated server

2014-12-11 Thread Niphlod
@gael: aside from suggestions of using something else, that are not useful for someone telling that I find myself stucked with provider X all that it takes is to tune apache2 config accordingly to what is needed, specifically a rewrite rule that you can find everywhere in scripts/setup*

[web2py] Re: migrate and fake_migrate

2014-12-10 Thread Niphlod
BTW, what you are experiencing is totally predictable, but you're barking at the wrong tree. now: migrate=True, fake_migrate=False db.define_table('mi_tabla', Field('f1', 'integer'), Field('f2', 'integer'), Field('f3', 'integer'), Field('f4', 'integer'),

[web2py] Re: change standard grid button text

2014-12-10 Thread Niphlod
except fiddling with translations, I don't think so. On Wednesday, December 10, 2014 11:05:30 AM UTC+1, Manuele wrote: Hi *, is there a standard, or easy at least, way to change standard grid button text? Thank you in advance Cheers Manuele -- Resources: - http://web2py.com

Re: [web2py] Can the web2py validators be used outside of forms?

2014-12-10 Thread Niphlod
BTW, for the specific case there's IS_LIST_OF_EMAILS :P On Wednesday, December 10, 2014 10:21:07 AM UTC+1, desta wrote: Thank you Manuele for the quick answer. Even though I read the documentation I didn't understand that I could do that! Thank you for pointing that out to me. It works

[web2py] Re: are expired session files deleted automatically?

2014-12-09 Thread Niphlod
wrote: what about on linux filesystems? also, isn't folders the default in later web2py? Den söndagen den 30:e november 2014 kl. 13:39:34 UTC+1 skrev Niphlod: folders do not create a performance issue on ntfs. if you want to keep it clean for aestethical reasons, do it with another step

Re: [web2py] How to use DAL with effective dated queries

2014-12-09 Thread Niphlod
like this) - Think i will stick to crafted SQL for now! Remco Op maandag 8 december 2014 19:20:20 UTC+1 schreef Niphlod: given that the aliases are not supported in master-sub selects (i.e. they're coded with the same level of aliasing in mind, whereas your select needs to propagate

Re: [web2py] Get a Web2py cloud instance in less than 30 seconds

2014-12-09 Thread Niphlod
checking isn't needed. if you want to access admin is either through https or http on localhost. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You

<    9   10   11   12   13   14   15   16   17   18   >