Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

no longer works with Jython 2.7rc2 #33

Open
GoogleCodeExporter opened this issue Oct 29, 2015 · 2 comments
Open

no longer works with Jython 2.7rc2 #33

GoogleCodeExporter opened this issue Oct 29, 2015 · 2 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. run "~/jython2.7rc2/bin/jython console.py"

What is the expected output? What do you see instead?

expected: console window should pop up

actual: no error, and instead a Traceback:

 Traceback (most recent call last):
   File "console.py", line 36, in <module>
     class Console:
   File "console.py", line 37, in Console
     PROMPT = sys.ps1
 AttributeError: '<reflected field public org.python.core.PyObject o' object has no attribute 'ps1'

What version of the product are you using? On what operating system?

jythonconsole: Subversion head
Java: Java HotSpot(TM) 64-Bit Server VM (Oracle Corporation)] on java1.8.0_45
Jython: 2.7rc2

This worked in Jython 2.7rc1.

Original issue reported on code.google.com by flemi...@gmail.com on 21 May 2015 at 11:07

@GoogleCodeExporter
Copy link
Author

related:
  https://hg.python.org/jython/rev/23c3effa5d4f
  http://bugs.jython.org/issue2305

Original comment by flemi...@gmail.com on 21 May 2015 at 11:19

@jimbaker
Copy link

Related bug reported against Jython: http://bugs.jython.org/issue2373

It looks like we have changed how the REPL is set up in Jython compared to what it was in the past, so it's more compliant with CPython. In particular the demo code used a behavior that is specifically ruled out in the Python docs (and causes problems in tools expect a standard Python): https://docs.python.org/2/library/sys.html#sys.ps1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants