[web2py] Brainstorming

2014-06-15 Thread Massimo Di Pierro
Often Angular comes up on this list. I tried it and I was un-impressed. 
Instead today my favorite client-side stack is based on these:

- jquery.js
- sugar.js
- ractive.js
- semantic-ui (css & js)

Have you tried sugar, ractive, and semantic-ui? What is your opinion?

Massimo




-- 
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] Bug with upload widget when using digitally signed URL's?

2014-06-15 Thread Michael Beller
I'm trying to secure file downloads.  I use user_signature=True for an 
action that generates an edit form that includes an upload field.  The 
upload widget generates a download link but the link appends the file name 
arg after the signature var.

I'm using:
crud.settings.download_url = URL('dcoument', 'download', 
args=document.customer, user_signature=True)

I'm then using:
form = crud.update(...)

This creates a download link like
/document/download/51?_signature=/
instead of
/document/download/51/?_signature=

On a related topic, I'm using that extra arg above to create separate 
folders for each customer (useful for multi tenant) but this breaks 
appadmin uploads and download links.  It would be great to use a lambda for 
the upload folder, something like ...

db.define_table('document',
Field('customer', 'reference customer'),
Field('document', 'upload', autodelete=True, 
uploadfolder=lambda r: (request.folder + 'document/download/' + 
row.customer)),
)

-- 
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: Brainstorming

2014-06-15 Thread Niphlod
I was sincerely impressed with how many things you can do with Angular, but 
the learning curve is too steep.
Then I tried knockout...much better in terms of learning curve, and its 
methods to map json objects (resultsets) with view-models couples nicely 
with web2py.but the templating lacks too much and is a tad bit verbose.
Then I tried ractive, and I had a serious headache to figure out how to do 
"basic tasks" : to be fair, I asked a question on their google-group and 
got an answer pretty soon: unfortunately the solution was there but the 
docs weren't updated yet (that's why I had a hard time with it). 
It seems that the ractive "concept" is closer to my mindset, i.e. it's the 
tool I'd use to solve "problems" I can't solve with web2py alone, so it 
"adds" a good value given the effort spent.
That being said, there's a whole new concept to adapt to with all of them: 
your project starts to be python + html and then is python+html+js, with 
matters like "how do I organize js code within my app", "let's use 
requirejs" and so on...it's not that easy to adapt if you're coming from 
python web frameworks.

On Sunday, June 15, 2014 10:34:25 AM UTC+2, Massimo Di Pierro wrote:
>
> Often Angular comes up on this list. I tried it and I was un-impressed. 
> Instead today my favorite client-side stack is based on these:
>
> - jquery.js
> - sugar.js
> - ractive.js
> - semantic-ui (css & js)
>
> Have you tried sugar, ractive, and semantic-ui? What is your opinion?
>
> Massimo
>
>
>
>
>

-- 
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] validator - asking it to do some more

2014-06-15 Thread 98ujko9
# table definition
db.define_table('vehicle',
Field('manufacturer','string'),
Field('name','string'),
Field('vin','string',length=32,unique=True),
Field('year','string'),
Field('colour','string'),
Field('comment','string'),
Field('date','date',default=now),
migrate='vehicle.table',format='%(manufacturer)s %(name)s 
%(year)s %(vin)s'
)

# present validator
db.vehicle.vin.requires=[IS_UPPER(), 
IS_NOT_IN_DB(db(db.vehicle.vin==request.vars.vin),db.vehicle.vin)]

# I have js function: validate_vin(VIN_NUMBER) that returns True or False

# If I had a form variable "vinOK" I could assign test result to it: 
jQuery("#vinOK").val(validate_vin(jQuery("#vehicle_vin").val()))

# then use the enhanced validator
# this is only hypothetical because the form has no variable "vinOK" but it 
would be desirable because I could use the functionality of the validator 
to show error in the form

db.vehicle.vin.requires=[IS_EXPR(('"True" == "%s"' % 
str(request.vars.vinOK)),error_message="VIN not good"),IS_UPPER(), 
IS_NOT_IN_DB(db(db.vehicle.vin==request.vars.vin),db.vehicle.vin)]

# A hidden field would be a solution to store the result of the js function 
but hidden fields don't seem to work in web2py for security reasons.( That 
is my understanding)
# Any solution would be OK as long as I can use validator's functionality 
to show error message. Perhaps I do not need the hidden variable at all. 
How do I pass VIN test result to the validator? Thanks a lot in advance.

-- 
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: Brainstorming

2014-06-15 Thread Anthony
Have you tried React.js (from Facebook). I haven't tried it but have read 
good things. Supposedly somewhat similar to Ractive. Also seems to be more 
active (Ractive has had no commits for a month and seems to have limited 
user group activity).

Anthony

On Sunday, June 15, 2014 9:39:21 AM UTC-4, Niphlod wrote:
>
> I was sincerely impressed with how many things you can do with Angular, 
> but the learning curve is too steep.
> Then I tried knockout...much better in terms of learning curve, and its 
> methods to map json objects (resultsets) with view-models couples nicely 
> with web2py.but the templating lacks too much and is a tad bit verbose.
> Then I tried ractive, and I had a serious headache to figure out how to do 
> "basic tasks" : to be fair, I asked a question on their google-group and 
> got an answer pretty soon: unfortunately the solution was there but the 
> docs weren't updated yet (that's why I had a hard time with it). 
> It seems that the ractive "concept" is closer to my mindset, i.e. it's the 
> tool I'd use to solve "problems" I can't solve with web2py alone, so it 
> "adds" a good value given the effort spent.
> That being said, there's a whole new concept to adapt to with all of them: 
> your project starts to be python + html and then is python+html+js, with 
> matters like "how do I organize js code within my app", "let's use 
> requirejs" and so on...it's not that easy to adapt if you're coming from 
> python web frameworks.
>
> On Sunday, June 15, 2014 10:34:25 AM UTC+2, Massimo Di Pierro wrote:
>>
>> Often Angular comes up on this list. I tried it and I was un-impressed. 
>> Instead today my favorite client-side stack is based on these:
>>
>> - jquery.js
>> - sugar.js
>> - ractive.js
>> - semantic-ui (css & js)
>>
>> Have you tried sugar, ractive, and semantic-ui? What is your opinion?
>>
>> Massimo
>>
>>
>>
>>
>>

-- 
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: Brainstorming

2014-06-15 Thread António Ramos
If you check the popularity of angular ractive react etc at github you have
a winner:
ANGULAR!!
Big community, videos ,books etc
And
JOBS!!
 Em 15/06/2014 17:19, "Anthony"  escreveu:

> Have you tried React.js (from Facebook). I haven't tried it but have read
> good things. Supposedly somewhat similar to Ractive. Also seems to be more
> active (Ractive has had no commits for a month and seems to have limited
> user group activity).
>
> Anthony
>
> On Sunday, June 15, 2014 9:39:21 AM UTC-4, Niphlod wrote:
>>
>> I was sincerely impressed with how many things you can do with Angular,
>> but the learning curve is too steep.
>> Then I tried knockout...much better in terms of learning curve, and its
>> methods to map json objects (resultsets) with view-models couples nicely
>> with web2py.but the templating lacks too much and is a tad bit verbose.
>> Then I tried ractive, and I had a serious headache to figure out how to
>> do "basic tasks" : to be fair, I asked a question on their google-group and
>> got an answer pretty soon: unfortunately the solution was there but the
>> docs weren't updated yet (that's why I had a hard time with it).
>> It seems that the ractive "concept" is closer to my mindset, i.e. it's
>> the tool I'd use to solve "problems" I can't solve with web2py alone, so it
>> "adds" a good value given the effort spent.
>> That being said, there's a whole new concept to adapt to with all of
>> them: your project starts to be python + html and then is python+html+js,
>> with matters like "how do I organize js code within my app", "let's use
>> requirejs" and so on...it's not that easy to adapt if you're coming from
>> python web frameworks.
>>
>> On Sunday, June 15, 2014 10:34:25 AM UTC+2, Massimo Di Pierro wrote:
>>>
>>> Often Angular comes up on this list. I tried it and I was un-impressed.
>>> Instead today my favorite client-side stack is based on these:
>>>
>>> - jquery.js
>>> - sugar.js
>>> - ractive.js
>>> - semantic-ui (css & js)
>>>
>>> Have you tried sugar, ractive, and semantic-ui? What is your opinion?
>>>
>>> Massimo
>>>
>>>
>>>
>>>
>>>  --
> 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.
>

-- 
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] RapydScript / RapydML - impressive

2014-06-15 Thread António Ramos
I was hoping this would be a hot topic  but...
Em 09/06/2014 15:32, "António Ramos"  escreveu:

> interesting read from RapydML.
>
>
> {% extends basic.html %}
>
> For those unfamiliar with it, the above line includes HTML from basic.html
> inside of the current page. This is a useful technique to avoid unnecessary
> copies of HTML that's common to multiple pages (this includes navigation
> menus, website logo, etc.). The above logic, however, can also be
> substituted with RapydML's importstatement, importing RapydML logic from
> another page. For example, I can create a template.pyml file, declararing a
> function for generating a chunk of reusable HTML inside of it, and then
> invoke that function in every place I want that HTML to appear. Which
> solution is better?
>
> If you're an experienced web developer, you probably know that on most
> hosting services storage space (especially for text/html) is relatively
> cheap compared to bandwidth and CPU usage. The bandwidth requirements in
> this case are the same, since both, template engine and RapydML logic
> happens before the page is served to the client. The main difference is
> that by using extends, you force your template engine to dynamically
> generate that HTML content before serving it to the client (using up CPU
> cycles, smart engines will probably cache this data), while by using
> import you make your compiler generate that HTML once and serve it
> repeatedly to your clients (using up a bit more storage space, which is not
> even significant when comparing it to storage taken up by images and other
> multimedia files). As a rule of thumb, I recommend using RapydML's logic
> over Django/Rails/web2py unless it's something that requires information
> that will not be available until runtime (i.e. news that you retrieve from
> the database, interactive form that deals with user input). It's not too
> different from preferring CSS over JavaScript for styling that doesn't
> change dynamically.
>
>
> 2014-06-09 14:51 GMT+01:00 António Ramos :
>
>> I think i need something like that.
>>
>> cleaner is simple to read ..
>>
>>
>> 2014-06-09 3:35 GMT+01:00 nick name :
>>
>> Does anyone have experience with RapydScript (lightweight py-like to JS
>>> translator) and RapydML (pythonic-template to html/xml/svg translator)?
>>>
>>> Have just discovered them, and from a cursory examination they seem
>>> extremely nice and useful. RapydScript seems to bridge the JS<->Python
>>> bridge better than other projects I've looked at (PythonJS, Skulpt,
>>> Pyjamas, Brython) - it goes much farther than Brython, for example, but
>>> produces very readable and debuggable javascript that still works on IE8.
>>>
>>> RapydML explicitly shows how to support web2py in its documents ( ... as
>>> well as plain html and django).
>>>
>>> Does anyone have any experience with them?
>>>
>>> https://github.com/atsepkov/RapydML
>>>
>>> https://github.com/atsepkov/RapydScript
>>>
>>>  --
>>> 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.
>>>
>>
>>
>

-- 
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: Brainstorming

2014-06-15 Thread Michele Comitini
ractive.js author's ideas about the philosophy of the framework and more,
are nicely writte in a blog.
Many interesting points that were brought up here are discussed in depth
there.

http://blog.ractivejs.org/


mic


2014-06-15 18:19 GMT+02:00 Anthony :

> Have you tried React.js (from Facebook). I haven't tried it but have read
> good things. Supposedly somewhat similar to Ractive. Also seems to be more
> active (Ractive has had no commits for a month and seems to have limited
> user group activity).
>
> Anthony
>
>
> On Sunday, June 15, 2014 9:39:21 AM UTC-4, Niphlod wrote:
>>
>> I was sincerely impressed with how many things you can do with Angular,
>> but the learning curve is too steep.
>> Then I tried knockout...much better in terms of learning curve, and its
>> methods to map json objects (resultsets) with view-models couples nicely
>> with web2py.but the templating lacks too much and is a tad bit verbose.
>> Then I tried ractive, and I had a serious headache to figure out how to
>> do "basic tasks" : to be fair, I asked a question on their google-group and
>> got an answer pretty soon: unfortunately the solution was there but the
>> docs weren't updated yet (that's why I had a hard time with it).
>> It seems that the ractive "concept" is closer to my mindset, i.e. it's
>> the tool I'd use to solve "problems" I can't solve with web2py alone, so it
>> "adds" a good value given the effort spent.
>> That being said, there's a whole new concept to adapt to with all of
>> them: your project starts to be python + html and then is python+html+js,
>> with matters like "how do I organize js code within my app", "let's use
>> requirejs" and so on...it's not that easy to adapt if you're coming from
>> python web frameworks.
>>
>> On Sunday, June 15, 2014 10:34:25 AM UTC+2, Massimo Di Pierro wrote:
>>>
>>> Often Angular comes up on this list. I tried it and I was un-impressed.
>>> Instead today my favorite client-side stack is based on these:
>>>
>>> - jquery.js
>>> - sugar.js
>>> - ractive.js
>>> - semantic-ui (css & js)
>>>
>>> Have you tried sugar, ractive, and semantic-ui? What is your opinion?
>>>
>>> Massimo
>>>
>>>
>>>
>>>
>>>  --
> 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.
>

-- 
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] websocket_messaging and security

2014-06-15 Thread Khalil KHAMLICHI
Hi Everyone,

We used websocket_messaging.py in our application extensively.

We did not modify any of its code, we used it as it is out of the box.

Before deployments on a cloud server, has anyone any suggestions about
securing this websocket server ? for example :

- allow connections only to logged-in users ?
- ignore connection requests from non logged-in users so to not waste
ressources.

any experience on this matter is welcome.

Thanks in advance.

Khalil

-- 
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: Brainstorming

2014-06-15 Thread samuel bonill
Angular is very easy to learn...

#1 http://campus.codeschool.com/courses/shaping-up-with-angular-js/intro

#2 www.*ng*-*book*.com

El domingo, 15 de junio de 2014 03:34:25 UTC-5, Massimo Di Pierro escribió:
>
> Often Angular comes up on this list. I tried it and I was un-impressed. 
> Instead today my favorite client-side stack is based on these:
>
> - jquery.js
> - sugar.js
> - ractive.js
> - semantic-ui (css & js)
>
> Have you tried sugar, ractive, and semantic-ui? What is your opinion?
>
> Massimo
>
>
>
>
>

-- 
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: one more web2py e-commerce app :)

2014-06-15 Thread Sarbjit
Hi Adi,

I visited the nammuhats.com, its a fantastic site. I just want to know 
whether you are using woocommerce plugin (wordpress plugin) in this site or 
using woocommerce template in it?

Can you give some pointers on how to adapt woocommerce plugin to web2py app.

Thanks
Sarbjit

On Thursday, October 10, 2013 4:40:32 AM UTC+5:30, Adi wrote:
>
>
> :) 
>
> There are only few hats left in this color, so they are just on small 
> special now, but we also send absolutely free hat to anyone who's going 
> through chemotherapy  
> treatment. 
>
>
> On Wed, Oct 9, 2013 at 6:26 PM, Derek > 
> wrote:
>
>> Why is a light purple hat $2 less than a white one?
>>
>>   

-- 
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] RapydScript / RapydML - impressive

2014-06-15 Thread Massimo Di Pierro
actually I did not know about this and this is really interesting.
The problem I had with coffeescript was it was hard to debug because errors 
would reference the generate JS and not the source. How does radyscript 
handle tracebacks? 

On Sunday, 15 June 2014 13:24:28 UTC-5, Ramos wrote:
>
> I was hoping this would be a hot topic  but...
> Em 09/06/2014 15:32, "António Ramos"  escreveu:
>
>> interesting read from RapydML. 
>>
>>
>> {% extends basic.html %}
>>
>> For those unfamiliar with it, the above line includes HTML from 
>> basic.html inside of the current page. This is a useful technique to avoid 
>> unnecessary copies of HTML that's common to multiple pages (this includes 
>> navigation menus, website logo, etc.). The above logic, however, can also 
>> be substituted with RapydML's importstatement, importing RapydML logic 
>> from another page. For example, I can create a template.pyml file, 
>> declararing a function for generating a chunk of reusable HTML inside of 
>> it, and then invoke that function in every place I want that HTML to 
>> appear. Which solution is better?
>>
>> If you're an experienced web developer, you probably know that on most 
>> hosting services storage space (especially for text/html) is relatively 
>> cheap compared to bandwidth and CPU usage. The bandwidth requirements in 
>> this case are the same, since both, template engine and RapydML logic 
>> happens before the page is served to the client. The main difference is 
>> that by using extends, you force your template engine to dynamically 
>> generate that HTML content before serving it to the client (using up CPU 
>> cycles, smart engines will probably cache this data), while by using 
>> import you make your compiler generate that HTML once and serve it 
>> repeatedly to your clients (using up a bit more storage space, which is not 
>> even significant when comparing it to storage taken up by images and other 
>> multimedia files). As a rule of thumb, I recommend using RapydML's logic 
>> over Django/Rails/web2py unless it's something that requires information 
>> that will not be available until runtime (i.e. news that you retrieve from 
>> the database, interactive form that deals with user input). It's not too 
>> different from preferring CSS over JavaScript for styling that doesn't 
>> change dynamically.
>>
>>
>> 2014-06-09 14:51 GMT+01:00 António Ramos :
>>
>>> I think i need something like that.
>>>
>>> cleaner is simple to read ..
>>>
>>>
>>> 2014-06-09 3:35 GMT+01:00 nick name :
>>>
>>> Does anyone have experience with RapydScript (lightweight py-like to JS 
 translator) and RapydML (pythonic-template to html/xml/svg translator)?

 Have just discovered them, and from a cursory examination they seem 
 extremely nice and useful. RapydScript seems to bridge the JS<->Python 
 bridge better than other projects I've looked at (PythonJS, Skulpt, 
 Pyjamas, Brython) - it goes much farther than Brython, for example, but 
 produces very readable and debuggable javascript that still works on IE8.

 RapydML explicitly shows how to support web2py in its documents ( ... 
 as well as plain html and django).

 Does anyone have any experience with them?

 https://github.com/atsepkov/RapydML

 https://github.com/atsepkov/RapydScript

  -- 
 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.

>>>
>>>
>> 

-- 
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 there an issue with my web2py install? "can't pickle function objects"

2014-06-15 Thread Nguyen Minh Tuan
I am having this issue too!

Server : CentOS 6.5
Apache : 2.2
Python : 2.6.6
Web2py : 2.95

So, I think this error caused by Apache config.
Look into error log file, I found msg like : "...*client denied by server 
configuration*: /var/www/web2py/wsgihandler.py ..."

I've changed in httpd.conf file :


AllowOverride None  
Order Allow,Deny
Deny from all

Allow from all



to :

AllowOverride AuthConfig FileInfo
Order Allow,Deny
Deny from all

Allow from all


...
and this error do not happen any more.
I don't fully understand about Apache config, but hope this may help.
Can anyone tell me there are risks if I set Apache config file like this?

Regards,
Tuan.

On Thursday, April 3, 2014 12:14:14 AM UTC+7, Carlos Alba wrote:
>
> Is this still a issue? I am receiving this error.
>
> On Tuesday, July 16, 2013 9:44:46 PM UTC-5, Joe Magaro wrote:
>>
>> Hi, Lately when I'm in the admin section, when I perform an action such 
>> as installing a new app, or deleting a view I keep getting the error below. 
>> Im not sure what changed to affect this, please help!
>>
>> raceback (most recent call last):
>>   File "/home/www-data/web2py/gluon/main.py", line 606, in wsgibase
>> session._try_store_in_cookie_or_file(request, response)
>>   File "/home/www-data/web2py/gluon/globals.py", line 757, in 
>> _try_store_in_cookie_or_file
>> self._try_store_in_file(request, response)
>>   File "/home/www-data/web2py/gluon/globals.py", line 763, in 
>> _try_store_in_file
>> if not response.session_id or self._forget or self._unchanged():
>>   File "/home/www-data/web2py/gluon/globals.py", line 719, in _unchanged
>> session_pickled = cPickle.dumps(dict(self))
>>   File "/usr/lib/python2.7/copy_reg.py", line 70, in _reduce_ex
>> raise TypeError, "can't pickle %s objects" % base.__name__
>> TypeError: can't pickle function objects
>>
>> Error snapshot [image: help] 
>> 
>>
>> (can't pickle function objects)
>>
>

-- 
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: Brainstorming

2014-06-15 Thread Massimo Di Pierro
I have used Angular for a project and it was a nightmare. I soon moved to 
ractive and did not regret it. Angular forces a scope and, for example, 
promises can only live within the scope. That means you cannot use Angular 
promises in your own library unless you put all the code in the scope. I 
constantly found myself fighting the constraints imposed by angular. 

On Sunday, 15 June 2014 19:59:43 UTC-5, samuel bonill wrote:
>
> Angular is very easy to learn...
>
> #1 http://campus.codeschool.com/courses/shaping-up-with-angular-js/intro
>
> #2 www.*ng*-*book*.com
>
> El domingo, 15 de junio de 2014 03:34:25 UTC-5, Massimo Di Pierro escribió:
>>
>> Often Angular comes up on this list. I tried it and I was un-impressed. 
>> Instead today my favorite client-side stack is based on these:
>>
>> - jquery.js
>> - sugar.js
>> - ractive.js
>> - semantic-ui (css & js)
>>
>> Have you tried sugar, ractive, and semantic-ui? What is your opinion?
>>
>> Massimo
>>
>>
>>
>>
>>

-- 
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: force mobilize

2014-06-15 Thread HarryE
Put request.user_agent().is_mobile=True in db.py


marți, 21 februarie 2012, 13:12:20 UTC, Scott Benninghoff a scris:
>
> I was wondering if there is a way to set a global variable that would 
> force a site to present in mobile mode.  Thanks for the help.

-- 
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.