[google-appengine] Can't remember the name of this startup
A couple of years ago someone presented a nice app hosted on App Engine that I'm trying to remember now. The developer was based on Japan, I think. The app was a web authoring tool for documentation, classes, presentations, manuals etc -- it was a simple elearning authoring tool. It had a js-based editor to create and organize pages, and select themes, and so on. I don't want a tool similar to the one I described; I want to remember what was the name of that site. Any takers? :) cheers, rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To unsubscribe from this group and stop receiving emails from it, send an email to google-appengine+unsubscr...@googlegroups.com. To post to this group, send email to google-appengine@googlegroups.com. Visit this group at http://groups.google.com/group/google-appengine?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
[google-appengine] Re: Stackoverflow
+1 Objective questions have reduced usefulness here, as there's more noise and they get lost with time. SO's peer review forces people to stay on topic, thus reducing noise and making questions more reusable. The group is better for less objective discussions, of course. -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To view this discussion on the web visit https://groups.google.com/d/msg/google-appengine/-/KkBHR99piiwJ. To post to this group, send email to google-appengine@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
Re: [google-appengine] App Engine Weekly Community Update #1
Hi Jay, This was also posted on Google Plus: https://plus.google.com/111042085517496880918/posts/exjJoZwygq1 Until there're brand pages on g+, and then the weekly update could be posted on a 'App Engine' profile, you can follow Johan using the link above. -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To view this discussion on the web visit https://groups.google.com/d/msg/google-appengine/-/lBsHKUaKDiUJ. To post to this group, send email to google-appengine@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] Re: Requests hanging when using Chrome and development server (python)
I had this problem a while ago, and later figured a solution: http://stackoverflow.com/questions/5989159/switching-subdomains-locally-takes-several-seconds-what-could-it-be/5990860#5990860 In short, in to fix it, in Chrome 12 go to Preferences/Under the Hood, and uncheck Predict network actions to improve page load performance. This was known as DNS prefetching in previous Chrome versions. -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To view this discussion on the web visit https://groups.google.com/d/msg/google-appengine/-/xgfdDrRD1_MJ. To post to this group, send email to google-appengine@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
Re: RE: [google-appengine] Re: Party like it's 1970? auto_now_add=True
Just FYI, DateProperty, TimeProperty and DatetimeProperty all store the same type in the datastore: a datetime representation. The difference is that the first two are stored incomplete (on DateProperty, time will be 00:00 00:00, on TimeProperty, date will be 1970-01-01), and that's what you see in the datastore. It's hard to justify using DateProperty or TimeProperty since the storage space used and underlying type are the same, so I end always using DatetimeProperty. -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] Re: URL Dispatch efficiency
I guess even with 10 thousand rules it would be very fast and building/matching would take milliseconds. Easy to test it yourself. -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
Re: [google-appengine] Re: URL Dispatch efficiency
There's a limit to the number of handlers you can define in app.yaml. IIRC, it's about 100. Oh, I was only referring to matching URLs passed to webapp.WSGIApplication (Python). I'd just say you don't need to worry about that. You need *a lot* of URL patterns for the matching process to be noticeable. -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] Re: Prerelease SDK 1.3.8 is out!
On Oct 6, 6:48 am, Greg wrote: I guess one solution would be to make downloading optional. A setting to disable source downloading in app.yaml would be safe, because uploading a new version would destroy the existing code. +1 I always considered not being able to download the code a feature. Making it optional would probably be ideal. -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appeng...@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] Re: SSO with built-in OpenId is possible?
On Aug 29, 11:33 pm, gops wrote: I think pure openid is possible( just login ). but , openid with oauth ( for docs and contact api etc ) is not possible with sso. What I am missing is how people achieve login coming from Google Apps without passing by the approval screen (user is prompted for authorization). I've set a manifest file with a whitelisted domain and so on, and after several tries I'm considering if SSO is even possible with built-in OpenId auth. -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appeng...@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] Re: Multitenancy and datastore performance
On Aug 30, 7:55 am, l.denardo wrote: In my application the only suitable namespace would be the user's email domain (Google Apps domain btw), making the choice of multitenancy nearly useless (I currently have security checks to separate user's access to datastore object). Why useless? If each user only accesses his own data, using a namespace could make sense. It would make queries simpler, and one less filter should probably affect performance positively. -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appeng...@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] Re: Multitenancy and datastore performance
On Aug 30, 10:08 am, l.denardo wrote: The point in my question is: does multitenancy impact performance when user ID (or anything which will be used as a namespace identifier) is not explicitly used for filtering? Does the use of namespaces improve performances, e.g., of getObjectByID? AFAIK, all getObjectByID calls use namespaces. They are used to build the key. So there's no difference in performance, because you are using namespaces *anyway* (even if the default one). -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appeng...@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] Re: SSO with built-in OpenId is possible?
On Aug 31, 12:23 am, gops wrote: Confirmation is done only one time. the first time. if you want to avoid confirmation even for first time, domain should be registered to google first. ( which they may not approve for OAuth+OpenID , as you have mentioned in a linked document.) Hi gops, Indeed. I can confirm now that SSO works with built-in OpenId. Got it working and the problem was (probably) a bad URL that I added to the marketplace white-list (it seems that even ending slashes matter, or I missed something in my previous attempts). Now user coming from Google Apps can be logged in directly, without confirmation. -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appeng...@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] SSO with built-in OpenId is possible?
Hey everybody, Is it possible to achieve SSO with the buil-in OpenId? I've been trying to integrate a Marketplace app and get the user logged in when coming from Google Apps (the admin panel or universal navigation). I failed miserably, then now I found this: The one exception to this is applications which do hybrid OpenID/ OAuth — whitelisting does not currently work with this approach. [1] I assume that I have to implement OpenId using a library instead of using the built-in one to achieve SSO with Google Apps in my app? Or is it possible to implement SSO with built-in OpenId? And if so, do you know if there are code examples anywhere? thanks, rodrigo [1] http://code.google.com/googleapps/marketplace/sso.html -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appeng...@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] Re: Compare tipfy and kay-framework?
On Apr 14, 1:09 pm, Matt C wrote: I'm curious about both of these. From a quick overview, they are both well regarded, and to my newbie eyes, seem to be fairly similar to one another. Is there anyone who has tried both who could highlight the most important difference(s)? Also, I see that the owners of both tipfy and kay sometimes post here. Comments from either of you about your favorite feature or what makes your framework different from other frameworks would be especially appreciated. Heya, Uh, only saw this message today. I'm responsible for tipfy. Yep they are similar as both are based on several same libraries - Werkzeug, Jinja2, Babel, and so on. From my perspective the main difference is that kay follows a django'ish approach for the views organization, and tipfy is more like webapp (so we call them handlers :P). Besides the function vs class matter and general project organization, I think both have several things in common - a light core and a middleware system to plug extra functionalities, and so on. -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appeng...@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
Re: [google-appengine] Reference Properties
On Sat, Nov 28, 2009 at 10:09 PM, MajorProgamming wrote: I was wondering: isn't using reference properties a waste of space? Wouldn't it make more sense to store the id (assuming not using key_name) of the entity. After all, if the Kind is known, one can easily generate the full key based on that. And with a reference property it actually stores the _entire_ key (very long!). Storing the key or the full path is the only way to retrieve *any* entity. Why? Because you can't generate a full key for an entity that has ancestors using only a key name or id. You need the full path of ancestor entities. The key is the full path encoded. For simple and common cases (entity with no ancestor), you can surely store simply the id or key name. But you have to keep in mind that this won't work for any possible entity (if you store an entity with ancestor, you can't retrieve it back). -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appeng...@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
Re: [google-appengine] What IDE the community recommend to developers of Python+GAE
On Tue, Nov 24, 2009 at 9:16 PM, frankabel wrote: I know that Java+GAE have http://code.google.com/eclipse/ as google recommendation, but what about Python+GAE developers? eclipse + pydev plugin is probably the only ide with built-in app engine support. hope this helps. -- rodrigo -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appeng...@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] Re: [Python] Reading files with python and open()
On Sat, Nov 7, 2009 at 1:39 PM, warlock24 warloc...@gmail.com wrote: [CODE] ROOT_DIR = os.path.dirname(__file__) pageUrl = os.path.join(ROOT_DIR, 'pages/' + pageName + '.html') pageContent = open(pageUrl, 'r').read() [/CODE] Is the .html file mapped in app.yaml as static file? If it is, it can't be read directly. If not, try using abspath: ROOT_DIR = os.path.abspath(os.path.dirname(__file__)) -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Mapping a domain name to your app
On Sun, Nov 8, 2009 at 5:13 PM, Daniel wrote: Is it impossible to map the root domain to Google Apps or Google App Engine instances? It appears so. It is. You can't map a naked domain to a CNAME. You need to set a redirect from the naked domain to the non-naked domain using services from your dns provider or others. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Mapping a domain name to your app
On Fri, Nov 6, 2009 at 6:42 PM, Al a...@infosports.com wrote: The question I have is, is it possible to just use the plain domain name. If if so how does one map the domain name at GoDaddy? It is not possible - naked domains are not allowed. What you can do is to use a redirect service from Godaddy, so that people accessing http://kindlemap.net will be redirected to http://www.kindlemap.net . On the happy side, www is good! See: http://www.www.extra-www.org/ :-D -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: db.Query and cursor
On Wed, Oct 14, 2009 at 4:03 PM, Paul Kinlan wrote: Hi Guys, Just browsing the source for the 1.2.6 to see if there is support for querying multiple ancestors (something I think I need but I don't think is supported) and I noticed that _BaseQuery and Query has compilation options and associated cursor support. Is this for iterating across results 1000? I played with cursors a little bit, and while they work on dev server, in production query.cursor() seems to always return None. It's not officially released, so nothing to complaint. :-( Here's a basic example: query = MyModel.all() results = query.fetch(10) cursor = query.cursor() for the next query, you can use the cursor: query = MyModel.all().with_cursor(cursor) results = query.fetch(10) This second query will start where the later stopped. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: AttributeError: 'Key' object has no attribute '_str'
On Tue, Oct 13, 2009 at 1:56 PM, johnP wrote: OK, folks. Please let me know what to do in the contingency where I have an application that is functioning; have paying customers; then after a change on Google's side - it stops functioning; and when I try to contact people at Google, I get radio silence? johnP johnP, the immediate solution for your issue would be to rebuild the files with cached pickles. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Prettier values for reference keys?
On Mon, Oct 12, 2009 at 4:45 AM, Tonny wrote: in. I could write my own ReferenceProperty from scratch, subclassing Property, but I would also like a simple solution where I didn't reinvent all ready existing functionality. use a StringProperty, and add some utility functions to set it from a referenced entity or to get a entity based on the stored key_name. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Prettier values for reference keys?
On Mon, Oct 12, 2009 at 4:45 AM, Tonny wrote: in. I could write my own ReferenceProperty from scratch, subclassing Property, but I would also like a simple solution where I didn't reinvent all ready existing functionality. ignore my previous post. here's a solution that does exactly what your looking for. add this method to your model: def get_key_name_from_reference_property(self, prop_name): key = getattr(self.__class__, prop_name).get_value_for_datastore(self) return db.Key(key).key_name() then, you simply call it passing the ReferenceProperty name. class MyModel(db.Model): some_other_entity = db.ReferenceProperty() entity = MyModel.get(...) referenced_key_name = entity.get_key_name_from_reference_property('some_other_entity') that's it. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: The development environment datastore is so slow
On Sun, Oct 11, 2009 at 2:06 PM, (jpgerek) wrote: Does anyone have a solution or workaround apart from working with a reduced data set ? There's nothing to do with the current implementation which is indeed very simple and can't handle large data sets (everything is loaded into memory and there's no indexing at all, afaik). The alternative would be to set an environment with a real database. I'm afraid however that the current options are at a very early stage of development. One recently announced was TyphoonAE, which uses mongoDB for the database backend: http://code.google.com/p/typhoonae/ I never tested it myself, though. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: What are your top three issues in appengine?
1. WordPress support http://code.google.com/p/googleappengine/issues/detail?id=124 2. Klingon support http://code.google.com/p/googleappengine/issues/detail?id=2134 3. COBOL and Lolcats support http://code.google.com/p/googleappengine/issues/detail?id=150 nah. i am kidding. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Discussion on deleting-existing-www-mapping-from-google-apps
On Thu, Oct 8, 2009 at 1:33 PM, qweruiop qweru...@gmail.com wrote: I disabled Sites service completely (or was it the Start Page? not sure) and was able to map the www address to the app engine. However, right now it's giving me a Not Found The requested URL / was not found on this server. you have to remove sites and add it back a couple of times. it's a weird bug, and from time to time it gets me again. there's an issue that describes the solution better than me: http://code.google.com/p/googleappengine/issues/detail?id=768 -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: HELP ME PLZ!!!
On Wed, Oct 7, 2009 at 5:34 AM, Snail wrote: I input my mobile number and press send button, and later I received a verification code, but google said it's a wrong verification code, I'm sure there's no mistakes in the code. Now google says I have applied to many times for verification code, what can I do? send a message describing your problem using the SMS issue form: https://appengine.google.com/waitlist/sms_issues -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: What are your top three issues in appengine?
mine are... 1) Built-in Paging (no issues, but it's in roadmap and coming soon) Currently we have to re-implement or re-think paging for every situation. 2) Full-text search API (http://code.google.com/p/googleappengine/issues/detail?id=217) No-brainer. Much needed and required by almost all kinds of apps. 3) Subdomain management API (http://code.google.com/p/googleappengine/issues/detail?id=2214 and http://code.google.com/p/googleappengine/issues/detail?id=113) It's a Google Apps issue, but very related to GAE. We can't have http://my-customer-id.my-domain.com without manual intervention, which is terrible. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: What are your top three issues in appengine?
On Tue, Oct 6, 2009 at 6:04 AM, Kenneth wrote: 1) More granular accounting of how datastore space is used http://code.google.com/p/googleappengine/issues/detail?id=1396 This one should be easy, the information is being pulled from somewhere already. Right now storage usage is a total black hole. btw, this one is coming probably in 1.2.6. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Ref static file in CSS file
On Tue, Sep 22, 2009 at 2:43 PM, stelg wrote: Seems that the total URl is not constructured properly (absolute reference) url(images/bodyBg.jpg) Did you try this url(../images/bodyBg.jpg)? (add ../ ) url(images/bodyBg.jpg) is actually relative to the stylesheet location. an absolute reference would start with a slash: url(/images/bodyBg.jpg). either one is ok, you just need to point to the correct file. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Unbelievably high CPU Time
On Tue, Sep 22, 2009 at 7:11 PM, blscott wrote: I have three tables consisting of 21 fields. The majority of them are strings and the maximum string length is approximately 50 chars. I had some 500's during the development, but not many overall. Other than disabling autogenerate in the index.yaml, how would I take control of which fields are indexed? When I tried to set indexing on single fields I got an error that this was done automatically. Thank you for your help. When definining Model properties, you can pass indexed=False as parameter. Some properties are not indexed by default (Blob, Text). -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Flatpages do not work in django app engine patch
On Sun, Sep 6, 2009 at 10:37 AM, Andrius wrote: I cannot get Django Flatpages on app-engine-patch to work on my site. I am getting 404 page not exists error. I have done all the need configuration: I don't want to sound rude, but isn't it better to post this kind of question in the specific group? http://groups.google.com/group/app-engine-patch -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Entities disappearing from index
One more update: during the night, I deleted all related indexes and rebuilt them again, hoping to fix the issue. After the rebuild, surprise: now many more entities that should be listed are missing. It got even worst. /sigh -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Entities disappearing from index
this happened again today. my user reported: i can find it and access it after a google search, but it is not listed in the page. he referred to another entity that disappeared from the index. when accessing the entity's page linked in google, the system uses the entity id, so that's ok. but when listing entities, it uses a query which should include the entity in the results, but the entity was not included. the sad conclusion is that indexes are still not reliable. :-( -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Entities disappearing from index
Hi, Last week two of my users complained about entities that disappeared. I searched for the records using a simple query with no composite index and found them, and confirmed that they were not returned by a composite index that should return them. The index was up and running, and as far as I know the entities disappeared randomly. I re-saved the same entities, and they appeared in the index again. I have no idea if other entities are missing from the index, because I only know if someone reports it, which is sad and a bit scary. Question is: in which cases can this happen? Which tricks can we use to check/ensure that an index is complete? thanks, rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Source-Code Version Control
I'd recommend Git or Mercurial for collaboration. Read why here [1]. I personally user Mercurial. Git is mainly equivalent, but Mercurial is a Python project and will be the official Python VCS [1] so I preferred it. Both have popular web services: bitbucket.org (mercurial) and github.com (git). Oh please notice that it is bitbucket.org, and not .com as said before. -- rodrigo [1] http://www.python.org/dev/peps/pep-0374/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: two applications two domains - please help
On Fri, Aug 21, 2009 at 5:32 PM, Kate wrote: OK. I have a number of applications. I successfully set up one to be accessed via one of my domains. Now I have a second app I want to map top a different domain. I'm stumped. If I have one domain with a cname rcord pointing to ghs.google.com and another pointing to ghs.google.com, how does google know WHICH app it's meant to bring up? Google Apps will look at the requested domain and load the app defined for that domain - which may be gmail, google calendar etc, or a App Engine app. That's why the domain must be registered with Google Apps. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Tasks queue to accomplish this?
Also check: http://code.google.com/p/pubsubhubbub/ And the video: http://www.youtube.com/watch?v=AgaL6NGpkB8 Both are about the fan-out problem you're trying to solve. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: All Read Please: Geographical Request Latency
São Paulo, Brazil - average 210ms -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: GAE costs more than 10 times than expected.
On Mon, Aug 10, 2009 at 11:49 AM, Sylvain wrote: 4 - Add a credit system. For example, I credit my account with 50€, then GAE/Chekout use this money this is a sweet idea! same thing happened to me for a while. i also think app engine should not charge below a certain amount, or allow us to buy credits. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Redistributing the GAE SDK
On Mon, Aug 10, 2009 at 3:53 PM, Perica Zivkovic wrote: what are the licensing terms about redistributing the SDK. I would like to include it in my Python distribution (http:// www.PortablePython.com) and I was wondering is that allowed and under what conditions. The SDK is released under a strict Apache 2 License: http://code.google.com/p/googleappengine/ So I guess it'd be ok to redistribute it. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: How to translate an application running on GAE?
On Sat, Aug 1, 2009 at 11:51 AM, Emilien Klein wrote: The problem I see with using Babel is that it IS an external library, which means that I need to integrate it with my project. What I'm looking for is a way to have a translated application WITHOUT having to install any external library... Without any other external library, you have 2 options: 1. use gettext - http://docs.python.org/library/gettext.html 2. hack and patch django's i18n The problem with the 2nd option is that your app stays tied to django's ecosystem - later you need i18n in a small project and you'll have to add django just for it. Ok, it is a valid solution, I just personally prefer to use a external library that is not coupled with a bunch of unrelated things, and avoid all the monkeypatching mess. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Cursors for continuing results?
Hey guys. I saw this in the roadmap: Cursors for continuing results of Datastore queries past the 1000 entity limit. This made me think this would be *the* thing we need for a pagination api - not only we could resume a query from the 1000th result, but also from any result - so, we could easily get query bookmarks (the encoded cursor or something) to fetch other results. Anybody knows more about how they will work? Please tell us a bit more! :-) thanks, -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: How to read a file from the local machine
On Fri, Jul 31, 2009 at 4:06 AM, shanmukh wrote: Hi team, You may find this query quite basic, as i am a tyro in developing google app engine applications. The problem is i am unable to read a file from the local machine. but i can read the file when it is uploaded to the google server.Could you please suggest me how i can achieve this? Thanks in advance, Shanmukh. supposing you have a file 'my_file.txt' in your root app dir, you just do: f = file('my_file.txt') contents = f.read() f.close() for files inside directories, prepend it with the directory name: f = file('dir_name/my_file.txt') ... that's all. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: self.request get file name.
On Fri, Jul 31, 2009 at 3:30 AM, Maxim Kremenev wrote: And another question, why GAE community don't use irc change #gae on irc.freenode.net ? the correct channel name is #appengine see you there. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: How to translate an application running on GAE?
On Fri, Jul 31, 2009 at 7:46 PM, Emilien Klein wrote: I'd like to hear if someone has successfully deployed a translated application (links please), and if possible what solution you have used. I use babel. It's a library from the trac guys: http://babel.edgewall.org/ It is a gettext wrapper and i18n tools. You can extract messages from .py and .html files, and then you translate/compile the .po/.mo catalogs. For a full implementation you can see how it is done in Kay: http://bitbucket.org/tmatsuo/kay/src/tip/kay/i18n/ -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: How to translate an application running on GAE?
Now, anwering some other questions. - I suppose that the .po / .mo files that open source projects traditionally use can not be used in the App Engine world? Yes, you can use those files with gettext functions. You'll probably need to wrap those functions and write some utilities to make it easier to use - but you don't need to do that because there are excellent libraries that have done it - Babel is the most known in the python world (I actually don't know any other). - Would you have various template files for each languages (like a contact.en.html, contact.fr.html, contact.nl.html, etc.) and use the appropriate file depending on the language that has been detected from the browser header? No! You would use one template, and have the strings wrapped by a translation function. The convention is to use a function name _. Like: {{ _(This is my string - I'll translate it later, and if not it'll be in English forever.) }} There are issues you'll find, like how to handle singular/plural and string replacements, but existing solutions cover that. - Would you use a single template file, but pass it the strings one by one that you would retrieve from the datastore (ouch, just writing this solution hurts!) Absolutelly no. The strings are stored in a .po file, which you compile into a .mo file. This if you go for the widely used gettext. Note: if you execute the following command from inside the GAE dev server folder: find | xargs -i grep -iH i18n \{\} you will see that a lot of files contain the string i18n, and that all are related to django. Does that mean that we could use standard Django internationalization techniques, or is it just that Google forgot to remove those files? I tried to use Django's i18n. Unfortunately Django is too tied to itself and that library is not reusable outside of Django. Fortunately later I found a standalone, reusable, well written one: Babel. It works very well. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Watermarking with Image Composite
On Jun 3, 8:08 pm, Mick wrote: Just tested and it worked on appspot. awesome! but is there a workaround to get it work correctly on dev? Hi Mick. I had this same problem today (no transparency in png's when using composite()), and got a quick fix. If you want to pach the SDK until it is fixed, here's how. in google.appengine.api.images.images_stub.py, on lines 114-116, you'll find: alpha = options.opacity() * 255 mask = Image.new(L, source.size, alpha) canvas.paste(source, (x_offset, y_offset), mask) replace it with... if source.mode == 'RGBA': canvas.paste(source, (x_offset, y_offset), source) else: alpha = options.opacity() * 255 mask = Image.new(L, source.size, alpha) canvas.paste(source, (x_offset, y_offset), mask) that's it. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 403 Error
On Tue, Jul 21, 2009 at 7:03 PM, Jeremy Truax wrote: I'm having it too, seems to be an old issue but unresolved: http://code.google.com/p/googleappengine/issues/detail?id=690 I just had this problem too some minutes ago, for the first time. I have only 2 versions, and in quota details it shows 24 of 250 deployments today - it's far under the allowed quota. I tried deleting version 2, and upload a new version 2 - got a 403. I tried creating a version 3 - got a 403. I'm blocked now by this. Can anybody help, please? -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 403 Error
On Tue, Jul 21, 2009 at 7:10 PM, Rodrigo Moraeswrote: On Tue, Jul 21, 2009 at 7:03 PM, Jeremy Truax wrote: I'm having it too, seems to be an old issue but unresolved: http://code.google.com/p/googleappengine/issues/detail?id=690 I just had this problem too some minutes ago, for the first time. I have only 2 versions, and in quota details it shows 24 of 250 deployments today - it's far under the allowed quota. I tried deleting version 2, and upload a new version 2 - got a 403. I tried creating a version 3 - got a 403. just an update. it fixed by itself after some time. or it was because of what I did: i deleted the version 2 in the admin panel, ran appcfg.py rollback and then deployed a new version number 3. not sure what is happening here or why i got the 403 previously, but well. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: key name (String) vs key id (long) performance
On Thu, Jun 11, 2009 at 2:19 PM, cryb wrote: Is there an official position / benchmark about what type of keys issue the best performance as for queries? Are key ids (long) being looked up faster than key names (string) - assuming that both have comparable sizes in bytes? There's no difference. Both key_name's and id's are used internally to build a Key from path, which is then used to get the entity. So, when you do Model.get_by_id(1) or Model.get_by_key_name('a'), you're actually doing Model.get(Key.from_path('Model', 1)) or Model.get(Key.from_path('Model', 'a')) - essentially the same thing. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: key name (String) vs key id (long) performance
On Thu, Jun 11, 2009 at 4:52 PM, cryb wrote: Hi Rodrigo.. Indeed, what you said is correct... however, bigtable internals can use different optimizations/lookup algorithms/key structure representation for different key types like key ids and key names (even if their logical structure appears to be identical)... Please note that I don't say it does, but I just want to make sure that both kind of keys behave the same in therms of lookup performance. Hi cryb, Someone asked this a while ago on irc. There's no difference. All get(key) have in theory the same lookup cost. Meaning that get_by_key_name() and get_by_id() have the same performance. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] When will we trust indexes?
Hi all, I'm facing an alarming, critical, impeditive issue migrating an app with a medium sized database to app engine. Serving indexes return disordered results, or return no results when they should return something. Working indexes stop to work properly, making the app run as if entities that are there are not. This obviously will potentially break all my data, in a way that I can't even know if it is broken - a disaster, or a maintenance nightmare. We deal with lots of restrictions and limits, and that's all fine for me. But how can we deal with datastore when it starts to return nothing for results that exist (and are supposed to be indexed), or return results in an order that makes no sense (again, indexed ones)? Inaccurate, broken indexes should never be serving. When can we expect this to be fixed? For reference, my issues: http://code.google.com/p/googleappengine/issues/detail?id=1670 http://groups.google.com/group/google-appengine/browse_thread/thread/66cd6fcfc228e43f And others: http://code.google.com/p/googleappengine/issues/detail?id=901 (medium priority) I am sorry if this sounds harsh. I'm very frustrated about this. thanks, -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: When will we trust indexes?
On Tue, Jun 9, 2009 at 8:13 PM, wrote: Just a note that all previous indexes that were broken by this bug should be fixed now, meaning they should be returning the expected results. Hi Jason, Thank you very much for the quick response. All my problematic indexes are all working fine now. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Index returning wrong results
Hi, I have an application returning wrongly ordered results. Only the entities returned after the related index started serving are correctly ordered, the rest makes no sense to me. I can give examples of entities that don't appear in the results for a given query, while they should at least come before other results that are there. I thought about dropping the index and rebuilding it, but the application isn't even live yet so maybe you could be interested to discover why this happened, if it is a bug and how to fix/avoid a wrong index serving in the future. Please let me know and I'll give you more info. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: How do I check for remainder in templates?
On May 29, 6:26 am, ogterran wrote: Hi, I want to create a row in my table for with 5 products in each row I tried to use the modulus with the forloop.counter but it doesn't seem to work {% for product in product_list %} {% ifequal forloop.counter%5 0 %}tr {% endifequal %} td{{ product.title }}/td {% ifequal forloop.counter%5 0 %}/tr {% endifequal %} {% endfor %} This won't help with Django templates, but I can't avoid pointing out that Jinja2 has by default a loop variable inside for [1]. You'd do something like: {% for product in product_list %} {% if loop.index == 5 %}tr {% endif %} td{{ product.title }}/td {% if loop.index == 5 %}/tr {% endif %} {% endfor %} It is a pretty useful feature. Sorry for the plug. :-/ -- rodrigo [1] http://jinja.pocoo.org/2/documentation/templates#list-of-control-structures --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Efficient paging using __key__ instead of a dedicated unique property [part 2]
Hi guys, I rewrote the pagination class originated from Ryan's idea [1]. In case you missed it, it supports efficient paging in any query, on any schema, purely in user land, without requiring extra properties or other schema changes. This means that no extra property is required for an index, and that you can have efficient pagination for any existing Model. The class wraps db.Query to build bookmarkable queries and resume from query bookmarks. A quick example of how to use it: # Get the encoded bookmark from request. bookmark = request.GET['bookmark'] # Build a paginated query. query = PagerQuery(ModelClass).filter('foo ', 'bar') \ .filter('baz =', 'ding') \ .order('foo') # Fetch results for the current page and bookmarks for previous and next # pages. prev, results, next = query.fetch(10, bookmark) # If 'prev' and/or 'next' are returned, use them to create links to the # previous and/or next pages. http://localhost:8080/?bookmark={{ prev }} http://localhost:8080/?bookmark={{ next }} And here is the code: http://bitbucket.org/moraes/appengine/src/4f7036301b52/pager.py let me know of any issues. :-) thanks, rodrigo moraes [1] http://google-appengine.googlegroups.com/web/efficient_paging_using_key_instead_of_a_dedicated_unique_property.txt --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: RuntimeWarning: Custom _query_class specified without corresponding custom _query_multi_class. Things will break if you use queries with the IN or != operators.
On Sat, May 2, 2009 at 6:48 PM, manuelaraoz wrote: Hey! I'm getting my app Logs filled with this error. RuntimeWarning: Custom _query_class specified without corresponding custom _query_multi_class. Things will break if you use queries with the IN or != operators. I don't know how to stop that or what causes it. By the way, I'm using the BookmarkQuery for efficient paging by Rodrigo Moraes that can be found here: http://bitbucket.org/moraes/appengine/src/422cc9b9473b/bookmark.py Hello Manuel, I revisited the pager class and decided to rewrite it from scratch at a higher level. The new version works much better, and does not extend google classes anymore; instead it wraps db.Query. Try it: http://bitbucket.org/moraes/appengine/src/tip/pager.py And let me know how can we improve it. :-) thanks, rodrigo moraes --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Announcing BDBDatastore, a replacement datastore for App Engine
I'm late on the topic, sorry. :-) Just tried BDBDatastore yesterday. A good reason to use it is to have a local/development datastore with better performance. The default one provided with the SDK performs very poorly with large datasets. BDBDatastore can do it much better, and so is very welcome. Neat project! -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Bulk Upload/Download for List and Unicode properties
On Thu, May 21, 2009 at 9:11 AM, Alex Popescu wrote: For lists, things sound even more complex. I must confess that I haven't tried it yet, but (I don't know why exactly) I believe that specifying 'list' as a conversion type will not be enough. Has anyone tried any of these scenarios and have any hints for me? You can create your own conversion function. You'd have to format the list as a string, and the conversion function takes that string and convert it to a list. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Bulk Upload/Download for List and Unicode properties
On Thu, May 21, 2009 at 9:29 AM, 风笑雪 kea...@gmail.com wrote: Change it to: for (name, converter), val in zip(self.__properties, values): if converter is bool and val.lower() in ('0', 'false', 'no'): val = False if isinstance(val,str) and not isinstance(val, unicode): val=unicode(val,'utf-8') This change is not needed. Instead of specifying str as converter, define a conversion function and use that instead: def convert_str(val): return unicode(val, 'utf-8') -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Shorthand to modify model-Objects?
I use a 'populate' method in a base model class. Slightly different from the previously posted function because it'll only update values of existing properties. def populate(self, **kargs): properties = self.properties() for key, value in kargs.iteritems(): if key in properties: setattr(self, key, value) I use it mostly to update an entity using data from a form. For example: entity = MyModel.get_by_key_name('my_key_name') entity.populate(**processed_form_data) entity.put() -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Role Based Access Control in GAE?
Hello pbr, I implemented a ACL system a couple of days ago, ported from a system I use in php. The idea is similar to what you described - access rules are defined for an user or can be grouped in roles. Users can have one or more roles, and individual access rules can override or extend these roles. Here's a quick paste: http://paste.pocoo.org/show/110555/ This is just a storage system and interface to check permissions. You need to tie it to the objects you want to restrict access (handlers and/or models) using decorators or other methods. Let me know if it helps or if you have ideas to improve it. -- rodrigo On Mar 29, 1:16 am, wrote: 1) I have a simple application that can be accessed by multiple users 2) The users are combined into groups (overlapping is possible) 3) Privileges (read/write/delete) are assigned to groups 4) Groups are then assigned to view/edit data I have started to build out this functionality by creating Users, Groups, Privileges models and then setting up pseudo-foreign key relationships to them. (As you can see, I can from the relational world). Before I continue down this implementation path, I thought I'd see if there was something already out there that did this or if there is a better way. Any advice or pointers to other resources would be greatly appreciated. Thanks. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Efficient paging using __key__ instead of a dedicated unique property
hey there, just an update: a working version of the query class with built in pagination is available at: http://bitbucket.org/moraes/appengine/src/tip/bookmark.py let me know what you think. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: I18N, translation
On Thu, Jan 29, 2009 at 2:34 PM, Mel T. wrote: What is gae's team official statement about support for localized application? Does GAE support it or not ? Are we supposed to develop our own localization solution? hey Mel, please check http://babel.edgewall.org/ - it is a standalone package that provides full i18n support. well documented, easy to implemented, etc. it is the way to go, imo. (sorry, not official, just a practical statement) cheers, rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: How to list the files in a static directory?
On Sun, Jan 25, 2009 at 2:00 PM, KillIEbrowser wrote: I'm thinking to put the static files into the templates folder: open http://shell.appspot.com/ type: import os os.listdir(templates) by static files i mean those files declared static in app.yaml, independently of the file type. those *can't* be accessed by the app. templates are not declared static. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Having a strange problem viewing my app
On Tue, Jan 20, 2009 at 1:20 PM, csellengoapplikacio wrote: When after some time of inactivity I load one page of the application, it displays nothing. After a reload it does display correctly. ... does anybody have some idea what could this be? this is a really common issue and should be added to the FAQ if it is not there already (sorry, i didn't check). it is caused when you don't check if your main app file is being accessed directly, as in if __name__ == '__main__' in the code below: application = ... def main(): run_wsgi_app(application) if __name__ == '__main__': main() do the above and you'll be happy. :) -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Having a strange problem viewing my app
On Tue, Jan 20, 2009 at 3:52 PM, Rodrigo Moraes wrote: this is a really common issue and should be added to the FAQ if it is not there already (sorry, i didn't check). uh, an update. it is in the FAQ [1]. see: Q: The first time I load my application, it is blank. After that it works fine. What is wrong? A: This is due to the way that App Engine handles app caching. To fix it, simply include this at the bottom of your file: if __name__ == __main__: main() [1] http://knol.google.com/k/marce/app-engine-community-faqs/vkzeph4si12v/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 500 server error
On Fri, Jan 9, 2009 at 5:04 PM, adelevie wrote: I have one app right now http://wepaste.appspot.com. I know how to create and upload apps. However, today, I cannot even upload a hello world even though the app works perfectly on dev_appserver. appcfg.py runs fine but when I visit the URL, I get a 500 server error. which error appears in the log? -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: http://carpoolfinder.appspot.com/ won't work now and svn update fails
On Thu, Jan 8, 2009 at 6:05 AM, thebrianschott wrote: Using logging.info() I have determined that the appspot is always return None for user=users.get_current_user() and that is why the app is working differently at appspot that locally. I have tried to make this a single transaction to allow the value of user to be determined in a timely way, but either I am doing it wrong, or it does not work. Please advise. you don't need a transaction for that. actually, it seems that you got completely wrong what transactions are for. what you need is to add a link so that users can login and then, after login, you will be able to get the current user inside your app. in your app: template_values = {} template_values['login_url'] = users.get_login_url() in your template: a href={{ login_url }}login here, buddy!/a that's it, simple as that. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: OSX Leopard NotImplementedError: Unable to find the Python PIL library.
On Thu, Jan 8, 2009 at 7:11 AM, PatHaugen wrote: Anyone get this to cleanly work as documented by Google? not me. this is how i got it working: http://appengine-cookbook.appspot.com/recipe/install-pil-in-mac-os-x -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 2 reference to same model causing problem
On Wed, Jan 7, 2009 at 1:54 PM, james...@163.com wrote: class webdir(db.model): name = db.StringProperty() class webcontain(db.model): dirA = db.ReferenceProperty(webdir) dirB = db.ReferenceProperty(webdir) when you have two references to entities of the same kind, you need to define collection_name, or the collection names will collide. this should fix your problem: class webcontain(db.model): dirA = db.ReferenceProperty(webdir) dirB = db.ReferenceProperty(webdir, collection_name=something_else) -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Zip Importer High CPU every request
On Wed, Jan 7, 2009 at 2:16 PM, Anthony wrote: Is it normal for the zipimporter to take 500-1000ms every request - should it be caching internally? I'm importing like so: # templates.py sys.path.insert(0, 'lib/jinja2.zip') from jinja2 import Environment, FunctionLoader , TemplateNotFound , MemcachedBytecodeCache Will it still be caching if im not importing the zip dircetly in the main.py? Not an answer to your question (which I'd like to know :), just a warning: you won't be able to use MemcachedBytecodeCache from Jinja2, because bytecode usage is not allowed in App Engine. The example using MemcachedBytecodeCache in the App Engine Cookbook only works in the dev server, not in production. :-/ Apart from this, Jinja2 implementation is very smooth. :) -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Django Templates Usage
On Wed, Jan 7, 2009 at 6:25 PM, MajorProgamming wrote: This all worked well when my pages looked like http://example.com/ apage, where the relative pointers to the images directory would resolve well. However, I am now creating pages that look like http:// example.com/adir/apage, and my relative URLs are breaking! The problem is that I can't just change the base.html template, because the my http://example.com/apage; URLs would break. Is there any way to handle this using django? (Also, I would rather not use absolute URLs) Not sure if i understood the problem, but I'm guessing you should just standardize to use relative url's based on the root, in other words, always start relative url's with / and provide the full path. This will avoid lots of headaches. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Error returned on images in static dir
hey tijer, For the record, I saw this happening yesterday too - a single jpg file in the static dir wasn't loading, and when i tried to access it directly I got a 500 error. I updated the app a couple of times, and the same happened. The static file only loaded after i removed the image from the app, updated the app, re-added the image and updated again - as reported. As it affected a single image and was solved more or less easily I did not care too much, but I thought you'd like to know that more people saw this. :) -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: entity.populate()
On Sat, Jan 3, 2009 at 3:55 PM, gops wrote: i am using your code , thats easy and cool!! thanks. cool. i created a feature request for it. star if you think it is worth: http://code.google.com/p/googleappengine/issues/detail?id=968 thanks, rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Working with mappings
On Sat, Jan 3, 2009 at 10:02 PM, MajorProgamming wrote: Firstly, Do these mappings also support regular expression mappings? They *are* regular expressions. That's how those expressions are evaluated. Secondly, How can I use dynamic mappings (like instead of http://example.com/article?id=20 -- http://example.com/article/20)? ('/article/([\d]+)', Article) With the above rule, the matched values are passed to the handler, in order. So in Article you'll have the method get(self, article_id), which receives the article id from the matched rule. [and is there any advantage to doing query strings in this fashion?] Well, sometimes query strings are more convenient, but in many times you would want to certify that only url's with minimally valid parameters (in the above example, an integer) will match. With ?id=20, you'll have to check if an id is passed in the handler method, *after* the dispatch process. It's also a matter of aesthetics and, most important, how your handlers are organized. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Working with mappings
On Sat, Jan 3, 2009 at 11:16 PM, MajorProgamming wrote: What's passed to the article_id parameter? The digits extracted from the matched url - using the rule regexp as below: ('/article/([\d]+)', Article) How does GAE know what to pass? It simply passes all values captured by the regexp. Your handler method will receive as many values as the regex captures. Take a look at google.appengine.ext.webapp.__init__.py: the magic happens in WSGIApplication.__call__ For a bit more sophisticated / flexible routing mechanisms, see Routes or Werkzeug's routing: http://routes.groovie.org/ http://werkzeug.pocoo.org/documentation/routing -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: How to query through multiple models?
On Fri, Jan 2, 2009 at 9:25 AM, djidjadji wrote: parents = db.get([Entity.parent.get_value_for_datastore(entity) for entity in result]) Is more efficient because you only do 1 call to the datastore, for multiple objects. Awesome... I thought it was not possible to get the key from a ReferenceProperty without fetching the related entity. This is a nice trick. :-) -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] entity.populate()
Hey, I am missing a way to populate an entity with data from a dict (or a list of tuples with key/value). We can do this with new entities: entity = ModelFoo(**data) ... but how about existing entities? Wouldn't a populate() (or load(), or call it a better name :-) Something like: entity = ModelFoo.get_by_id(id) entity.populate(data) It's pretty simple, and I am wondering if it would not be worth to have in Molel: def populate(self, data): properties = self.properties() for key, value in data.iteritems(): if key in properties: setattr(self, key, value) ... or: maybe I am missing a feature that already exists? thank you, rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: why java
On Wed, Dec 31, 2008 at 2:09 PM, Xavier Mathews wrote: There Are So many Javas Out there to learn that its really up to the user! Python is not really used anymore. But its nice to still know it! What do you mean by Python is not really used anymore? -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Trying to understand model keys a little better
On Wed, Dec 31, 2008 at 5:21 PM, Ryan W wrote: If you have the key, why not just use the stringified version of it directly instead of constructing the key from its Id? Maybe you would want to check if the key is valid - I think Key will throw an exception if it is not. Apart that, it is cleaner and exact the same to use the stringfied version - if you have it. Constructing it from path may be useful in some cases when you have known ancestors - remember that id is only unique for the same ancestor. Anyway, sometimes it makes sense to build a key programaticaly - normally not. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Efficient paging using __key__ instead of a dedicated unique property
On Wed, Dec 17, 2008 at 4:33 AM, Thomas Johansson wrote: ryan: We really *really* need some kind of pagination built-in though, it has to be said. It is more or less the number one constraint for everybody I've talked to, and something we all need in one way or another. The other constraints can be worked around with relative ease, but pagination is smack in your face for even the simplest stuff; And as you clearly demonstrate with the above, not exactly trivial to implement efficiently, not to mention in a scalable manner. I totally agree with this. #1 constraint for me. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: IP to location in GAE
On Sat, Dec 6, 2008 at 8:45 AM, yejun wrote: Google ajax api has city level ip lookup. yep, take a look here: http://googleajaxsearchapi.blogspot.com/2008/08/where-is-my-current-user.html ... and avoid the headache to maintain such data. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Setting the HTTP status code without webapp
On Sat, Nov 22, 2008 at 9:50 PM, robertpogue [EMAIL PROTECTED] wrote: For illustrative purposes, what would a Hello World app that returned a status code of 500 look like? you should set the status code in the response object. in a webapp: self.response.set_status(500) that's the easy way, you only need to pass the code. webapp will send the status message for you. but you can also do: self.response.set_status(500, 'Internal Server Error') -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Setting the HTTP status code without webapp
duh, how i missed the without webapp part of the subject? reformulating, without webapp you'd need to pass the status code and message in the response header, together with other headers, and not in the body as you did. a response object is advised, and you can use the one from WebOb which is simple enough. take a look at google.webapp.ext.webapp.__init__ (in Response.wsgi_write()) to see how it does it. hope this helps. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Add Model field via Mixin?
On Mon, Nov 17, 2008 at 2:56 PM, Adam wrote: I tried declaring Commentable to inherit from db.Model, but that didn't seem to make a difference. take a look at this project, which is a mixin class for tags: http://code.google.com/p/taggable-mixin/ it requires that you define __init__() for the class that extends the mixin class. not sure if it would make any difference for you, but let me know. :) -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] pagination, again
hey, from the I/O Session [1] i can see how to create pagination based on indexes that doesn't rely on database offsets. but the example is plain simple and I am intrigued in how to do some more complex pagination in a app-engine way. in the I/O Session example, you fetch 1 extra record to know if you have a next page, and based on that and the current page's pagination data, you can create previous or next links. now, what if we want to create a pager with links to a range of pages (the common pager we use everywhere: previous 1 2 3 4 next )? to know how many items we have to paginate we can set a sharded counter (using the awesome class from our fellows here :), but how to fetch the data related to the requested page in a consistent way? or, better, how to keep the index consistent? let's say i'm displaying 20 items per page, so have the links: * page 2: /my-page?start=20 * page 3: /my-page?start=40 * etc. now, if I delete items 23, 24 and 25, my page 2 will have 17 items instead of 20. to avoid this, I'd have to rebuild the index when items are removed, which is undesired. do you have other ideas? i'd want to keep it efficient and relativelly simple, and maybe i'm just trying to do what i should not try to do. what do you think? -- rodrigo [1] http://sites.google.com/site/io/building-scalable-web-applications-with-google-app-engine --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Querying Ascending, Listing Descending
On Wed, Nov 12, 2008 at 5:23 PM, sternr wrote: Is it possible to start looping the query object from the end (so the listing would be in ascending order)? hmmm, not sure if i understood the problem, but maybe you just want to sort the results after the fetch()? the result is simply a list, so it you can use list methods to sort it. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Using ANCESTOR IS to improve datastore performance?
On Mon, Nov 10, 2008 at 8:23 AM, heavyz wrote: 2. Because the ancestor relationship also establishes a one-to-many relationship, should I remove CommentOnFoo's foo property (ReferenceProperty to Foo)? I think it's redundant. since you define Foo as parent of CommentOnFoo, it'd be redundant indeed to have it as a property. regarding performance, the docs says: Entity groups do not have a significant impact on the speed of queries., but improve the performance of creating and updating data. [1] [1] http://code.google.com/appengine/docs/datastore/keysandentitygroups.html#Entity_Groups_Ancestors_and_Paths -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Getting host of application..?
On Mon, Nov 10, 2008 at 8:24 PM, jago wrote: in my case os.environ['SERVER_NAME'] return only 'localhost', which does not work. use self.request.uri -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Getting host of application..?
On Mon, Nov 10, 2008 at 7:13 PM, jago wrote: With self.request.url I have the current host + path. Is there a clean way to only get the host without splitting strings? oh, sorry, i missed this message. you can pass self.request.uri to urlparse(), and get the components you want: http://www.python.org/doc/2.5.2/lib/module-urlparse.html -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] localization recipe
hey. anyone has a recipe to implement localization in webapp? i created gettext files using django-admin.py makemessages / compilemessages. now i was looking at django utils/translation but the infrastructure to display locale strings seems too specific and with tons of dependencies, and I am not using django. do we have a more simple solution? -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] ImportError: No module named foo.bar
sometimes i get a ImportError: No module named foo.bar, although the module is there. then i restart the server and the module is loaded normally (the error goes away). does this occur with you? is there a way to avoid this? -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: App engine on mac eclipse
On Sun, Nov 9, 2008 at 10:08 PM, ohayo wrote: I am not sure if the app engine is available to developers any more. However I downloaded from google site - app engine sdk. i donot see any libraries to link to in eclipse. does the sdk come with the libraries. i am only able to see launcher. i am not sure where the libraries are placed by default, but you could use finder to look for one of the framework files, for example djangoforms.py, do discover the location of the libraries. hope this helps. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: validation of GET/POST data in URL handlers
On Sat, Nov 8, 2008 at 1:27 PM, adrian wrote: Not a helpful comment.If what you said were true, why is there an AppEngine Helper for Django? Obviously there are some issues. you'll have some issues using a django app as it is because it initializes stuff that won't work inside app engine. AppEngineHelperForDjango tries to make it smooth by removing/overriding those unsupported stuff. you can very well import just the django modules for form generation/validation and use them; they are independent enough to be used without the whole django, afaik. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Purchased domain via Google Apps. How to host my appengine app on this domain?
On Sat, Nov 8, 2008 at 12:02 AM, jago wrote: At least from my tests so far Google Apps does not allow me to host the AppEngine app directly on www.example.com but enforces me to define a subdomain. Am I wrong? yes. there are many app engine apps out there using a www subdomain. this is perfectly possible. and since we are on this, anybody knows the technical reasons why it is not possible to have a *.domain.com pointing to a app in app engine? i tried a silly workaround, pointing www.domain.com to google, and then pointing *.domain.com to www.domain.com, but it didn't work. silly because afaik it is not possible to point wildcard subdomains to cnames. :-P do you think this will be possible anytime in the future? i wanted to setup an app using user1.domain.com, user2.domain.com etc, like others here (see issue #113: http://code.google.com/p/googleappengine/issues/detail?id=113) -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Purchased domain via Google Apps. How to host my appengine app on this domain?
On Sat, Nov 8, 2008 at 12:20 AM, jago wrote: let me rephrase my question: Is it possible if I purchased www.example.com from Google to directly make my AppEngine app accessible if people type in there URL field: www.example.com ? However they should not be re-directed to www.myapp.example.com but directly stay at www.example.com where the AppEngine app is. Is this possible? How? set the domain you want to point in the service settings for the the app, as described here: http://www.google.com/support/a/bin/answer.py?hl=enanswer=91080 -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Google App Engine Roadmap - Now Published
On Mon, Nov 3, 2008 at 8:14 PM, johnP wrote: There is still a significant amount of development ahead. If it appears that my task is a non-starter for Appengine, I'd prefer to switch to pure django earlier rather than later. Can anyone provide some enlightenment for my dilemma? Thanks. I think this is a common concern. I don't want my app offline because I'm exceeding limits. Instead, I'd like to pay to be allowed to exceed limits - and it is on Google plans to give us this option (from the roadmap: Billing: developers can pay for more resource usage). I have great expectations and I'm waiting for it. -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Datastore Entity
On Oct 25, 2:49 am, yejun wrote: Actually, you still need to supply a empty dict object anykind = type(KindName, (db.Expando,), dict()) obj1 = anykind() obj1.put() Here anykind is just a variable name, it is not necessary to match KindName, but KindName is the name used for datastore. hey, interesting stuff here. couple of questions: 1. is there a way to retrieve a list of kinds used by an app, or we need to keep track of them? 2. i have a case where about 300 users have entity collections from various models. these collections vary in size from 10 to 10 thousand records, depending on the user. i don't need to fetch data from all users at any point. so, from a performance perspective, is it better to give each user its own kind (say user1_kindname, user2_kindname etc), and fetch directly from them depending on the user, or it doesn't matter and i can just use a single kind for each model, plus a reference property to the user? hope this makes sense. :-) thanks, -- rodrigo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---