google-app-engine

GAE change field name/attribute

Is it possiible to change attribute name on db.Model kind? i have some field name created with dash (e.g. field-name) that resulting error. class DataBulk(db.Model): group_id = db.IntegerProperty() group_name = db.StringProperty() geo_pos = db.GeoPtProperty() group-leader = db.StringProperty() <-----------error impo...

How to make integration test for DB at google App. engine?

Hi overflowed. I'am wondering, how to write integration tests, that involves DB interaction, for Google app engine? It's seems - no problem to run this test at Google, on "live" db, using GAEUnit SO Thread But, this seems bad practice to me, because it's live environment. Google has provided examples of such tests, for java, but not fo...

Parsing HTML easily like PyQuery in Python 2.5

I am writing an app for GAE (Python 2.5) and I was wondering if there is any library like PyQuery (which runs on Python 2.6+). All I have to do is to load an HTML file and get the content of a especific tag through its ID. In PyQuery, or even Python2.6's libraries like lxml, it is very easy, but I don't know how to do that with Python 2...

Java Query for Dates not working out?

hello i am using google app engine and using its database i am trying to retrive the data and make a query and only search for the dates or times i want. so if i want all the input dates off September 09, then it will give me the list of all the september dates. PersistenceManager pm = PMF.get().getPersistenceManager(); List rul...

Google App Engine w/ Django - InboundMailHandler appears to only work once

I'm writing an app for Google App Engine (with Python and Django) that needs to receive email and add some elements of the received email messages to a datastore. I am a very novice programmer. The problem is that the script I specify to handle incoming email appears to only run once (until the script is touched). Sending a test email ...

How to send an e-mail from a Python script that is being run on "Google App Engine"?

Hi All!!! How could I send an e-mail from my Python script that is being run on "Google App Engines" to one of my mail boxes? I am just a beginner and I have never tried sending a message from a Python script. I have found this script (IN THIS TUTORIAL): Here is the same script as a quote: import sys, smtplib fromaddr = raw_inp...

WebTest: Testing with decorators + datastore calls

Hello, I have a Google App Engine application and my request hadnler has a decorator that does authentication. With WebTest I found out yesterday how you can set a logged in user and administrator. Now today my authentication decorator got a little more complex. It's also checking if a user has a profile in the database and if he doesn...

GAE Datastore - Is there a next page / Are there x+1 entities?

Hi. Currently, to determine whether or not there is a next page of entities I'm using the following code: q = Entity.all().fetch(10) cursor = q.cursor() extra = q.fetch(1) has_next_page = False if extra: has_next_page = True However, this is very expensive in terms of the time it takes to execute the 'extra' query. I need to extra...

google-app-engine-django loading fixtures

I'm having troubles loading fixtures on GAE with google-app-engine-django. I receive an error that says "DeserializationError: Invalid model identifier: 'fcl.User'" ./manage.py loaddata users I'm trying to load a fixture that has the following data: - model: fcl.User fields: firstname: test lastname:...

Outbound FTP request from google appengine using python.

Hi All, I need to make an outbound ftp request to retrieve a number of small files. There are 6 files each less than 10K and I only need to retrieve them once every couple of hours. When I try to do this with urllib2.urlopen("ftp://xxx.xxx.xxx") I get an exception AttributeError: 'module' object has no attribute 'FTP_PORT'. I have r...

GAE Query counter (+1000)

How to implement this query counter into existing class? The main purpose is i have datastore model of members with more than 3000 records. I just want to count its total record, and found this on app engine cookbook: def query_counter (q, cursor=None, limit=500): if cursor: q.with_cursor (cursor) count = q.count (limit=...

django dynamic translate on AppEngine

Hi, I need dynamic translation in django on AppEngine. I found nice django modul for dynamic translations: django-rosetta, but it open files (django.po...) and it is not allowed on AppEngine. Exist some other translate modul where is compatibile (or with small fix) with AppEngine? Thanks. Martin ...

XMPP bot status message on GAE

Hi , GAE XMPP documentation states that is not possible to set status message for an app ( https://code.google.com/appengine/docs/python/xmpp/overview.html#Google_Talk_User_Status ). On other hand, I've vark IM client has status message set. Obviously it is not hosted on GAE, but it is possible to set status message for app. I hav...

What do I need to know about JRuby on Rails after developing RoR Apps?

I have done a few projects using Ruby on Rails. I am going to use JRuby on Rails and hosting it on GAE. In that case what are the stuff that I need to know while developing JRuby apps. I read that JRuby has the same syntax I can access Java libraries JRuby does not have access to some gems/plugins JRuby app would take some time to load...

Sys.path modification or more complex issue?

Hi, I have problems with importing correctly a module on appengine. My app generally uses django with app-engine-patch, but this part is task queues using only the webapp framework. I need to import django settings for the app to work properly. My script starts with: import os import sys sys.path.append('common/') # Force Django to r...

Google app engine static jsp files

Hi, I am building an application on GAE and let's say I just want a plain about page for the application. The about.jsp file should or should not have an servlet class? in in web.xml I have something like <servlet> <servlet-name>application</servlet-name> <servlet-class>application.applicationServlet</servlet-class> </servlet>...

Google App Engine self.redirect() POST method

Hi! In GAE (Python), using the webApp Framework, calling self.redirect('some_url') redirects the user to that URL via the GET method. Is it possible to do a (redirect) via the POST method with some parameters as well? If possible, how? Thanks! ...

function call after the deployement of the app

Hello, I wanna know if there is a function that is called directly after the deployment of the server. This functions could be called as an initialisation function of the deployment. Thanks ...

Google App Engine, JDO, use Date in filter

Hi. In my application, I would like to fetch a set of entities from the Datastore, that have a Date field set to a date before the present moment. I do realize, that one of the ways of doing that is by simply storing the date in those entities as just a long value in milliseconds. But ist there actually a way of storing them as Dates...

GChart on GAE wont show

I am using Eclipse with GAE on a MacBook Pro with GChart. My problem is that I cant get any chart to show when I am developing, but when I use regular tools such as Buttons or Labels with GAE they work just fine. The code doesn't give me any errors, so I am assuming that I have the right code: public class TestingTesting implements Ent...