[web2py] Webfaction Deployment and Tuning Web2py Slice.

2012-11-06 Thread Mark Graves
to the framework. If you are willing to lend your expertise please let me know, so we can make this community better for everyone. Sincerely, Mark Graves GravesMedical Founder --

[web2py] Seeking Skilled Web2py Developer with UX experience

2013-09-27 Thread Mark Graves
Hey guys, I've been developing an application myself over the past 3 years. I've finally got a solid version 1.0. I'm refining it, deploying it, and looking for a skilled web2py/UX developer's help. I've got a CTO ready to come on board. We are pitching VC next month, and I'll be pitching a

[web2py] response.view best practices

2013-11-18 Thread Mark Graves
Hey guys, Two questions: So I've got a public facing site and a private site, which have different layouts. In the past, I used one layout.html and blocks of if statements to include stuff. In terms of performance what would be the difference between that and response.view? Also, I was havi

[web2py] web2py deployment: LetsEncrypt Nginx auto renew deployment script

2016-05-25 Thread Mark Graves
Has anyone used LetsEncrypt certificates or followed the instructions below with web2py? https://www.digitalocean.com/community/tutorials/how-to-secure-nginx-with-let-s-encrypt-on-ubuntu-14-04 https://www.nginx.com/blog/free-certificates-lets-encrypt-and-nginx/ What are your thoughts of the sta

Re: [web2py] Re: web2py deployment: LetsEncrypt Nginx auto renew deployment script

2016-05-27 Thread Mark Graves
cert for a production site > rather than using letsentcypt. > > > On Thursday, May 26, 2016 at 12:11:29 AM UTC+2, Mark Graves wrote: >> >> Has anyone used LetsEncrypt certificates or followed the instructions >> below with web2py? >> >> >> https://www.digita

[web2py] Re: Append fields within form, iteratively add fields inside form, List:string append, custom forms

2016-06-02 Thread Mark Graves
Hey Ron, This looks like an architectural issue to me. You have to maintain state somehow for the form2 vars. You can either do this via javascript on the client side, then have only one form server side, which has a dynamic set of fields. If i were to do it this way, I would use a javascript

Re: [web2py] Re: web2py deployment: LetsEncrypt Nginx auto renew deployment script

2016-06-03 Thread Mark Graves
: > On Friday, May 27, 2016 at 5:39:04 AM UTC-4, Mark Graves wrote: >> >> Thank Niphlod and Anthony. >> >> I agree. The technology is not quite mainstream enough to really rely on >> yet. >> > > About a month ago, it was already the third largest cert

[web2py] Re: Weird form issue

2016-06-05 Thread Mark Graves
Hey Jeff, It looks like you created a sqlform expecting all fields, then the form was expecting all fields back, but you only used some of them in the view, so they were not processed. Specifically, the status field. You could either set the type of the field to hidden and include it or only

Re: [web2py] Re: Weird form issue

2016-06-05 Thread Mark Graves
gt; > On Sunday, June 5, 2016 at 6:14:35 PM UTC-5, Mark Graves wrote: > >> Hey Jeff, >> >> It looks like you created a sqlform expecting all fields, then the form >> was expecting all fields back, but you only used some of them in the view, >> so they were not p

[web2py] Re: Weird form issue

2016-06-06 Thread Mark Graves
Hey Jeff, Most likely the date/time format. If you can post a sample sqlite file and SQLGRID code, happy to help. -Mark On Monday, June 6, 2016 at 12:42:16 PM UTC-7, Jeff Riley wrote: > > Sorry quick update. Rows is returning information, so I must have a > problem with my javascript. I st

[web2py] migrate uwsgi + nginx --> twisted

2016-06-08 Thread Mark Graves
Hey everyone, I am migrating an app from uwsgi + nginx to twisted. I've read the docs and can get it started on my local machine. Now, I'm putting it on a separate box. Does anyone have a service startup script that they would mind sharing? Otherwise, any recommendations for further reading?

[web2py] Redis Session Auth Issue

2016-08-10 Thread Mark Graves
Hey everyone, Having trouble tracking down a bug, looking for a sanity check. Somehow, when I turn on redis sessions, auth is not getting updated from the session. This behavior manifests itself as a 303 with functions that are decorated with @auth.requires. Basic Workflow: Ajax re

[web2py] Re: Redis Session Auth Issue

2016-08-10 Thread Mark Graves
I'm an idiot. Put session below auth. Ignore. On Wednesday, August 10, 2016 at 8:13:55 PM UTC-5, Mark Graves wrote: > > Hey everyone, > > Having trouble tracking down a bug, looking for a sanity check. > > Somehow, when I turn on redis sessions, auth is not getting upda

[web2py] web2py react-python

2016-11-20 Thread Mark Graves
Hey everyone, I recently stumbled across this: https://github.com/markfinger/python-react/issues/70#issuecomment-254396083 Just thought I'd share for anyone who was looking for something similar -Mark -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.c

Re: [web2py] web2py react-python

2016-11-20 Thread Mark Graves
ell me one use case or explain when could this pyhon-react > setup make sense? > > Thanks > José L. > > 2016-11-20 10:25 GMT+01:00 Mark Graves : > >> Hey everyone, >> >> I recently stumbled across this: >> >> https://github.com/markfinger/python-react/

[web2py] Re: 50x performance improvement for web2py in TechEmpower Web Framework Benchmarks

2016-11-20 Thread Mark Graves
This is great news! Thank you for working on this, all of you. Any ability to check out the errors? Would love to know what that was. On Saturday, November 19, 2016 at 2:16:18 PM UTC-6, Massimo Di Pierro wrote: > > Fantastic! Thank you Anthony, Michele, Simone, Richard, Paolo, Giovanni > and ev

Re: [web2py] Re: web2py react-python

2016-11-21 Thread Mark Graves
Way better use case Leonel, thanks =) On Mon, Nov 21, 2016 at 3:44 AM, Leonel Câmara wrote: > José a use case may be for graceful degradation when clients don't have > javascript. > > -- > Resources: > - http://web2py.com > - http://web2py.com/book (Documentation) > - http://github.com/web2py/we

Re: [web2py] Re: web2py react-python

2016-11-21 Thread Mark Graves
One other thing that popped into my head after reading Anthony's points about search engine indexing would be permanent URI views (theoretically), whereas with pure JS apps often my experience has been less than thrilling with the routing capacities. On Mon, Nov 21, 2016 at 3:41 PM, Anthony wrote

Re: [web2py] Re: 50x performance improvement for web2py in TechEmpower Web Framework Benchmarks

2016-11-22 Thread Mark Graves
2016 at 3:36 PM, Anthony wrote: > On Monday, November 21, 2016 at 2:39:21 AM UTC-5, Mark Graves wrote: >> >> This is great news! Thank you for working on this, all of you. >> >> Any ability to check out the errors? >> > > Not that I know of. Note, the errors occ

Re: [web2py] Re: 50x performance improvement for web2py in TechEmpower Web Framework Benchmarks

2016-11-22 Thread Mark Graves
That is truly strange. Seems to be a distinct confound. Greatly appreciated work. On Tue, Nov 22, 2016 at 7:27 AM, Anthony wrote: > On Tuesday, November 22, 2016 at 8:16:16 AM UTC-5, Mark Graves wrote: >> >> If I'm reading that correctly, doesn't that show web2py

[web2py] Re: Deploy with postgresql

2016-12-27 Thread Mark Graves
Hopefully this is solved, but a simple test is to use the original appconfig.ini with storage.sqlite as the connection string. That will tell you if it is a syntax problem, at least. -Mark On Monday, December 26, 2016 at 7:08:23 PM UTC-6, Ben Lawrence wrote: > > seems to be an appconfig probl

[web2py] Re: homebrew python not working with web2py

2016-12-30 Thread Mark Graves
How did you install web2py? as a zip? via git? Did you ever pip install gluon? Did you install web2py / python at different times? Can you try under each python version to do: import gluon.widget On Thursday, December 29, 2016 at 11:29:08 PM UTC-6, lyn2py wrote: > > I am not sure if this is

[web2py] Re: auth groups and permission

2016-12-30 Thread Mark Graves
Depends on workflow, but Stefan was similar to what I was thinking. probably: auth.settings.create_user_groups = None Then after form submission, depending on workflow, algorithmically add the person to the group...eg. if form.vars.is_editor == True: db.auth_membership.insert(YOUR_DATA_HE

[web2py] Re: Updating log on mobile device

2016-12-30 Thread Mark Graves
Or you could always use a websocket but that might be overkill On Thursday, December 29, 2016 at 1:48:06 PM UTC-6, Dave S wrote: > > > > On Thursday, December 29, 2016 at 6:25:09 AM UTC-8, Leonel Câmara wrote: >> >> I'm guessing the log entries have a created_on Field, you can >> periodically que

Re: [web2py] Re: homebrew python not working with web2py

2017-01-01 Thread Mark Graves
2017 at 9:02 AM, lyn2py wrote: > > > On Saturday, December 31, 2016 at 5:06:07 AM UTC+8, Mark Graves wrote: >> >> How did you install web2py? as a zip? via git? >> > > *git clone* > > >> Did you ever pip install gluon? >> > > *n

Re: [web2py] Re: homebrew python not working with web2py

2017-01-01 Thread Mark Graves
commands are on the same directory. > Secondly, I have tried git clone recursive in a brand new folder, but it's > still the same result. > > On Monday, January 2, 2017 at 9:51:55 AM UTC+8, Mark Graves wrote: >> >> potential quick fix before giving it thought: >> >

Re: [web2py] Re: homebrew python not working with web2py

2017-01-03 Thread Mark Graves
did you try the downloaded via zip version? On Mon, Jan 2, 2017 at 9:01 AM, lyn2py wrote: > Nope :) > > On Monday, January 2, 2017 at 10:55:59 AM UTC+8, Mark Graves wrote: >> >> Is it in a virtual environment? >> >> -Mark >> >> On Sun, Jan 1, 2017 a

Re: [web2py] Re: homebrew python not working with web2py

2017-01-03 Thread Mark Graves
Wait wait, whats the output of which python On Tue, Jan 3, 2017 at 3:43 AM, Mark Graves wrote: > did you try the downloaded via zip version? > > On Mon, Jan 2, 2017 at 9:01 AM, lyn2py wrote: > >> Nope :) >> >> On Monday, January 2, 2017 at 10:55:59 AM UTC+8, Ma

Re: [web2py] Re: homebrew python not working with web2py

2017-01-03 Thread Mark Graves
Also, under each please list the output of: import os print os.environ['PYTHONPATH'] import sys print sys.path On Tue, Jan 3, 2017 at 3:58 AM, Mark Graves wrote: > Wait wait, whats the output of > > which python > > On Tue, Jan 3, 2017 at 3:43 AM, Mark Graves wr

Re: [web2py] Re: homebrew python not working with web2py

2017-01-03 Thread Mark Graves
(key) >> >> KeyError: 'PYTHONPATH' >> >> >>> import sys >> >> >>> print sys.path >> >> ['', >> '/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python27.zip' >> , >>

[web2py] Re: How to architect a public facing data subset

2017-01-26 Thread Mark Graves
+1 for Leonel On Wednesday, January 25, 2017 at 7:51:49 PM UTC-6, Dave S wrote: > > > > On Wednesday, January 25, 2017 at 4:31:20 PM UTC-8, Leonel Câmara wrote: >> >> web2py permissions not enough? >> >> If not, I guess you could make 2 applications which had 2 different >> users/roles in the sam

[web2py] Caching of Modules

2014-01-16 Thread Mark Graves
I'm trying to import a local module into my application. I've got the following at the bottom of one of my model files: from gluon.custom_import import track_changes track_changes(True) It still appears to be caching the class definition. Has any of this code changed recently? Initially I was

[web2py] Minimum Response Time Tuning

2014-02-10 Thread Mark Graves
Hey Everyone, I'm deploying a web-service app which will require sub second response times. The code is entirely written in python and the algorithm to compute the output takes approximately .3 seconds. Will web2py's overhead be too much to deliver the response time I need? Should I consi

Re: [web2py] Re: Minimum Response Time Tuning

2014-02-10 Thread Mark Graves
do not need any > of this and you need sub ms performance, I'd recommend bare bone tornado or > gevent. You do not need a framework. > > Massimo > > > > > > On Monday, 10 February 2014 07:00:54 UTC-6, Mark Graves wrote: >> >> Hey Everyone, >> >

[web2py] Best practices for using mercurial within web2py

2014-02-21 Thread Mark Graves
Hey everyone, I'm trying to use web2py to manage multiple repos on my local system. I know using os.chdir is a problem. Is the best way to just hg clone [REPO_URL] [FULL_PATH_TO_FILES]? Also, relatedly, I was trying to restart apache from within a web2py app. That was giving me errors, so I'm

Re: [web2py] Best practices for using mercurial within web2py

2014-02-21 Thread Mark Graves
Right. I know the commands. But is there an issue restarting apache from within web2py (which is running on apache)? I was getting some errors when i ran the commands from within web2py vs shell On Fri, Feb 21, 2014 at 9:47 PM, Calvin Morrison wrote: > > Also, relatedly, I was trying to resta

Re: [web2py] Re: Best practices for using mercurial within web2py

2014-02-28 Thread Mark Graves
the pulls and updates. I did this to avoid os.chdir() (for thread safety) ... Is it better to use the mercurial python api? Anyone have any experience with this? Mark On Thu, Feb 27, 2014 at 3:12 PM, Dave S wrote: > On Friday, February 21, 2014 7:28:20 PM UTC-8, Mark Graves wrote: >&g

[web2py] Web2py / Pydal Time Fields

2015-11-04 Thread Mark Graves
Hey everyone, I find myself in the need for microsecond level precision for time fields where I am querying over those fields regularly. As I dug into pydal and web2py's internals, I noticed that it seems to be convention that times are truncated to H:M:S I'm aware I can easily store as a stri

Re: [web2py] Web2py / Pydal Time Fields

2015-11-10 Thread Mark Graves
I ended up converting to Decimal and then working from there. On Tue, Nov 10, 2015 at 1:18 AM, Manuele Pesenti wrote: > Il 05/11/15 06:53, Mark Graves ha scritto: > > Hey everyone, > > > > I find myself in the need for microsecond level precision for time > > fiel

Re: [web2py] Web2py / Pydal Time Fields

2015-11-10 Thread Mark Graves
No, thankfully everything was done in one timezone =) On Tue, Nov 10, 2015 at 8:53 AM, Manuele Pesenti wrote: > Il 10/11/15 10:39, Mark Graves ha scritto: > > I ended up converting to Decimal and then working from there. > ok, not so far from my approach... you don't need to

Re: [web2py] Re: Web2py / Pydal Time Fields

2015-11-11 Thread Mark Graves
What about changing the format specification to allow for the format so you could still have the time there. The only problem I thought I saw is that stripping off ms is built into a number of pydal adapters (I think -- might be wrong) With that, it would in theory allow backward compatibility fo

[web2py] New Web2py Materialize CSS Welcome app scaffold

2015-11-13 Thread Mark Graves
Hey everyone, I just put up a new web2py welcome scaffold app based on materializecss. The repository is available at: https://bitbucket.org/MarkGraves/welcome_materialize/ You can preview it at: https://gravesmedical.pythonanywhere.com/welcome/ There are definitely some issues, but I though

Re: [web2py] New Web2py Materialize CSS Welcome app scaffold

2015-11-13 Thread Mark Graves
chard > > On Fri, Nov 13, 2015 at 12:55 PM, Mark Graves wrote: > >> Hey everyone, >> >> I just put up a new web2py welcome scaffold app based on materializecss. >> >> The repository is available at: >> >> https://bitbucket.org/MarkGraves/wel

Re: [web2py] Re: Appconfig cast boolean

2015-11-19 Thread Mark Graves
I just tried to reproduce your error and could not. Judging from the error, are you sure you are passing in the string 'auth.create_user_groups' and not auth.create_user_groups as a variable? On Thu, Nov 19, 2015 at 9:32 PM, 黄祥 wrote: > tested it. return an error if i put the value int = 1 as

Re: [web2py] Re: Appconfig cast boolean

2015-11-19 Thread Mark Graves
bool(int(value) ) ) > > but it returns an error when i set the value in privates/appconfig.ini > into 1 > > any idea? > > thanks n best regards, > stifan > > > On Friday, November 20, 2015 at 11:36:33 AM UTC+7, Mark Graves wrote: >> >> I just t

Re: [web2py] Re: Appconfig cast boolean

2015-11-19 Thread Mark Graves
Also: auth.settings.create_user_groups = myconf.take('auth.create_user_groups', cast=lambda value: bool(int(value))) On Thu, Nov 19, 2015 at 10:53 PM, Mark Graves wrote: > Can you reproduce this error in a fresh welcome app? > > Then you can send just the one lin

Re: [web2py] Re: Appconfig cast boolean

2015-11-19 Thread Mark Graves
It appears that auth.settings.create_user_groups takes either False or the string that formats the user group creation message. So you'll need to provide a string format representation ie '%(id)s' as is shown in the error. However that won't convert to a boolean, so your cast function will fail.

[web2py] web2py / pydal returning id 1 in postgres

2015-11-22 Thread Mark Graves
Are there any caveats to know about running applications in shell mode (e.g. transactions / returning id)? I'm running a middleware migration script to migrate someone off an old database to a new one. When I run a db.table.validate_and_insert() it keeps returning me id 1. This is yielding a du

Re: [web2py] Re: web2py / pydal returning id 1 in postgres

2015-11-24 Thread Mark Graves
gt; What does the code look like? Are you calling db.commit() at any point? > > > On Sunday, November 22, 2015 at 9:58:05 PM UTC-5, Mark Graves wrote: >> >> Are there any caveats to know about running applications in shell mode >> (e.g. transactions / returning id)? >&

Re: [web2py] Re: web2py / pydal returning id 1 in postgres

2015-11-25 Thread Mark Graves
k which I store in the database >> to make my life easier. >> >> Anyone have any experience with that? >> >> On Mon, Nov 23, 2015 at 6:06 AM, Anthony wrote: >> >>> What does the code look like? Are you calling db.commit() at any point? >>> &g

[web2py] Re: web2py / pydal returning id 1 in postgres

2015-11-25 Thread Mark Graves
Code available @ https://github.com/gravesmedical/migration Its just a series of scripts that gets run in the order they are in the scripts directory. -Mark On Sunday, November 22, 2015 at 8:58:05 PM UTC-6, Mark Graves wrote: > > Are there any caveats to know about running applicati

[web2py] Re: Embed pdf and file download

2015-11-28 Thread Mark Graves
I would personally use pdf.js. Does that meet your needs? -Mark On Thursday, November 26, 2015 at 3:01:50 PM UTC-6, Gael Princivalle wrote: > > Dear Leonel thanks a lot. > > I've tried also with stream without success. > "/stream/memos.memo_file.ac5f12657d916e96.456c656e636f5f646f63756d656e74695

Re: [web2py] Re: New Web2py Materialize CSS Welcome app scaffold

2015-11-28 Thread Mark Graves
ood work Mark! > > Did you check if the SQLFORM and other web2py forms are still working > after disabling bootstrapcss? > > Thanks > > > On Friday, 13 November 2015 22:55:56 UTC+5, Mark Graves wrote: >> >> Hey everyone, >> >> I just put up a new w

Re: [web2py] Re: Embed pdf and file download

2015-11-28 Thread Mark Graves
https://bitbucket.org/MarkGraves/web2py_pdf_view Here's a really basic example of pdf.js integration. Basically, all I did was drop in pdf.js and then return it as a stream via ajax. -Mark On Sat, Nov 28, 2015 at 2:50 PM, Gael Princivalle wrote: > Leonel, if you can send me a sample app it wi

[web2py] Re: web2py / pydal returning id 1 in postgres

2015-11-28 Thread Mark Graves
Still have not figured this out. Trying a different approach, but I suspect it was Massimo's hunch. If I locally upload the files without and uploadfs, then I s3sync the files up to my s3bucket and set the uploadfs to that bucket after, will web2py find them automatically? I know i could dig i

[web2py] aws s3 uploadfs

2015-12-09 Thread Mark Graves
Hey everyone, I've got an odd issue I've been experiencing. I uploaded about 10k files through the DAL into my local filesystem. Then, I s3synced them, and mounted the s3 to the uploadfs for the DAL field. The bucket and permissions for the keys and configuration works, because I accessed it

[web2py] Re: aws s3 uploadfs

2015-12-09 Thread Mark Graves
Interesting update. I used the same code from the command line, it worked. Copied and pasted inside web2py, it stopped working with 403. On Wednesday, December 9, 2015 at 5:26:52 PM UTC-6, Mark Graves wrote: > > Hey everyone, > > I've got an odd issue I've been experien

[web2py] SELinux and web2py

2015-12-10 Thread Mark Graves
Has anyone got any experience with selinux file permissions and web2py? Somehow my sessions are not writing for the admin app but they are for the welcome app... -Mark -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - h

Re: [web2py] SELinux and web2py

2015-12-10 Thread Mark Graves
.com> wrote: > >> Have you look to the welcome app user? >> >> ls -al >> >> Then >> >> chown -Rf same_welcome_app_user:same_welcome_app_user >> >> Richard >> >> On Thu, Dec 10, 2015 at 7:50 PM, Mark Graves wrote: >> >

Re: [web2py] SELinux and web2py

2015-12-10 Thread Mark Graves
Same permissions =( On Thu, Dec 10, 2015 at 7:05 PM, Mark Graves wrote: > Its centos. I'll check that now. Its owned by apache > > On Thu, Dec 10, 2015 at 7:04 PM, Richard Vézina < > ml.richard.vez...@gmail.com> wrote: > >> with ubuntu the default owner fo

Re: [web2py] SELinux and web2py

2015-12-11 Thread Mark Graves
orry in french : > https://fr.wikipedia.org/wiki/SELinux > > I check english one and there where not this example... > > Then I don't know how you chage these exented attribute, there surely > other exented command for that > > :D > > Richard > > On Thu, D

[web2py] multiple auth instances for one app

2015-12-19 Thread Mark Graves
Hey everyone. Interesting question here. Has anyone ever used two instances of auth in the same app, on two separate databases: eg. db1 = DAL() db2 = DAL() auth1 = Auth(db1) auth2 = Auth(db2) Would that run into any thread safety issues? -Mark -- Resources: - http://web2py.com - http://we

Re: [web2py] Re: multiple auth instances for one app

2015-12-21 Thread Mark Graves
ber 2015 03:03:45 UTC-6, Mark Graves wrote: >> >> Hey everyone. >> >> Interesting question here. >> >> Has anyone ever used two instances of auth in the same app, on two >> separate databases: >> >> eg. >> >> db1 = DAL() >> db2 =

Re: [web2py] Re: multiple auth instances for one app

2015-12-22 Thread Mark Graves
for this. Tell us more. >> >> >> On Saturday, 19 December 2015 03:03:45 UTC-6, Mark Graves wrote: >>> >>> Hey everyone. >>> >>> Interesting question here. >>> >>> Has anyone ever used two instances of auth in the same app, on t

Re: [web2py] Re: multiple auth instances for one app

2015-12-22 Thread Mark Graves
ay, December 19, 2015 at 4:03:45 AM UTC-5, Mark Graves wrote: >> >> Hey everyone. >> >> Interesting question here. >> >> Has anyone ever used two instances of auth in the same app, on two >> separate databases: >> >> eg. >> >> db1 = D

[web2py] Re: web2py on AWS

2016-01-23 Thread Mark Graves
Hey Dave, Any reason why you are choosing to use the rocket server and manual install? I usually use the scripts from github as follows: (configurable, but ubuntu is easiest) 1. Create new ubuntu micro box. 2. ssh into box 3. wget https://raw.githubusercontent.com/web2py/web2py/master/scripts/

[web2py] Re: web2py on AWS

2016-01-23 Thread Mark Graves
Re reading your answer, check the access logs. See if rocket is getting overwhelmed by robots or other spam traffic. consider installing ip tables if thats the case or use nginx. -Mark On Saturday, January 23, 2016 at 1:46:56 AM UTC-6, Dave S wrote: > > I'm trying to set up a demo on an AWS fr

Re: [web2py] Re: web2py on AWS

2016-01-24 Thread Mark Graves
Can you do ps -aux and see whether you can see rocket listening on port 80? -Mark On Mon, Jan 25, 2016 at 12:44 AM, Dave S wrote: > > > On Saturday, January 23, 2016 at 12:58:25 PM UTC-8, Mark Graves wrote: >> >> Re reading your answer, >> >> check the ac

[web2py] Re: constraints

2016-02-28 Thread Mark Graves
db.define_table('table_1_name', Field('field_1_name','string')) db.define_table('table_2_name', Field('table_1_reference_field','reference table_1_name')) It looks like you defined the field as an integer field and then are attempting to redefine it as a reference field. -Mark On Sunda

[web2py] auth_user extra fields + row.to_dict()

2016-04-05 Thread Mark Graves
Hey everyone, I saw a random bug in an app I'm working on, and I was wondering what the correct approach is. I have auth.settings.extra_fields["auth_user"] = [LIST_OF_FIELDS] later, I select that row and get it as a dict: row = db(db.auth_user.id == user_id).select().first().as_dict() then I

Re: [web2py] auth_user extra fields + row.to_dict()

2016-04-06 Thread Mark Graves
Hey Anthony and Richard, Yes you are both correct. I am attempting to create a usable JSON object. The confounding details from what I can tell are: 1.) the offending method is defined in a model file, which returns a dictionary, which is then json serialized via response.json(RETURNED_FROM_MO

Re: [web2py] auth_user extra fields + row.to_dict()

2016-04-06 Thread Mark Graves
= {'auth_fields':row, "other_stuff":{"hello":False}, "second_bool":False} return response.json(profile) This returns the following JSON response: {"second_bool": false, "auth_fields": {"_extra": {"test_field

Re: [web2py] auth_user extra fields + row.to_dict()

2016-04-06 Thread Mark Graves
Ah! Of course. Thanks Anthony! I knew it was something dumb i did =) -Mark On Wed, Apr 6, 2016 at 11:35 AM, Anthony wrote: > table = db.auth_user >> fields = ['id','first_name'] >> fields.append('test_field_1') >> >> query = table.id > 0 >> >> row = db(query).select(*fiel

[web2py] reading config flat files in from module

2014-04-09 Thread Mark Graves
Hey Everyone, For various reasons, I import some configuration information from files in an application I'm working on (config.json). There are some limitations which are forcing me to take this approach. This configuration information is imported in a web2py module file (config.py) When I ch

[web2py] Re: reading config flat files in from module

2014-04-09 Thread Mark Graves
I ended up fixing my own problem. I had declared some configuration variables directly within the config.py module. I moved the functions that load the config information into a class and instantiate that class, and it all worked. On Thursday, April 10, 2014 1:02:05 AM UTC-5, Mark Graves

[web2py] Security of serving static files referenced in DB

2014-05-10 Thread Mark Graves
Hey everyone, So I have a bunch of static files, managed by the database, which are not proprietary. They will be public content on the web site. I put them in the static folder so they can be served by Apache instead of streamed by web2py. As I developed, I put a link in to download these f

Re: [web2py] Re: Security of serving static files referenced in DB

2014-05-10 Thread Mark Graves
ssing to find > files to download. Exposing the names of actual files that you are making > available to the public should not pose any problems. > > Anthony > > > On Saturday, May 10, 2014 1:20:03 PM UTC-4, Mark Graves wrote: >> >> Hey everyone, >> >>

[web2py] Anyone ever done a braintree integration with web2py?

2014-05-30 Thread Mark Graves
Hey everyone, Using braintree to process payments in an app I'm working on. Anyone ever done it and willing to answer a few questions? (I checked their documentation, I was more interested in a few web2py specifics) -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) -

[web2py] Anyone ever done a braintree integration with web2py?

2014-05-30 Thread Mark Graves
Hey everyone, Using braintree to process payments in an app I'm working on. Anyone ever done it and willing to answer a few questions? (I checked their documentation, I was more interested in a few web2py specifics) -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) -

[web2py] AJAX and sessions

2014-06-21 Thread Mark Graves
Hey Everyone, I have a question about session.forget(response) I've got an application to filter an inventory across multiple categories. Each filter works independently, however, one appears buggy. It sends data on keyup. As long as this data is entered in slow enough, the filters update pro

[web2py] Seeking Experienced web2py Functional Tester

2014-08-13 Thread Mark Graves
Hey everyone! We are looking for a functional test script to be written for a web2py application for a small fee. We will provide a test environment, user access control list, list of URL's, expected results, and actual results. Results are behavioral in nature and will include modals. We are

[web2py] SQLFORM uploads with uploadfs and Amazon S3

2014-10-03 Thread Mark Graves
Hey Everyone, Does anyone have experience using SQLFORM with Amazon S3 for upload fields? My standard SQLFORM(db.table,record) is not removing the S3 object for the uploaded file. It is properly uploading the file and getting the obfuscated filename. Is there another argument I'm missing or

Re: [web2py] Re: SQLFORM uploads with uploadfs and Amazon S3

2014-10-07 Thread Mark Graves
imo Di Pierro > wrote: > > you say "it is not removing". Do you expect it to delete the files? > >> On Friday, 3 October 2014 16:31:28 UTC-5, Mark Graves wrote: >> Hey Everyone, >> >> Does anyone have experience using SQLFORM with Amazon S3 for upload

Re: [web2py] Re: SQLFORM uploads with uploadfs and Amazon S3

2014-10-08 Thread Mark Graves
That is precisely what I was envisioning. Perhaps this is a better discussion for the developer group? On Tue, Oct 7, 2014 at 12:29 PM, Leonel Câmara wrote: > I think Mark has a point. The way Set.delete_uploaded_files is defined > right now forces you to implement a custom_delete if you want

[web2py] Re: Returning a token for Android app authentication

2014-10-10 Thread Mark Graves
Did you ever finish this? I implemented something similar. I'd love to collaborate and get a repo up for working with mobile devices with web2py as an app back end. On Sunday, January 6, 2013 11:43:05 AM UTC-6, dlypka wrote: > > If you mimic the same http traffic that a browser would generate,

[web2py] Thread safety and importing db, response, session

2014-12-14 Thread Mark Graves
Hey everyone, I could use a sanity check here from the community. In a controller I get a record, then, I want to pass do some database calls from a module. It seems that the least code I could write would be in models: from gluon import current current.db = db Then in the module at the top

[web2py] Re: Thread safety and importing db, response, session

2014-12-14 Thread Mark Graves
> http://www.web2py.com/books/default/chapter/29/04/the-core#Accessing-the-API-from-Python-modules > > You cannot assign the thread local object to a top-level variable in the > module, as it will only be assigned once upon first import. > > Anthony > > On Sunday, December 14, 2014

[web2py] Re: Thread safety and importing db, response, session

2014-12-15 Thread Mark Graves
15, 2014 9:23:42 AM UTC-6, Anthony wrote: > > You can also just import current in the module and then refer to it > directly within your function (i.e., no need to pass current as an argument > to the function). > > Anthony > > On Sunday, December 14, 2014 11:07:48 PM

[web2py] Re: Testing and web2py - especially appadmin

2015-02-16 Thread Mark Graves
James, Thank you for bringing up this very important issue. I have been setting up a continuous integration environment using open source software (Jenkins) as well as some tutorials, in the manner of the ruby koans package. If you're interested, there are 3 repos right now (They are very ro

Re: [web2py] Re: Testing and web2py - especially appadmin

2015-02-19 Thread Mark Graves
You may also consider pytest bdd. Its a pytest plugin that brings in BDD gherkin syntax and executable specifications. A nice complement/alternative to behave. On Thursday, February 19, 2015 at 9:29:19 AM UTC-6, Richard wrote: > > Thanks! > > You maybe right about TDD being less applicable web

[web2py] py.test database issues

2015-03-03 Thread Mark Graves
I've been encountering some strange issues that I have never seen before. I'm running some a complete regression suite on an application. It's pretty long running, in the current iteration. (over 400 seconds). This includes a number of browser automation tasks using python and selenium. For an

Re: [web2py] Re: py.test database issues

2015-03-03 Thread Mark Graves
of pg8000. > > > On Tuesday, 3 March 2015 09:21:46 UTC-6, Mark Graves wrote: >> >> I've been encountering some strange issues that I have never seen before. >> >> I'm running some a complete regression suite on an application. It's >> pretty long ru

[web2py] Re: Thread safety and importing db, response, session

2015-04-08 Thread Mark Graves
ie: in a controller: from applications.MY_APPLICATION_NAME.modules.SOME_MODULE_NAME import foo x = foo(db,argument) ? On Monday, December 15, 2014 at 3:26:15 PM UTC-6, Anthony wrote: > > Yes, that should do it. > > Anthony > > On Monday, December 15, 2014 3:35:01 PM UTC-5, Mar

Re: [web2py] Re: Thread safety and importing db, response, session

2015-04-09 Thread Mark Graves
Thanks Anthony, Sorry, I was a bit delirious writing that =) -Mark On Thu, Apr 9, 2015 at 6:47 AM, Anthony wrote: > Sure, that's how Auth and Crud work. > > Anthony > > -- > Resources: > - http://web2py.com > - http://web2py.com/book (Documentation) > - http://github.com/web2py/web2py (Source

[web2py] AWS S3 SSLv3 Deprecation

2015-04-15 Thread Mark Graves
Hey everyone, I realize this is more of a server administration question than web2py in specific, but I want to make sure I cover all my bases, I recently received an email from AWS about their deprecation of SSLv3 in connecting to S3. I have an app deployed behind nginx, but the only ssl pro

Re: [web2py] Re: AWS S3 SSLv3 Deprecation

2015-04-15 Thread Mark Graves
Thank you! Mark Graves > On Apr 15, 2015, at 5:42 PM, Niphlod wrote: > > the problem would arise only if you connect to S3 to fetch whatever is stored > there AND you use a library that allows ONLY SSLv3. > Since most of python modules manage other https algorithms wit

[web2py] Re: web2pyslices

2017-03-31 Thread Mark Graves
I'd be happy to convert it to something. I can write a quick scraper which would maintain whatever info is publicly available and upload it as static files to github or something. On Tuesday, March 21, 2017 at 2:53:16 PM UTC-5, Massimo Di Pierro wrote: > > web2pyslices is becoming hard to mai

[web2py] auth_cas redis session_filename + logout issue

2017-08-17 Thread Mark Graves
Hey everyone, Question / potential bug(s): I created the following to reproduce: https://bitbucket.org/MarkGraves/web2py_cas Basically, when I run that setup.sh, it sets up two apps and installs redis in virtual environments, copies in web2py, and replaces db.py with the one in the main rep

[web2py] Re: auth_cas redis session_filename + logout issue

2017-08-18 Thread Mark Graves
sessions are used. They are created when redis sessions are not used. Is that expected behavior? It strikes me as a misconfiguration issue. On Friday, August 18, 2017 at 12:22:40 AM UTC-5, Mark Graves wrote: > > Hey everyone, > > Question / potential bug(s): > > I created the foll

Re: [web2py] Re: auth_cas redis session_filename + logout issue

2017-08-24 Thread Mark Graves
Fri, Aug 18, 2017 at 12:35 PM, Mark Graves wrote: > On deeper inspection, the logout issue is strange, and related to the > redis sessions. > > auth.settings.login_form.cas_logout_url > > > is the right URL. If I visit it independently in a browser it works as > expected. &

  1   2   >