Try run
python web2py.py -S welcome
then do things manually
>>> db = DAL('oracle://',migrate=True)
>>> db.define_tables('person',Field('name'))
etc. See what goes wrong. If your want to access tables that are already
there you set migrate=False but still need to define_table them.
On Mon
Can you connect to the database outside of Web2py?
The long delay can mean connection problems, which I have induced by typing
the db name incorrectly.
On Monday, October 8, 2012 8:06:58 PM UTC-4, Bill Thayer wrote:
>
> Hi Massimo,
>
> Thank you.
>
> After installing the latest version I delet
OOPS. No, that does not stand for object oriented programming superstar!
On Monday, October 8, 2012 6:53:42 PM UTC-4, Massimo Di Pierro wrote:
>
> It is
>
> auth.enable_record_versioning(db)
>
> not
>
> auth.enable_record_versioning=True # Doh!
>
> On Monday, 8 October 2012 15:21:48 UTC-5, Mass
did you open an issue?
http://code.google.com/p/web2py/issues/list
On Saturday, October 6, 2012 11:28:32 AM UTC-7, Gerd wrote:
>
> Hi!
>
> Any updates on this?
>
> Am Sonntag, 30. September 2012 16:16:33 UTC+2 schrieb Gerd:
>>
>> Hi!
>>
>> I'm actually using V2.0.9 and the error is still active. I
Hi Massimo,
Thank you.
After installing the latest version I deleted the contents of the databases
folder and run with DAL(...,migrate=True) got one error, set the table
causing the error to migrate=false and re-ran. Now all the database tables
are created but now (after seting my settings.mig
Thanks, I will update the repo.
--
It is
auth.enable_record_versioning(db)
not
auth.enable_record_versioning=True # Doh!
On Monday, 8 October 2012 15:21:48 UTC-5, Massimo Di Pierro wrote:
>
> There are two ways to do record versioning in web2py:
>
> - the old way using auth.archive (the one you are using). When a record is
>
Thanks to everybody for fixing this!
You might also want to make a similar change at about line 244:
try:
field = sqlrows.db[tablename][fieldname]
# except KeyError:
except (KeyError,AttributeError):
field = Non
LOL
- Make sure you use stable "Version 2.0.9 (2012-09-13 23:51:30)" of the
latest trunk. Not any intermediate version.
- do not use the wizard if you do not want crap. The wizard is experimental
and not the best piece of web2py.
- If your tables already exist and you are happy with them run onc
auth.enable_record_versioning=True is written at the end of the model.
Didn't work.
On Monday, October 8, 2012 4:21:48 PM UTC-4, Massimo Di Pierro wrote:
>
> There are two ways to do record versioning in web2py:
>
> - the old way using auth.archive (the one you are using). When a record is
> mo
Ok,
I have my Oracle database. From some attempted migrations I have the auth
tables defined and two other tables defined of about 17 tables.The typical
error is Object with that name already exists or some crap like that. I
figured clicking the clean button would help... DON"T DO THAT! Now my
Web2py does not support this. It must be handled outside web2py, for
example using a ssh tunnel.
Can you tell us more about the setup and the database?
massimo
On Monday, 8 October 2012 15:24:02 UTC-5, Brandon Reynolds wrote:
>
> I am having trouble accomplishing this. I am new to this still and
I've seen this before but I cannot remember what's causing it.
I have @auth.requires_login() decorating several of my controller
functions. I log in first, 'go' to one of those controller functions/pages
in my browser, and I get challenged to log in (even though I'm already
logged in). I log in
this is horribly outdated, but should give you some
ideashttp://www.web2pyslices.com/slice/show/1402/facebook-twitter-and-google-authentication
i don't think that version of FB auth works at all anymore.
On Sunday, October 7, 2012 3:33:28 AM UTC-7, Kenneth wrote:
>
> Hello everyone,
>
>
Massimo, I agree with your points, not necessarily 3, but then again, i've
had many years of experience writing sql queries, so i know what can go
wrong, and i know why you might say that to a beginner.
On Friday, October 5, 2012 7:24:40 AM UTC-7, Massimo Di Pierro wrote:
>
> I am not sure about
I think the only problem here is that you copied a working copy of web2py,
not a fresh copy. There are files in there that are system specific
(applications/app/cache/* and applications/app/cron/*). You should delete
them before you copy web2py,else web2py will try delete them itself and
fail (
I am having trouble accomplishing this. I am new to this still and have
never encountered a db that requires such a thing. How do i tell web2py to
use this certificate that allows me to connect?
--
There are two ways to do record versioning in web2py:
- the old way using auth.archive (the one you are using). When a record is
modified the old record is copied into the archive table. When a record is
deleted, it is actually deleted and a copy of the old one is saved.
- the new way auth.enab
:-)
On Monday, 8 October 2012 12:53:27 UTC-5, Don_X wrote:
>
> BINGO ! - IT WORKS LIKE A CHARM MASSIMO !!! ...
>
> Thank you ... now I can study this properly so I can adapt it to my app !
>
> On Monday, October 8, 2012 1:49:09 PM UTC-4, Massimo Di Pierro wrote:
>>
>> Now the error is at a diff
Just wanted to add, keep reading down that page, it shows how web2py is
configured for GAE (google app engine) because GAE also doesn't have access
to the file system. That could be useful for what you are trying to do.
On Monday, October 8, 2012 1:02:38 PM UTC-7, Derek wrote:
>
> web2py is ligh
web2py is light? first i've heard... well, it seems that you are getting
these errors because it does not have write access?
You can try the recipe listed here:
http://web2py.com/book/default/chapter/13#Memcache
This replaces the disk cache with memcache.
On Saturday, October 6, 2012 6:46:17
And if you want to see what ones are reserved, check here:
gluon/reserved_sql_keywords.py
On Monday, October 8, 2012 12:49:00 PM UTC-7, Niphlod wrote:
>
> that's because probably you are using names that your db does not allow as
> names because they are functions (i.e. naming a field "select" w
that's because probably you are using names that your db does not allow as
names because they are functions (i.e. naming a field "select" wouldn't
work on most of the dbs).
http://web2py.com/books/default/chapter/29/06#Reserved-keywords
On Monday, October 8, 2012 9:42:33 PM UTC+2, VP wrote:
>
>
http://web2py.com/books/default/chapter/29/06?search=reserved#Reserved-keywords
Standard SQL keywords are normally reserved in all SQL databases. "Order"
is a sql keyword, so it may not be reserved by web2py but the database
itself. To give you an example, here are a few...
http://dev.mysql.com
I've always had this problem with web2py. Sometime, I got a weird name
violation. For example, you can't name a table "order", or can't name a
field "item". It doesn't seem to be documented anywhere.
--
You are doing nothing wrong, perhaps you had a misunderstanding of how
versioning works.
Do do what you want, look at the before_delete callback. You'd want to
return 'true' to abort the delete operation.
http://web2py.com/books/default/chapter/29/06#before-and-after-callbacks
On Monday, Oct
the code is not in trunk, it's only on my machine: current web2py has no
knowledge of saving sessions in redis.
On Monday, October 8, 2012 6:30:49 PM UTC+2, rif wrote:
>
> Thank you and take your time. I will report any issues I find with it.
>
> Right now after Massimo's fix I get this:
>
> Trac
if you point to a https:// page but your server isn't serving any ssl
protected content, that error thrown by firefox will stand no matter what.
normal setups don't take the port into account: in production, for http
urls the port is always 80 and for https:// the port is 443. If you want
that
I have the following, but checking the delete box actually deletes the
record rather than setting is_active to False.
It creates records in the archive table, but I also want them to stay in
the main table with is_active set to False.
What am I doing wrong?
Thank you,
Cliff Kachinske
Model
db
I suggest you download a copy of the web2py manual
(http://web2py.com/book). Read and run the snippet on pagination.
with a some tweaks you could as well achieve an infinite scroll pagination.
On Thursday, October 4, 2012 4:16:00 PM UTC+2, Paulo Donizeti Gardinalli
Filho wrote:
>
> hi, I am sta
I'll take a look. Any ideas why I get the:
ImportError:No module named gluon.contrib.login_methods.gae_google_account
Kenneth
Look into
gluon/contrib/login_methods/extended_login_form.py
On Monday, 8 October 2012 07:48:04 UTC-5, Kenneth wrote:
Hi again,
does anyone know if it is
BINGO ! - IT WORKS LIKE A CHARM MASSIMO !!! ...
Thank you ... now I can study this properly so I can adapt it to my app !
On Monday, October 8, 2012 1:49:09 PM UTC-4, Massimo Di Pierro wrote:
>
> Now the error is at a different line. The previous error has been fixed.
> Now it is at line 215:
Now the error is at a different line. The previous error has been fixed.
Now it is at line 215:
try:
_id = record[keycolumntbl][keycolumnfld]
except KeyError:
as before it should be
try:
_id = record[keycolumntbl][keycolumnfl
El lunes, 8 de octubre de 2012 14:32:47 UTC-3, Massimo Di Pierro escribió:
>
> You have different ways:
>
> if request.function!='maintenance':
> try:
> db = DAL('sqlite://storage.sqlite')
> except:
> redirect(URL('default', 'maintenance'))
> else: db = None
>
> But then
I think something else is going on...
With the current version from trunk and Masssimo's code above verified to
be in gluon/globals.py and
request.requires_https()
uncommented in db.py the following error occurs:
If I try: https:127.0.0.1:8000/TAMOTO/appadmin/insert/db/auth_user
I get an er
Bruno .. I am using the app example from your bitbucket
the web2py.app.skrywer_powertable.w2p
On Monday, October 8, 2012 1:33:50 PM UTC-4, rochacbruno wrote:
>
> Hi Don,
>
> I will try to reproduce it here and maybe make some updates to plugin.
>
> Can you give me a full code sample? The bas
For a more detailed report .. I have openned up the last line pertaining to
the plugin_powertable.py below :
-
Function argument list
()
Code listing
20.
21.
22.
23.
24.
25.
It cannot be. The former traceback said:
File
"/home/fvillarroel/www/web2py/applications/administrador/models/plugin_powertable.py",
line 178, in __init__
headers[c] = sqlrows.db[t][f].label
now this line does not exist any more. Please report the complete traceback.
On Monday, Octobe
Hi Don,
I will try to reproduce it here and maybe make some updates to plugin.
Can you give me a full code sample? The basic model you are using, the
powerTable options etc.. (if you can put on a pastebin)
Thanks
--
You have different ways:
if request.function!='maintenance':
try:
db = DAL('sqlite://storage.sqlite')
except:
redirect(URL('default', 'maintenance'))
else: db = None
But then you need to check (if db) every time you use db in models.
You can use conditional models:
- Mo
Same as above Massimo ... it gives the exact same traceback as above ...
and the lines that I have changed are from line no 177 to 185 as follows :
>
elif headers=='labels':
headers = {}
for c in columns:
(t,f) = c.split('.')
table =
El lunes, 8 de octubre de 2012 14:01:44 UTC-3, Massimo Di Pierro escribió:
>
> Why did you get a cycle?
>
Because when you redirect to the maintenance, run again the model
(connection to the database)
Jose
--
Can you show a complete traceback and a code snipped of powertable? I guess
my version of powertable does not match yours or the error is now at a
different line.
On Monday, 8 October 2012 12:07:46 UTC-5, Don_X wrote:
>
> Thank you Massimo .. but the same error persists ... with both
> suggest
Thank you Massimo .. but the same error persists ... with both suggestions
!
--
In your code:
form = SQLFORM(db.checkout, formstyle='divs')
if form.process(onvalidation=check_database_entry).accepted:
for key, value in session.cart.items():
db.checkout.insert(userinfo = auth.user.id,
product = key,
Why did you get a cycle?
On Monday, 8 October 2012 11:25:53 UTC-5, Jose wrote:
>
> Hi,
>
> I want to make the connection to the database within a try block
>
> try:
> db = DAL('sqlite://storage.sqlite')
> except:
> redirect(URL(c='default', f='maintenance'))
>
> but, obviously, this comes
On Linux, if you have postfix, you can just spoof your domain:
mail.settings.sender = 'y...@anywhere.com'
mail.settings.server = 'localhost'
mail.settings.login = None
On Monday, 8 October 2012 11:22:25 UTC-5, LightDot wrote:
>
> Well, if your domain is hosted somewhere, the provider usually gi
Or better this should be:
table = sqlrows.db[t]
if f in table.fields:
headers[c] = table[f].label
else:
On Monday, 8 October 2012 11:55:23 UTC-5, Massimo Di Pierro wrote:
>
> The error is that in plugin_powertable.py there are t
Have you setup https? Created certificates... told web2py where
certificates are?
Massimo
On Monday, 8 October 2012 10:57:15 UTC-5, jw wrote:
>
> Hi!
>
> I'm getting desperated about this issue.
> The server is running fine over http and in the "normal" mode on an WinXP
> machine. I'm running i
The error is that in plugin_powertable.py there are these lines:
try:
headers[c] = sqlrows.db[t][f].label
except KeyError:
They should be changed to
try:
headers[c] = sqlrows.db[t][f].label
ex
I am trying to solve an issue in my code and hoping some of you can help
I have a cart functionality for *reserving* items based on a month / day /
year reservation. The problem is an extra entry is being added to the
database when I submit the form.
Any ideas how to fix this also will my *chec
Thank you and take your time. I will report any issues I find with it.
Right now after Massimo's fix I get this:
Traceback (most recent call last):
File "/home/rif/Documents/webframeworks/web2py/gluon/main.py", line 541,
in wsgibase
session._try_store_in_db(request, response)
File "/home
Hi,
I want to make the connection to the database within a try block
try:
db = DAL('sqlite://storage.sqlite')
except:
redirect(URL(c='default', f='maintenance'))
but, obviously, this comes into a cycle of error trapping error.
how I can secure the connection to the database and returns
Well, if your domain is hosted somewhere, the provider usually gives you
access to a mail server too. The access information needed is pretty
obvious, username and password, same as you need for regular SMTP access.
Regards,
Ales
On Monday, October 8, 2012 1:40:19 PM UTC+2, Hassan Alnatour wro
give me some time, I need to polish it with some improvements also on the
redis cache side.
The current implementation is quite dumb (but redis is fast so no-one
noticed problems).
If you're up with testing it at least I can be sure it will work on 3
machines (my test rig, my production env, yo
I find it better than memcache because the sessions would survive a
restart. So while I can settle on using memcache but I feel like I am
loosing something.
I really see no reason to store them on the disk or in db (except limited
memory).
-rif
luni, 8 octombrie 2012, 18:44:09 UTC+3, Niphlod
This particular error is a bug with trunk. I just fixed it. Whether you can
store session in redis or not is another issue. Niphlod is the expert on
that.
On Monday, 8 October 2012 09:48:52 UTC-5, rif wrote:
>
> Is the code bellow the correct way to create the sessions in redis?
>
> from gluon.c
Which version are you using? If you downloaded the latest trunk/stable and
open the web2py/VERSION file, there should no longer be an rc1 in there and
the problem should be gone.
On Monday, 8 October 2012 10:27:29 UTC-5, Don_X wrote:
>
>
> oupss .. I spoke too fast ...
>
> it opens up .. but can
Hi!
I'm getting desperated about this issue.
The server is running fine over http and in the "normal" mode on an WinXP
machine. I'm running it on 8000 and on 443.
I'm trying to access the appadmin page over https and 443 but I only get
the message: 'Admin is disabled because insecure channel' f
it runs by bypassing the admin/default/index page ...
but F.Y.I
the powertable app example still does not run : I get the following error :
'Row' object has no attribute 'product'
Versionweb2py™(2, 1, 0, datetime.datetime(2012, 10, 8, 15, 17, 50), 'dev')
PythonPython 2.7.3: /usr/bin/python
T
ATM, storing session in redis is a bunch of lines put together a month ago
by me, but it needs to be tested carefully before releasing it.
Moreover, it's possible that there are 3 peoples using redis with web2py
(me, you, bruno), so I prefer spending time on developing other things.
Il giorno l
Massimo,
the latest trunk or nightly build ... they do not run for now !
--
## connect to Google BigTable (optional 'google:datastore://namespace')
db = DAL('google:datastore')
## store sessions and tickets there
session.connect(request, response, db = db)
## or store session in Memcache, Redis, etc.
The last line above misled me. so it is possible to stor
oupss .. I spoke too fast ...
it opens up .. but cannot get to the admin/default/index page ! .. I get a
error link and when I clicked to see the ticket .. I simply get another
link to click on .. and on .. and on ...
--
fixed it !
took it out of the version file !
--
no, currently support for sessions in redis is not there.
Il giorno lunedì 8 ottobre 2012 16:48:52 UTC+2, rif ha scritto:
>
> Is the code bellow the correct way to create the sessions in redis?
>
> from gluon.contrib.memdb import MEMDB
> from gluon.contrib.redis_cache import RedisCache
> cache.re
the problem here is mainly that he's doing one query to retrieve the row.
then it's changing request.args to be able to call response.download (other
queries involved). That means that the query used to retrieve the filename
based on the custom key he's using is requiring and additional 800ms.
I just downloaded the nightly build and the trunk version they are not
running ! my apache server error log gives me this :
[Mon Oct 08 10:57:37 2012] [error] [client 127.0.0.1] mod_wsgi (pid=2009):
Target WSGI script '/home/www-data/web2py/wsgihandler.py' cannot be loaded
as Python module.
Is the code bellow the correct way to create the sessions in redis?
from gluon.contrib.memdb import MEMDB
from gluon.contrib.redis_cache import RedisCache
cache.redis = RedisCache('localhost:6379',db=None, debug=True)
session.connect(request, response, db = MEMDB(cache.redis))
If yes, there is an
Il 08/10/2012 16:18, Massimo Di Pierro ha scritto:
No. Virtual fields are only created after the data is retrieved.
You can create a calculated hidden field instead of a virtual field
and use that.
thanks a lot!
M.
--
finally solved ! with a different approach alltogether !
I have a short sign-up form and a long sign-up form for the same auth_user
table !
the short sign-up form deals with the first fields with requires defined in
the model while the additional fields do not have any requires and most
are se
Please use the latest trunk or nightly built. This problem has been fixed
yesterday.
On Monday, 8 October 2012 08:52:17 UTC-5, Don_X wrote:
>
>
> PowerGrid works with the latests web2py 2+ . while Powertable does
> not
>
> I was wondering what the real differences are between these 2 power
No. Virtual fields are only created after the data is retrieved.
You can create a calculated hidden field instead of a virtual field and use
that.
On Monday, 8 October 2012 07:57:45 UTC-5, Manuele wrote:
>
> Could it be possible to query for the sum of a (new style) virtual field
> directly?
>
Look into
gluon/contrib/login_methods/extended_login_form.py
On Monday, 8 October 2012 07:48:04 UTC-5, Kenneth wrote:
>
> Hi again,
>
> does anyone know if it is possible to have two auth mechanism. Like Google
> App users and local users?
>
>
> Kenneth
>
> Hello everyone,
>
> I have an appli
Sorry about this. removing the rc1.
On Monday, 8 October 2012 06:47:27 UTC-5, David Marko wrote:
>
> +1 ... it really doesnt start ...
>
> Dne pondělí, 8. října 2012 9:26:35 UTC+2 szimszon napsal(a):
>>
>> In 2.1.0rc1 admin do not work.
>>
>> S'Traceback (most recent call last):\n File
>> "/hom
Not supported yet. The code is actually in web2py but need some polishing.
This may be done during this week actually. Please open a ticket about this.
On Monday, 8 October 2012 05:27:43 UTC-5, Vasile Ermicioi wrote:
>
> hi,
>
> how to use signed cookies with web2py? ( instead of creating a lot o
You are telling us that row = dbs.image(filename=name) takes 1200-400ms on
your server. That is a lot.
You should:
1) try cache the requests
row = dbs(dbs.image.filename=name).select(cache=(cache.ram,3600)).first()
periodically you will need to clear cache to prevent leaks.
2) create an ind
PowerGrid works with the latests web2py 2+ . while Powertable does not
I was wondering what the real differences are between these 2 powerfull
plugins
they both seems to do basically the same things ... but PowerTable looks
much better and seems to have more options ... !
the app examp
Could it be possible to query for the sum of a (new style) virtual field
directly?
Thankyou very mutch
Manuele
--
Hi again,
does anyone know if it is possible to have two auth mechanism. Like
Google App users and local users?
Kenneth
Hello everyone,
I have an application where I'd like use an Google App account for
authentication. The application will not reside on GAE. Is this possible?
If I put "
Solved using JQuery, No need to put the event in the .
Can bind the event externally:
index.html
function on_field_changed(){
//
}
$(document).ready(function() {
$("#form_field").blur( function(){on_field_changed()});
});
I used blur and not change, because I had a problem w
+1 ... it really doesnt start ...
Dne pondělí, 8. října 2012 9:26:35 UTC+2 szimszon napsal(a):
>
> In 2.1.0rc1 admin do not work.
>
> S'Traceback (most recent call last):\n File
> "/home/gyszabolcs/fejlesztes/web2py/gluon/main.py", line 616, in
> wsgibase\nBaseAdapter.
> close_all_instance
Dear ALL,
i want to add my email in the db.py to use it to send email from the site ,
how can i make it using my own domain not gmail ?
Best Regards,
--
Thank you i will do as you guys said. Thank for help!
Il giorno venerdì 5 ottobre 2012 15:47:40 UTC+2, villas ha scritto:
>
> Just change your models/menu.py to have a conditional section which will
> add a section to response.menu, perhaps comething like this:
>
> if auth.has_membership('
hi,
how to use signed cookies with web2py? ( instead of creating a lot of
session files)
I read that flask uses them for storing session data
--
To optimize SEO, I prefer to use descriptive, keyword-rich image filenames
instead of the auto-generated names used by web2py.
Currently, I am using a custom download function that looks up the
auto-generated filename in a database using the original filename as a key,
then uses the standard
I have this custom form:
{{=form.create_form.custom.begin}}
{{=*form.create_form.custom.widget.field*}}
{{=form.create_form.custom.submit}}
{{=form.create_form.custom.end}}
how do I attach an event "onclick" to the widget 'field", to obtain this?
--
hello one and all,
using linux, centos 6, and web2py 2.0.9.
how do i update or change the admin password under the console or
command-line editor?
thanx in advance, lucas
--
In 2.1.0rc1 admin do not work.
S'Traceback (most recent call last):\n File
"/home/gyszabolcs/fejlesztes/web2py/gluon/main.py", line 616, in
wsgibase\nBaseAdapter.
close_all_instances(\'rollback\')\n File
"/home/gyszabolcs/fejlesztes/web2py/gluon/dal.py", line 529, in
close_all_instances\
parse_version can handle only numbers... and not rc1 :(
fileutils.py line 46:
re_version = re.compile('[^\d]+
(\d+)\.(\d+)\.(\d+)\s*\((?P.+?)\)\s*(?P[a-z]+)?')
--
Hi,
I like the idea.
My first thought is having an application that enlist the appliances and
their features ( web2py 2.0 , wiki page , calendar ,
workflow , map , tree , ).
That is to monitor the status of the appliances and their upgrade.
Regards,
Ashraf
On Sunday, October 7, 2012 1
Hi,
I like the idea.
My first thought is having an application that enlist the appliances and
their features ( web2py 2.0 , wiki page , calendar ,
workflow , map , tree , ).
That is to monitor the status of the appliances and their upgrade.
Regards,
Ashraf
On Sunday, October 7, 2012 1
Per the subject line, I can click to drop down the links but I can't click on
them.
This is on production and using stable.
May I know how to resolve? Thanks!
--
93 matches
Mail list logo