Skip to content


Subversion checkout URL

You can clone with
Download ZIP


asyncGet method for HTTPRequest does not accept content_type argument #398

pyjsorg opened this Issue · 1 comment

1 participant


What steps will reproduce the problem?
1. Install revision 2212 or earlier
2. Create an instance of HTTPRequest and attempt to set the content_type as

HTTPRequest().asyncGet(url = url, handler = myHandler(self), content_type =
3. Use pyjsbuild to compile and then attempt run the generated code.

What is the expected output?

A successful invocation of a GET to the URL with Content-Type set to

What do you see instead?

Since the asyncGet() method does not accept a content_type argument you
will get an error.

What version of Pyjamas are you using? which svn revision number?

Revision 2212

On what operating system?

-bash-3.2$ uname -srvpo
Linux 2.6.18-xen #1 SMP Fri May 18 16:01:42 BST 2007 x86_64 GNU/Linux
-bash-3.2$ cat /etc/issue
CentOS release 5.2 (Final)
Kernel \r on an \m

If using PyJS, have you attached a javascript stack trace,
from IE's Script Debugger or from Firefox Venkman / Firebug?

No, the method simply does not accept the option.

Have you attached a stack trace from using "-d" compiler option?

No, the method simply does not accept the option.

If using PyJS, what compiler options did you use?


Please provide any additional information below.

See attached SVN diff for a patch that adds the content_type argument to
asyncGet() in a way that mimics what is already done for asyncPost().

I tested the patch for a asyncGet() against a remote web service. I am not
able to test changes made to the XULrunnerHackCallback invocations in

Original issue: (November 05, 2009 19:42:41)

@pyjsorg pyjsorg closed this

From on November 06, 2009 12:55:24:
raise SyntaxError, "non-keyword arg after keyword arg"
SyntaxError: non-keyword arg after keyword arg

whoops :)

         return XULrunnerHackCallback(self, 'GET', None, None, user,
  • handler=pwd)
  • handler=pwd, return_xml, content_type)

i'll sort this out don't worry

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.