[google-appengine] Longest Common Sub sequence
Hi I am using google app engine with python and I am trying to implement parallel lcs with task queue api the problem is i dont know how to use task queue api dose taskqueue.add function returns any result because my parallel function return results also i dont konw whst to put in the URL argument in taskqueue.add(url=' ') please i need help 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] Parallel python with google app engine
Hi I am using python with google app engine and i am trying to use parallel python(pp.py) library in my application i first program my application without google app engine and it worked perfect but when i used it with google app engine a error messge display This is the error messge: Traceback (most recent call last): File C:\Program Files\Google\google_appengine\google\appengine\ext\webapp\__init__.py, line 513, in __call__ handler.post(*groups) File C:\Users\tota\Documents\master\selected topecs\project\lcs-website\lcs-website\main.py, line 35, in post Matching.r3 =' '.join(m.main(self.request.get('dna1'),self.request.get('dna2'))) File C:\Users\tota\Documents\master\selected topecs\project\lcs-website\lcs-website\m.py, line 36, in main job_server = pp.Server(ppservers=ppservers) File C:\Users\tota\Documents\master\selected topecs\project\lcs-website\lcs-website\pp.py, line 343, in __init__ self.set_ncpus(ncpus) File C:\Users\tota\Documents\master\selected topecs\project\lcs-website\lcs-website\pp.py, line 503, in set_ncpus range(ncpus - len(self.__workers))]) File C:\Users\tota\Documents\master\selected topecs\project\lcs-website\lcs-website\pp.py, line 148, in __init__ self.start() File C:\Users\tota\Documents\master\selected topecs\project\lcs-website\lcs-website\pp.py, line 153, in start proc = subprocess.Popen(self.command, stdin=subprocess.PIPE, \ AttributeError: 'module' object has no attribute 'Popen' how could i solve this problem 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] The links in my application navigate me to an empty page
Hi every one I am using python in google app engine application and i am inserting html in python as templates. I have multiple pages and i have problem in the links for example i am in index page when i click any link to navigate to any other page it display an empty page without anything in it can you please tell me what is the problem 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.
Re: [google-appengine] Re: The links in my application navigate me to an empty page
Thanks Ernesto I solved my problem i was stuck in this problem for 5 hours and finally found that i forget to add something stupid I have in the main.py this: def main(): application = webapp.WSGIApplication([('/', MainHandler)],debug=True) and i should write it this way: def main(): application = webapp.WSGIApplication([('/.*', MainHandler)],debug=True) because in the app.yaml i have: handlers: - url: /.* script: main.py Thanks for replaying 2011/1/25 Ernesto Karim Oltra ernestoka...@gmail.com The problem isn't the links. The problem is the page. Have you seen your logs searching for 403/404 (Page not found, etc.) errors? Use some tool like Firebug or the Developer Tools of Chrome to see what code the server returns so yo can address more precisely the source of your error (or give a URL of your page where the error occurs and I'll see it) On 25 ene, 01:53, fatimah mujallid f.mujal...@gmail.com wrote: Hi every one I am using python in google app engine application and i am inserting html in python as templates. I have multiple pages and i have problem in the links for example i am in index page when i click any link to navigate to any other page it display an empty page without anything in it can you please tell me what is the problem 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.comgoogle-appengine%2bunsubscr...@googlegroups.com . For more options, visit this group at http://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.
Re: [google-appengine] Re: how can i write Arabic in app engine
Finally it works perfect Thank you all for replying and you support 2010/12/17 Geoffrey Spear geoffsp...@gmail.com You're just encoding the filename in utf-8 (which is identical to its ASCII encoding as it doesn't comain non-ASCII characters) and then passing that encoded filename to django's template engine.) On Dec 16, 5:11 pm, fatimah mujallid f.mujal...@gmail.com wrote: Ok this code works great: self.response.out.write(u' السلام عليكم'.encode('utf-8')) but when i use an html page instead of a string just like this: self.response.out.write(template.render(u'test.html'.encode('utf-8'))) it displays arabic characters rabish in the html page i tried to write this: meta http-equiv=Content-Type content=text/html; charset=utf-8 and tried with out it both displays arabic characters rabish 2010/12/17 fatimah mujallid f.mujal...@gmail.com Ok this code works great: self.response.out.write(u'السلام عليكم'.encode('utf-8')) but when i use an html page instead of a string just like this: self.response.out.write(template.render(u'test.html'.encode('utf-8'))) it displays arabic characters rabish in the html page i tried to write this: meta http-equiv=Content-Type content=text/html; charset=utf-8 and tried with out it arabic characters rabish both displays 2010/12/16 风笑雪 kea...@gmail.com I suggest you always use UTF-8, not windows-1256. However, if you insist on using windows-1256, you should encode your unicode output to str: self.response.out.write(u'some unicode string'.*encode*('windows-1256')) or: self.response.out.write('some windows-1256 string') # don't decode it -- keakon My blog(Chinese):www.keakon.net Blog source code:https://bitbucket.org/keakon/doodle/ -- 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.comgoogle-appengine%2bunsubscr...@googlegroups.comgoogle-appengine%2Bunsubscrib e...@googlegroups.com . For more options, visit this group at http://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-appeng...@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.comgoogle-appengine%2bunsubscr...@googlegroups.com . For more options, visit this group at http://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-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] how can i write Arabic in app engine
Ok this code works great: self.response.out.write(u'السلام عليكم'.encode('utf-8')) but when i use an html page instead of a string just like this: self.response.out.write(template.render(u'test.html'.encode('utf-8'))) it displays arabic characters rabish in the html page i tried to write this: meta http-equiv=Content-Type content=text/html; charset=utf-8 and tried with out it arabic characters rabish both displays 2010/12/16 风笑雪 kea...@gmail.com I suggest you always use UTF-8, not windows-1256. However, if you insist on using windows-1256, you should encode your unicode output to str: self.response.out.write(u'some unicode string'.*encode*('windows-1256')) or: self.response.out.write('some windows-1256 string') # don't decode it -- keakon My blog(Chinese): www.keakon.net Blog source code: https://bitbucket.org/keakon/doodle/ -- 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.comgoogle-appengine%2bunsubscr...@googlegroups.com . For more options, visit this group at http://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-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] how can i write Arabic in app engine
Ok this code works great: self.response.out.write(u' السلام عليكم'.encode('utf-8')) but when i use an html page instead of a string just like this: self.response.out.write(template.render(u'test.html'.encode('utf-8'))) it displays arabic characters rabish in the html page i tried to write this: meta http-equiv=Content-Type content=text/html; charset=utf-8 and tried with out it both displays arabic characters rabish 2010/12/17 fatimah mujallid f.mujal...@gmail.com Ok this code works great: self.response.out.write(u'السلام عليكم'.encode('utf-8')) but when i use an html page instead of a string just like this: self.response.out.write(template.render(u'test.html'.encode('utf-8'))) it displays arabic characters rabish in the html page i tried to write this: meta http-equiv=Content-Type content=text/html; charset=utf-8 and tried with out it arabic characters rabish both displays 2010/12/16 风笑雪 kea...@gmail.com I suggest you always use UTF-8, not windows-1256. However, if you insist on using windows-1256, you should encode your unicode output to str: self.response.out.write(u'some unicode string'.*encode*('windows-1256')) or: self.response.out.write('some windows-1256 string') # don't decode it -- keakon My blog(Chinese): www.keakon.net Blog source code: https://bitbucket.org/keakon/doodle/ -- 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.comgoogle-appengine%2bunsubscr...@googlegroups.com . For more options, visit this group at http://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-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] how can i write Arabic in app engine
Hi,thank you for your replay I have this code in main.py class Whatisinyourmind (db.Model): name=db.StringProperty() yourword=db.StringProperty() class MainHandler(webapp.RequestHandler): def get(self): yourwords=db.GqlQuery('SELECT * FROM Whatisinyourmind') values={'yourwords':yourwords} self.response.out.write(template.render('main.html',values).decode('windows-1256')) def post(self): whatisinyourmind=Whatisinyourmind() nameTemp=self.request.get('name') #nameTemp=unicode(nameTemp,'windows-1256') whatisinyourmind.name=nameTemp temp=self.request.get('yourword') #temp=unicode(temp,'windows-1256') whatisinyourmind.yourword=temp whatisinyourmind.put() self.redirect('/') --- you can see from the above code i used decode() to display any Arabic characters and it display will EXCEPT the Arabic characters that i retrieve it from the database it display garbish The code in main.html are -- html head meta http-equiv=Content-Type content=text/html; charset=windows-1256 titleUntitled Page/title /head body h1ماذا يدور في عقلك؟/h1 form action= method=post accept-charset=windows-1256 {% for yourword in yourwords %} div{{yourword.name}}/ div{{yourword.yourword}}/ {% endfor %} br labelالإسم الكريم: /label input id=name type=text name=name/ labelالكلمة:/label input id=yourword type=text name=yourword/ input id=button1 type=submit value=Post / /form /body /html -- thanks again 2010/12/15 风笑雪 kea...@gmail.com Hi, I don't know what framework are your using. Generally speaking, you should set Content-Type:text/html; charset=UTF-8 header, and make sure you output UTF-8 encoded sting. If you are using webapp, it will look like this: self.response.headers['Content-Type'] = 'Content-Type:text/html; charset=UTF-8' self.response.out.write(u'something in Arabic'.encode('utf-8')) -- keakon My blog(Chinese): www.keakon.net Blog source code: https://bitbucket.org/keakon/doodle/ -- 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.comgoogle-appengine%2bunsubscr...@googlegroups.com . For more options, visit this group at http://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-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.