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

Intern 3.4.0 and instructions in CONTRIBUTING.md #1343

Closed
karlcow opened this issue Feb 16, 2017 · 10 comments
Closed

Intern 3.4.0 and instructions in CONTRIBUTING.md #1343

karlcow opened this issue Feb 16, 2017 · 10 comments
Assignees

Comments

@karlcow
Copy link
Member

karlcow commented Feb 16, 2017

Currently if you follow strictly what is in CONTRIBUTING.md, the tests do not run.
https://github.com/webcompat/webcompat.com/blob/master/CONTRIBUTING.md#functional-tests

In one shell

(webcompatcom) 13:40:51 ~/code/webcompat.com
→ python run.py 
('secrets', '/Users/karl/code/webcompat.com')
/Users/karl/.virtualenvs/webcompatcom/lib/python2.7/site-packages/flask_limiter/extension.py:124: UserWarning: Use of the default `get_ipaddr` function is discouraged. Please refer to https://flask-limiter.readthedocs.org/#rate-limit-domain for the recommended configuration
  UserWarning
 * Running on http://localhost:5000/ (Press CTRL+C to quit)
 * Restarting with stat
('secrets', '/Users/karl/code/webcompat.com')
/Users/karl/.virtualenvs/webcompatcom/lib/python2.7/site-packages/flask_limiter/extension.py:124: UserWarning: Use of the default `get_ipaddr` function is discouraged. Please refer to https://flask-limiter.readthedocs.org/#rate-limit-domain for the recommended configuration
  UserWarning

then opening a new bash window:

→ workon webcompatcom
(webcompatcom) 13:49:57 ~/code/webcompat.com
→ echo $PATH
/Users/karl/.virtualenvs/webcompatcom/bin:/Library/Frameworks/Python.framework/Versions/3.4/bin:/Users/karl/bin/adt-bundle-mac-x86_64-20140321/sdk/platform-tools:/Users/karl/Library/Python/2.7/bin:/Users/karl/bin:/usr/local/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/usr/local/MacGPG2/bin
→ export PATH="/Applications/FirefoxNightly.app/Contents/MacOS/:$PATH"
(webcompatcom) 13:52:02 ~/code/webcompat.com
→ echo $PATH
/Applications/FirefoxNightly.app/Contents/MacOS/:/Users/karl/.virtualenvs/webcompatcom/bin:/Library/Frameworks/Python.framework/Versions/3.4/bin:/Users/karl/bin/adt-bundle-mac-x86_64-20140321/sdk/platform-tools:/Users/karl/Library/Python/2.7/bin:/Users/karl/bin:/usr/local/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/usr/local/MacGPG2/bin
(webcompatcom) 13:52:04 ~/code/webcompat.com
→ node_modules/.bin/intern-runner config=tests/intern
Error: Tunnel failed to start: Exception in thread "main" java.lang.UnsupportedClassVersionError: org/openqa/grid/selenium/GridLauncherV3 : Unsupported major.minor version 52.0
	at java.lang.ClassLoader.defineClass1(Native Method)
	at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
	at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
	at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
	at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
	at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
	at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
	at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:482)

  at ChildProcess.emit  <events.js:117:20>
  at Process.ChildProcess._handle.onexit  <child_process.js:810:12>
@karlcow
Copy link
Member Author

karlcow commented Feb 16, 2017

This follows the #982 comment updating to Intern 3.4.0

@karlcow
Copy link
Member Author

karlcow commented Feb 16, 2017

Probably @andreastt or @miketaylr have an idea of the missing step

@karlcow
Copy link
Member Author

karlcow commented Feb 16, 2017

My Firefox Nightly is 54. The Firefox production release is 51.
Ah wait my Java version.

locate java | grep bin/java$
/Applications/Xcode.app/Contents/Applications/Application Loader.app/Contents/itms/java/bin/java
/Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home/bin/java
/Library/Java/JavaVirtualMachines/jdk1.7.0_51.jdk/Contents/Home/bin/java
/Library/Java/JavaVirtualMachines/jdk1.7.0_51.jdk/Contents/Home/jre/bin/java

→ /Applications/Xcode.app/Contents/Applications/Application\ Loader.app/Contents/itms/java/bin/java -version
openjdk version "1.7.0-internal"
OpenJDK Runtime Environment (build 1.7.0-internal-root_2015_05_12_09_52-b00)
OpenJDK 64-Bit Server VM (build 24.80-b07, mixed mode)

→ /Library/Internet\ Plug-Ins/JavaAppletPlugin.plugin/Contents/Home/bin/java -version
java version "1.8.0_111"
Java(TM) SE Runtime Environment (build 1.8.0_111-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.111-b14, mixed mode)


→ /Library/Java/JavaVirtualMachines/jdk1.7.0_51.jdk/Contents/Home/bin/java -version
java version "1.7.0_51"
Java(TM) SE Runtime Environment (build 1.7.0_51-b13)
Java HotSpot(TM) 64-Bit Server VM (build 24.51-b03, mixed mode)

→ /usr/bin/java -version
java version "1.7.0_51"
Java(TM) SE Runtime Environment (build 1.7.0_51-b13)
Java HotSpot(TM) 64-Bit Server VM (build 24.51-b03, mixed mode)

→ which java
/usr/bin/java


→ ls -al /usr/bin/java
lrwxr-xr-x  1 root  wheel  74 29 sep 09:51 /usr/bin/java -> /System/Library/Frameworks/JavaVM.framework/Versions/Current/Commands/java

→ /usr/libexec/java_home -V 
Matching Java Virtual Machines (1):
    1.7.0_51, x86_64:	"Java SE 7"	/Library/Java/JavaVirtualMachines/jdk1.7.0_51.jdk/Contents/Home

/Library/Java/JavaVirtualMachines/jdk1.7.0_51.jdk/Contents/Home

OK Let's try with the most recent one.

export JAVA_HOME="/Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home"

Then

→ node_modules/.bin/intern-runner config=tests/intern

WORKING!

So be careful, basically you need a recent version of java. Probably should be tested in a command.

@karlcow
Copy link
Member Author

karlcow commented Feb 16, 2017

:) almost

capture d ecran 2017-02-16 a 14 39 29

@miketaylr
Copy link
Member

miketaylr commented Feb 16, 2017

Are you giving it a user and pw to run the auth tests with?

edit: https://github.com/webcompat/webcompat.com/blob/master/.travis.yml#L61

@miketaylr
Copy link
Member

I guess we need to say whatever the minimum Java requirement is here: https://github.com/webcompat/webcompat.com/blob/master/CONTRIBUTING.md#installing-java

@miketaylr
Copy link
Member

Ah, this is documented in a comment, but not contributing.md, i'll write a quick docs patch:

https://github.com/webcompat/webcompat.com/blob/master/.travis.yml#L1

@miketaylr
Copy link
Member

miketaylr commented Feb 16, 2017

@karlcow also, i would recommend you delete your Java Applet Plugin (unless you rely on that for some old banking websites or something), and upgrade /usr/bin/java to 1.8.0+

@karlcow
Copy link
Member Author

karlcow commented Feb 16, 2017

Are you giving it a user and pw to run the auth tests with?

yes :)

@karlcow also, i would recommend you delete your Java Applet Plugin (unless you rely on that for some old banking websites or something), and upgrade /usr/bin/java to 1.8.0+

I will give it a try. I remember upgrading with downloading and double clicking.

@miketaylr
Copy link
Member

(that said, do whatever works for you. computers are scary. 👻)

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

No branches or pull requests

2 participants