[web2py] web2py Conference Management System

2010-05-26 Thread KR
Hello,

There is a Vimeo screencast (http://www.vimeo.com/1838049) about a
web2py Conference Management System. Does anybody know wher I can
download the soource code of that ?


[web2py] Re: web2py Conference Management System

2010-05-31 Thread KR
Hello,

Thanks for the answers.

I tried both versions and none of them works out of the box.

Here is the trace for the Flisol (same as the PyCon) one:

x...@box~/work/web2py/web2py$ python web2py.py -S web2confF -M
web2py Enterprise Web Framework
Created by Massimo Di Pierro, Copyright 2007-2010
Version 1.78.3 (2010-05-17 21:59:39)
Database drivers available: SQLite3
Traceback (most recent call last):
  File "/home/xxx/work/web2py/web2py/gluon/restricted.py", line 178,
in restricted
exec ccode in environment
  File "applications/web2confF/models/db_cleanup.py", line 1, in

db(db.payment.created_on
self._execute = lambda *a, **b: self._cursor.execute(*a, **b)
OperationalError: no such table: payment

If somebody has a simple way to make it work, I will do that.
Otherwize, I will remove the payment stuffs (not sure to use it
anyway). Help for doing that would be appreciate as well.

Some info:
- web2py Version 1.78.3 (2010-05-17 21:59:39) (if I need a previous
version, which one and where to find it please ?)
- I don't understand spanish (french is my mother tongue)
- I need some CMS (or at least wiki) functionnality to manage the
website
- I deleted the databases folder and recreated it (empty)
- The default "reingart-web2conf" works after having replaced
db=SQLDB(DBURI,pools=DBPOOLS) by db=SQLDB(DBURI) and create the non
existant databases folder. But they are other issues (balance is
none ? making some requests failed) and it seems not to implement some
CMS functionnalities.

Thx already.

On 27 mai, 07:23, Yarko Tymciurak  wrote:
> Mariano -
>
> Thank you - I hadn't seen that you made a clone.
>
> FYI for others:  you can the list of clones 
> at:http://code.google.com/p/web2conf/source/clones
>
> I will look over this in June, and look at merging back (there are
> things in the base web2conf that need cleanup, updates - which looks
> like Mariano made many).
>
> - Yarko
>
> On May 26, 2:32 pm, Mariano Reingart  wrote:
>
> > On Wed, May 26, 2010 at 2:19 PM, Yarko Tymciurak
>
> >  wrote:
>
> > > On May 26, 9:23 am, KR  wrote:
> > >> Hello,
>
> > >> There is a Vimeo screencast (http://www.vimeo.com/1838049) about a
> > >> web2py Conference Management System. Does anybody know wher I can
> > >> download the soource code of that ?
>
> > > You can get the version used at PyCon-2010 at code.google.com/p/
> > > web2conf
>
> > > There is also an older version, which was modified for FLISOL-2010
> > > I'll have to find that (eventually, that should be merged back to
> > > web2conf).
>
> > You can found them in flisol 2010 and pyday branches of my web2conf clone:
>
> >http://code.google.com/r/reingart-web2conf/
>
> > Flisol:http://code.google.com/r/reingart-web2conf/source/browse/?r=1d551738b...
>
> > PyDay:http://code.google.com/r/reingart-web2conf/source/browse/?r=0776772cb...
>
> > Running 
> > sites:http://www.institutopascal.edu.ar/flisol2010?lang=eshttp://www.pyday
>
> > Sorry, I didn't have time to generalize them and merge back to the
> > web2conf trunk.
>
> > > Right now, web2conf needs a few updates and refactorings (typically,
> > > during the course of a registration cycle, things are fixed, added,
> > > etc. and should be re-visited, cleaned).   For example this web2conf
> > > is based on an older version of web2py.
>
> > I would be cleaning up some things, if there are any plans, please let me 
> > know.
>
> > I'm thinking of:
> >  * Spearate default.py into talks.py, registration.py statics.py, etc.
> >  * Finish talk reviewing/voting
> >  * Eliminate some T2 stuff
> >  * Rewrite PDF generation (badge and attendance certificate) using
> > PyFPDF (removing dependencies like dabo)
> >  * Speed-up, caching, cleanup, easier configuration, etc.
>
> > Best regards,
>
> > Mariano 
> > Reingarthttp://www.web2py.com.arhttp://www.sistemasagiles.com.arhttp://reinga...


[web2py] Submenus and IE6

2010-06-16 Thread KR
Hi,

I have the same problem as in that thread : Submenus and IE6 (
http://groups.google.be/group/web2py/browse_thread/thread/5b80149ee6cb508b/61fd3cb44109803e
)

To make sure that I didn't messed all up, I installed a fresh new
1.19.2 web2py and I tried on the welcome/default/index page. On my
windows with firefox PC it works as expected : I can see the
Controller-View_layout-... submenu when I put the mouse pointer on
Edit (in the left column). Unfortunately, when I use an older Windows
box with IE6 (we have a lot like that), nothing happens when I put the
pointer on the Edit field.

I need to deploy an application and upgrade IE6 is not an option.
Javascript is working, I checked it. The patch:





is in the layout (as a one-liner) out of the box.

What can I do ?

Thanks already.


[web2py] Re: Submenus and IE6

2010-06-16 Thread KR
Hi again,

I just installed web2py 1.75.5 (according to the VERSION file, I
downloaded the 1.75.4: http://web2py.com/examples/static/1.75.4/web2py_src.zip)
and it works.
According to the changelog, the bug was fixed on the 1.75.1 and I
downloaded the first version available after that one to check it.

Apparently there is a regression bug somewhere.

If somebody has an idea about that, I'm intersted. Any hint would be
appreciated in order to find the last version after the 1.75.5 still
OK with IE6. Having that, it will be easier to fix that bug ... or to
decide to stay with that version.

On 16 juin, 13:01, KR  wrote:
> Hi,
>
> I have the same problem as in that thread : Submenus and IE6 
> (http://groups.google.be/group/web2py/browse_thread/thread/5b80149ee6c...
> )
>
> To make sure that I didn't messed all up, I installed a fresh new
> 1.19.2 web2py and I tried on the welcome/default/index page. On my
> windows with firefox PC it works as expected : I can see the
> Controller-View_layout-... submenu when I put the mouse pointer on
> Edit (in the left column). Unfortunately, when I use an older Windows
> box with IE6 (we have a lot like that), nothing happens when I put the
> pointer on the Edit field.
>
> I need to deploy an application and upgrade IE6 is not an option.
> Javascript is working, I checked it. The patch:
>
> 
> <!--
> /* this adds sfhover class to menu li items to make IE6 work */
> jQuery(document).ready(function(){
>     jQuery('li.web2py-menu-expand').hover(
>         function () {
>             jQuery(this).addClass('sfhover');
>         },
>         function () {
>             jQuery(this).removeClass('sfhover');
>         }
>     );
>
> });
>
> //-->
> 
>
> is in the layout (as a one-liner) out of the box.
>
> What can I do ?
>
> Thanks already.


[web2py] Re: Submenus and IE6

2010-06-16 Thread KR
1.79.2 not 1.19.2 (in the first mail)

On 16 juin, 13:01, KR  wrote:
> Hi,
>
> I have the same problem as in that thread : Submenus and IE6 
> (http://groups.google.be/group/web2py/browse_thread/thread/5b80149ee6c...
> )
>
> To make sure that I didn't messed all up, I installed a fresh new
> 1.19.2 web2py and I tried on the welcome/default/index page. On my
> windows with firefox PC it works as expected : I can see the
> Controller-View_layout-... submenu when I put the mouse pointer on
> Edit (in the left column). Unfortunately, when I use an older Windows
> box with IE6 (we have a lot like that), nothing happens when I put the
> pointer on the Edit field.
>
> I need to deploy an application and upgrade IE6 is not an option.
> Javascript is working, I checked it. The patch:
>
> 
> <!--
> /* this adds sfhover class to menu li items to make IE6 work */
> jQuery(document).ready(function(){
>     jQuery('li.web2py-menu-expand').hover(
>         function () {
>             jQuery(this).addClass('sfhover');
>         },
>         function () {
>             jQuery(this).removeClass('sfhover');
>         }
>     );
>
> });
>
> //-->
> 
>
> is in the layout (as a one-liner) out of the box.
>
> What can I do ?
>
> Thanks already.


[web2py] Re: url rewrite for SEO optimization

2010-06-16 Thread KR
routes.py is the way to do it
it's a standard file of web2py

On 16 juin, 20:36, Michelle Jun  wrote:
> hi
>
> i am wondering if i can do these things
>
> for example, i have list of businesses url links (this is generated
> from my web2py default)
>
> http://domain.com/default/business/8http://domain.com/default/business/9http://domain.com/default/business/10http://domain.com/default/business/11http://domain.com/default/business/12http://domain.com/default/business/13http://domain.com/default/business/14http://domain.com/default/business/15
> etc...
>
> is it possible that i rewrite this to become just
>
> http://domain.com/8http://domain.com/9http://domain.com/10http://domain.com/11http://domain.com/12http://domain.com/13
> etc..
>
> is there anyway to do it within web2py or is it something that i have
> to do it within apache mod_rewrite? any idea on how to do that?
>
> thank you


[web2py] Re: Submenus and IE6

2010-06-17 Thread KR
Here is the solution:
- replace:

  <!-- /* this adds sfhover class to menu li items to make IE6
work */ jQuery(document).ready(function(){jQuery('li.web2py-menu-
expand').hover(function ()
{jQuery(this).addClass('sfhover');},function ()
{jQuery(this).removeClass('sfhover');});});//-->

- by the script above (first mail) or even by:
<!--
/* this adds sfhover class to menu li items to make IE6 work */
jQuery(document).ready(function(){jQuery('li.web2py-menu-
expand').hover(function ()
{jQuery(this).addClass('sfhover');},function ()
{jQuery(this).removeClass('sfhover');});}); //  -->

and it works ! Simpler than I tought. There is something wrong with
the oneliner version of the script introduced in release 1.77.1
Something related with a new line in comments.

BTW, is there anything wrong in my post, they were no answers :-(

Thanks for web2py anyway. It's more than great.

On 16 juin, 17:40, KR  wrote:
> Hi again,
>
> I just installed web2py 1.75.5 (according to the VERSION file, I
> downloaded the 1.75.4:http://web2py.com/examples/static/1.75.4/web2py_src.zip)
> and it works.
> According to the changelog, the bug was fixed on the 1.75.1 and I
> downloaded the first version available after that one to check it.
>
> Apparently there is a regression bug somewhere.
>
> If somebody has an idea about that, I'm intersted. Any hint would be
> appreciated in order to find the last version after the 1.75.5 still
> OK with IE6. Having that, it will be easier to fix that bug ... or to
> decide to stay with that version.
>
> On 16 juin, 13:01, KR  wrote:
>
> > Hi,
>
> > I have the same problem as in that thread : Submenus and IE6 
> > (http://groups.google.be/group/web2py/browse_thread/thread/5b80149ee6c...
> > )
>
> > To make sure that I didn't messed all up, I installed a fresh new
> > 1.19.2 web2py and I tried on the welcome/default/index page. On my
> > windows with firefox PC it works as expected : I can see the
> > Controller-View_layout-... submenu when I put the mouse pointer on
> > Edit (in the left column). Unfortunately, when I use an older Windows
> > box with IE6 (we have a lot like that), nothing happens when I put the
> > pointer on the Edit field.
>
> > I need to deploy an application and upgrade IE6 is not an option.
> > Javascript is working, I checked it. The patch:
>
> > 
> > <!--
> > /* this adds sfhover class to menu li items to make IE6 work */
> > jQuery(document).ready(function(){
> >     jQuery('li.web2py-menu-expand').hover(
> >         function () {
> >             jQuery(this).addClass('sfhover');
> >         },
> >         function () {
> >             jQuery(this).removeClass('sfhover');
> >         }
> >     );
>
> > });
>
> > //-->
> > 
>
> > is in the layout (as a one-liner) out of the box.
>
> > What can I do ?
>
> > Thanks already.


[web2py] Re: SSL & admin

2010-06-21 Thread KR
http://web2pyslices.com/main/slices/take_slice/71

On 21 juin, 19:42, oncle_bob  wrote:
> I can't configure a ssl virtualhost.
>
> How can I bypass the ssl requirement for admin page ?
>
> Thank you.
>
> Julien


[web2py] Re: Password verification - how to?

2010-07-05 Thread KR
Do you have somewhere in your code TD=something ?

On 6 juil, 01:18, elfuego1  wrote:
> Can you please tell me yet how to implement it, so it would start
> working in my form and verify the password?
> When I add it to view: user.html or controller default.py then I
> receive:
> TypeError: 'TD' object is not callable
>
> So please let me know how to use form.element syntax to make it work
> properly.
>
> On 4 Lip, 17:08, mdipierro  wrote:
>
> > form.element(_name=='password').insert(INPUT(_name='password2',requires=IS_EXPR('value=
> > %s' % repr(request.vars.password)) ))
> > should have been
> > form.element(_name='password').parent().append(INPUT(_name='password2',requires=IS_EXPR('value=
> > %s' % repr(request.vars.password)) ))
>
> > form.element(_name='password') finds the INPUT(name="password") item
>
> > form.element(_name='password').parent() finds the parent of such
> > element, the TD()
>
> > form.element(_name='password').parent().append(...) appends something
> > to the TD()
>
> > INPUT(_name='password2',) is the appened 
> > field
>
> > This:
> >    requires=IS_EXPR('value=%s' % repr(request.vars.password))
> > sets the requirements. i.e. the value ofpasswordis the same as the
> > value of fields request.vars,password
>
> > On 4 Lug, 09:37, elfuego1  wrote:
>
> > > I'm trying to make a use of this piece of code but nothing works. Can
> > > you please tell me where can I find some fine documentation that shows
> > > exactly how to use it or maybe write me an example because I have no
> > > idea where to put it in my form to make it work.
> > > HELP PLEASE!!
>
> > > form.element(_name=='password').insert(INPUT(_name='password2',requires=IS_EXPR('value=
> > > %s' % repr(request.vars.password)) ))
>
> > > or another example
>
> > > How do I use this piece of code to customize form field length???
> > > form.element(_name='last_name')['_size']=20
>
> > > Can anyone show me how to do that because there is no example in
> > > documentation, no properly written piece of code to meke use of.
>
> > > On 2 Lip, 12:25, elfuego1  wrote:
>
> > > > Thank you for your speedy help!!!
>
> > > > On 2 Lip, 12:13, mdipierro  wrote:
>
> > > > > you can do for example (assuming trunk)
>
> > > > > form.element(_name=='password').insert(INPUT(_name='password2',requires=IS_­EQUAL_TO(request.vars.password)))
>
> > > > > if you do not use trunk instead of IS_EQUAL_TO(request.vars.password)
> > > > > you can use
>
> > > > > IS_EXPR('value=%s' % repr(request.vars.password))
>
> > > > > On 2 Lug, 04:58, elfuego1  wrote:
>
> > > > > > Since I am customizing my registration form, can you tell me what to
> > > > > > do to havepasswordverificationfunctionality? I don’t know how to
> > > > > > implement it in my form. I havepasswordinput field in the form and
> > > > > > corresponding field in my database. Do I have to add additional 
> > > > > > field
> > > > > > for password2 and somehow compare those two fields or is there some
> > > > > > functionality in web2py which I could use out of the box?
>
> > > > > > Best regards.


[web2py] Re: IS_DATETIME validator bug

2010-08-25 Thread KR
maybe Field('When_Actually_Delivered','datetime', requires =
IS_NULL_OR(IS_DATETIME())),

On 25 août, 11:58, Andrew Buchan  wrote:
> Hello,
>
> I'm getting an error report using
>
> Field('When_Actually_Delivered', requires =
> IS_NULL_OR(IS_DATETIME())),
>
> The form is created with SQLFORM, and the input in the textbox was as
> per format quidelines from error message, so seems to be a bug in the
> validator...
>
>  File "C:\Program Files\Hub Pages\web2py\applications\HubForms\modules
> \ComplaintSystem.py", line 100, in ReadOnlyForm
>     form = SQLFORM(table, record= record, fields=fields, readonly =
> True, showid=showid)
>   File "C:\Program Files\Hub Pages\web2py\gluon\sqlhtml.py", line 693,
> in __init__
>     inp = field.formatter(default)
>   File "C:\Program Files\Hub Pages\web2py\gluon\sql.py", line 2766, in
> formatter
>     value = item.formatter(value)
>   File "C:\Program Files\Hub Pages\web2py\gluon\validators.py", line
> 2316, in formatter
>     return self.other.formatter(value)
>   File "C:\Program Files\Hub Pages\web2py\gluon\validators.py", line
> 2076, in formatter
>     year = value.year
> AttributeError: 'str' object has no attribute 'year'


[web2py] Re: The stability of web2py releases

2010-12-22 Thread KR
I support that.
For me the last stable is 1.89.5 (or maybe 1.90.6 ? if the new DAL is
stable)
The only missing stuff is a place to download it.

On 22 déc, 15:49, Branko Vukelić  wrote:
> On Wed, Dec 22, 2010 at 3:44 PM, appydev  wrote:
> > I think there should be a version, not to call it ... ,
> > Something likeUbuntu LTS (Long Term Support). and that
> > this version receiveimmediate bug fixes. and other critical updates that do
> > notprovide new features mean, for a considerable time until thestable
> > version and has been sufficiently tested.
>
> LTS is a completely different ting. It means a lot of backporting of
> stuff that's fixed in later releases, and keeping it supported for 3
> years. I don't think any framework does it. It's sufficient that we
> have a stable and unstable (or edge, or whatever) versions. The latter
> would be a _released_ version, but is not considered thoroughly
> tested. It's like Debian's unstable->testing->stable cycle.
>
> --
> Branko Vukelic
>
> stu...@brankovukelic.comhttp://www.brankovukelic.com/


[web2py] Re: Auto reload of file

2010-12-29 Thread KR
I don't use Eclipse anymore but I can just tell that on my ubuntu box
I never need to restart the server when I edit a file in the
application folder (that is Model, View or Controller) and I tought
that web2py works like that.

If you work in the framework itself, I think that stop and start is a
must.

On Dec 29, 10:27 am, Tomek  wrote:
> Hey
>
> I have simple problem:
>
> I work with eclips and web2py, every time when i done some change i
> need to restart web2py server to see effect of my work, is there any
> workaround for this. ???


[web2py] Re: Python job oportunity

2010-12-30 Thread KR


On Dec 30, 10:34 am, Kenneth Lundström 
wrote:
> Maybe they need perfect English as the don t have it?
>

:-)
... and now we know why they need "creative young developers" ...
;-)


> Kenneth
>
> On Dec 29, 8:29 pm, Bruno Rocha  wrote:
>
> >> for me it worked very well.
> > Same.  One thing that bothers me is that they require perfect English,
> > apparently, but fail several times themselves:
>
> >> 'Internship at i2Mobile, in Oeiras. We want creative young developers for
> > creative, young
>
> >> our very small team. We use Python, Django, Mysql, C#, SQL Server, J2ME,
> >> iOS, Android, HTML, Javascript, jquery.
> > Javascript, and jQquery.
>
> >> Yeah, thats right,
> > that's
>
> >> we really use all
> >> of that.i2
> > (No space between i2 and the period)
>
> >> is a great place to learn. One more thing: your english must be
> > English
>
> >> perfect, spoken and written. If you do not have a twitter or facebook
> >> account, dont bother to answer.
> > They mix "do not" and "don't"; also, they lost the apostrophe in
> > "don't".
>
> >> If you want to apply, call Pedro Carvalho
> >> 912155323. We dont need CVs and
> > This was good.  They avoided the temptation of putting an apostrophe
> > inside "CVs".  (Well done).
>
> > Hint: if you say you want "perfect English", you had better be
> > prepared to have to meet that requirement yourself.
>
>


[web2py] Web2py request different behavior on local and online version (server code executes, but returns 404

2016-08-16 Thread Ur. Kr.


On my local version of the application, making the request with the 
following code, executes the code on the server, returning successfully.

$.ajax({
 type: 'POST',
 url: "{{=URL('default', 'serverFunction.json')}}",
 data: {id: id}}); 

However, if I make the request like so (without '.json' after 
serverFunction)

$.ajax({
 type: 'POST',
 url: "{{=URL('default', 'serverFunction')}}",
 data: {id: id}}); 

The server code executes, but returns a 404 error.

On the online version, it returns a 404 error in both cases, executing the 
server code.


Cross-posting from 
here: 
http://stackoverflow.com/questions/38870171/web2py-request-different-behavior-on-local-and-online-version-server-code-execu

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] How to serve same view for multiple urls

2018-03-15 Thread Ur. Kr.
If you want to convert part of a web2py app into an SPA with client-side 
routing, how do you make web2py serve the same view for multiple urls? 

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: How to serve same view for multiple urls

2018-03-15 Thread Ur. Kr.
Would also need a way to redirect to "index" controller instead of getting 
"invalid controller" when navigating to a URL without a controller. 

On Thursday, March 15, 2018 at 11:28:33 AM UTC+1, Ur. Kr. wrote:
>
> If you want to convert part of a web2py app into an SPA with client-side 
> routing, how do you make web2py serve the same view for multiple urls? 
>

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] Re: How to serve same view for multiple urls

2018-03-15 Thread Ur. Kr.
I'm currently using React/ReactRouter/Redux. The main issue is for web2py 
to serve the same view wherefrom the javascript determines what other 
requests to make and what to render. 
Now if I have 
controller file controllers/default.py 
Then I go to default/page
This doesn't work if there's no `page` function in default.py and if there 
isn't a page.html file the views folder. 
For the SPA I need it to just serve a single HTML file regardless of the 
url components after "default/".
I suppose I could use the # fragment: default#/page

On Thursday, March 15, 2018 at 12:32:40 PM UTC+1, Massimiliano wrote:
>
> If I understand correctly what you mean, you need an entrypoint that could 
> be index in your controller that load the view.
> Now from the view you get and set data via ajax from/to other controller 
> functions.
>
> SPA are heavly javascript based.
>
> Take a look on discussions on Vue.js
>
> On Thu, Mar 15, 2018 at 11:53 AM, Ur. Kr.  > wrote:
>
>> Would also need a way to redirect to "index" controller instead of 
>> getting "invalid controller" when navigating to a URL without a controller. 
>>
>>
>> On Thursday, March 15, 2018 at 11:28:33 AM UTC+1, Ur. Kr. wrote:
>>>
>>> If you want to convert part of a web2py app into an SPA with client-side 
>>> routing, how do you make web2py serve the same view for multiple urls? 
>>>
>> -- 
>> 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 subscribed to the Google Groups 
>> "web2py-users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to web2py+un...@googlegroups.com .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> -- 
> Massimiliano
>

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Is it possible to trigger some action on error?

2018-06-03 Thread Ur. Kr.
Is it possible to trigger some action when an error occurs? When an error 
file is added to the errors folder. 

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: Is it possible to trigger some action on error?

2018-06-03 Thread Ur. Kr.
This doesn't works for errors that don't redirect there, right? So if I 
make an AJAX request that causes an error on the server, it wouldn't 
trigger the error handling function? 

On Sunday, June 3, 2018 at 4:24:01 PM UTC+2, Anthony wrote:
>
> One option is to create a custom error handler (see 
> http://web2py.com/books/default/chapter/29/04/the-core#Routes-on-error) 
> and have it take whatever action is desired before returning a response.
>
> Anthony
>
> On Sunday, June 3, 2018 at 9:15:04 AM UTC-4, Ur. Kr. wrote:
>>
>> Is it possible to trigger some action when an error occurs? When an error 
>> file is added to the errors folder. 
>>
>

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: How to force an update to the scheduler schema

2018-07-25 Thread Ur. Kr.
scheduler = Scheduler(db, migrate=True)
Doesn't recreate tables for me when I rerun the scheduler. 

On Tuesday, May 23, 2017 at 8:03:13 PM UTC+2, Dave S wrote:
>
>
>
> On Tuesday, May 23, 2017 at 5:30:08 AM UTC-7, Brad Miller wrote:
>>
>> Due to a forced migration to new hardware/os on webfaction,  I just 
>> recently had to upgrade from 2.5.1 to 2.14.6.
>>
>> In the process I have managed to get myself into a state where the 
>> scheduler schema is wrong.  (I'm using postgresql)
>>
>> I get the following error:
>>
>> ProgrammingError: ('ERROR', '42703', 'column "prevent_drift" of relation 
>> "scheduler_task" does not exist')
>>
>>
>> This is probably my fault as in my haste to get everything up and live 
>> again I did a fake_migrate_all=True (the app was crashing because it said 
>> the session table already existed.)
>>
>>
>> I have all my application tables prefixed with my app name for migration 
>> purposes:
>>
>> runestone_my_table.table. for example.  however the scheduler and the 
>> session tables are still getting the default:
>>
>> 033e652b5c024094757cfc1050e7ecda_scheduler_run.table
>> 033e652b5c024094757cfc1050e7ecda_scheduler_task.table
>> 033e652b5c024094757cfc1050e7ecda_scheduler_worker.table
>> 409096731cda32e62dcf6bbed574f3d5_web2py_session_runestone.table
>>
>> Everything except my scheduler processes is back on line.  Is there any 
>> way to make the scheduler update its schema given the state I am in??
>>
>> Thanks
>>
>> Brad
>>
>
>
> I think you want to set "migrate" (not "fake_migrate" this time) to true, 
> do one access to any function in your app, and then turn "migrate" off 
> again.
>
> Setting the "fake_migrate" updated your table files (the web2py side of 
> the pipe), but now you need to update the actual DB tables.
>
> If you've got the appconfig.ini set up (as part of your upgrade), then 
> that's easy to do, but it's not much harder if you have to set it in your 
> model.
>
>
> /dps
>
>
> /dps
>
>

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Scheduler migrate=True doesn't recreate tables

2018-07-25 Thread Ur. Kr.

scheduler = Scheduler(db, migrate=True)
This doesn't recreate tables for me when I rerun the scheduler and the 
application. 

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: Scheduler migrate=True doesn't recreate tables

2018-07-25 Thread Ur. Kr.
I have dropped the tables relating to the scheduler from the old database 
because I moved to a newer version of web2py. I want the scheduler to 
create the new tables it needs. 

On Wednesday, July 25, 2018 at 8:29:05 PM UTC+2, Anthony wrote:
>
> On Wednesday, July 25, 2018 at 1:33:24 PM UTC-4, Ur. Kr. wrote:
>>
>>
>> scheduler = Scheduler(db, migrate=True)
>> This doesn't recreate tables for me when I rerun the scheduler and the 
>> application. 
>>
>
> Have the tables already been created once? If so, they will not be 
> re-created. What are you trying to do? 
>

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: Scheduler migrate=True doesn't recreate tables

2018-07-25 Thread Ur. Kr.
Web2py\gluon\scheduler.py
The commit under the if around line 878 does run.

On Wednesday, July 25, 2018 at 9:19:33 PM UTC+2, Ur. Kr. wrote:
>
> I have dropped the tables relating to the scheduler from the old database 
> because I moved to a newer version of web2py. I want the scheduler to 
> create the new tables it needs. 
>
> On Wednesday, July 25, 2018 at 8:29:05 PM UTC+2, Anthony wrote:
>>
>> On Wednesday, July 25, 2018 at 1:33:24 PM UTC-4, Ur. Kr. wrote:
>>>
>>>
>>> scheduler = Scheduler(db, migrate=True)
>>> This doesn't recreate tables for me when I rerun the scheduler and the 
>>> application. 
>>>
>>
>> Have the tables already been created once? If so, they will not be 
>> re-created. What are you trying to do? 
>>
>

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] pg8000.errors.ProgrammingError 'no result set' when querying database from module

2019-01-01 Thread Ur. Kr.
Web2py version: Version 2.8.2-stable+timestamp.2013.11.28.07.51.37

in a module, I'm setting up a db object like so:

from gluon import current

db = current.globalenv['db']

But when I try whatever query the database inside that module, I get an 
error:
gluon.contrib.pg8000.errors.ProgrammingError('no result set')

Any idea why this would be? Do I need to provide additional details? 

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Cross-domain authentication for REST api

2017-03-28 Thread Ur. Kr.
We need to make a REST api service for our website that will be accessed 
from arbitrary domains by partner companies, but we're having trouble with 
authentication.

We tried auth.is_logged_in(), but the problem is that login doesn't seem to 
work cross domain. A session is created on the server, but the request 
still doesn't get passed authentication. 

Is there anything built-in in web2py for this use case?

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] How to connect MYSQL database in web2py

2018-01-31 Thread vinu KR
Dear all,

Am new to web2py, I need how to connect the MYSQL database in web2py. 
Kindly help us

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Migration not creating new fields/tables after restore from an old backup the database

2019-07-31 Thread Ur. Kr.
This are my migration settings:
DAL(settings.database_uri, migrate=True, fake_migrate_all=True)

When I add new tables of fields on the development version of the app they 
are added properly. However, if I create a backup of the production 
database (missing the newly added fields/tables) and I use that backup to 
restore the development database the new fields are missing and they are 
not created after refreshing the page with the above migration settings. 

Any fields/tables added AFTER the restore DO get added! The only ones that 
don't are those that were added pre-restore and were lost on restore. 

Deleting the files in the databases folder doesn't help either. 

-- 
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 subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/7c6ee234-810a-403b-80bf-ecb2bda2736f%40googlegroups.com.