Thanks! both already read! but my the initial approach was divide the mail handlers into three different classes for better readability, so the LogSenderMapper isn't useful. I wanted to do this (as said in docs):
- url: /_ah/mail/owner@.*app-id\.appspotmail\.com script: handle_owner.py login: admin - url: /_ah/mail/support@.*app-id\.appspotmail\.com script: handle_support.py login: admin - url: /_ah/mail/.+ script: handle_catchall.py login: admin but in the .py handlers, so that was when the problem arrived. To have several handlers for a specific e-mail (I want explicity ignore the rest addresses) in the same file is a bit hacky =) Anyway, thanks for reading the message! On 25 feb, 05:37, Robert Kluin <robert.kl...@gmail.com> wrote: > Hi Ernesto, > Hard-coding an email adress into the URL seems like a > less-than-ideal design. You might want to read about 'query strings' > and / or POST parameters (variables). At hte minimum take a look at > the 'URL Mappings' section of the webapp 'Running the Application' > doc: > http://code.google.com/appengine/docs/python/tools/webapp/running.html > > Also, I would strongly encourage you to read the docs on receiving email: > http://code.google.com/appengine/docs/python/mail/receivingmail.html > > Robert > > On Thu, Feb 24, 2011 at 17:09, Ernesto Karim Oltra > > > > > > > > <ernestoka...@gmail.com> wrote: > > I've found the solution my way. =) Google App Engine don't call > > "str...@appid.appspot.com", but "string%40appid.appspot.com", at least > > in SDK. I will have to test it in production too. > > > On 24 feb, 22:39, Ernesto Karim Oltra <ernestoka...@gmail.com> wrote: > >> Hi, I was trying to match a handler to a URL, so I'm using this code: > > >> class HomeworkSendMail(webapp.RequestHandler): > >> PATH = '/_ah/mail/sendhm@appid\.appspotmail\.com' > > >> def post(self): > >> logging.debug('reached!') > > >> URLMAP = [ > >> (HomeworkSendMail.PATH + '/?', HomeworkSendMail), > >> ] > > >> def main(): > >> logging.error('main!') > >> application = webapp.WSGIApplication(URLMAP, debug = config.DEBUG) > >> run_wsgi_app(application) > > >> In the logs "main!" appear, so I'm sure app.yaml points to the correct > >> python script. But the problem is the "@" in "sendhm@appid...". When I > >> replace "@" with ".+" it works perfectly. I've tried it in the python > >> shell with "@", and works well too, but not in app engine. > > >> What I'm doing wrong? > > > -- > > 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 > > athttp://groups.google.com/group/google-appengine?hl=en. -- 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.