How do I confirm I'm using the right chromedriver? - selenium-webdriver

I came in to the office yesterday morning to find that my Capybara tests couldn't interact with Chrome. I'm seeing
Selenium::WebDriver::Error::UnknownError: unknown error: unable to discover open pages
Googling around revealed that this was likely caused by an out-of-date chromedriver or selenium-webdriver, which sounded very plausible, since neither had been updated in a long time (I think chromedriver was at 2.2 and selenium-webdriver was at 2.35.1), and since Chrome auto-updated to 32.0.1700.77 on January 14, that seemed like good solid evidence to me.
So I've updated selenium-webdriver to 2.39.0. Figuring out what version of chromedriver I had been using actually turned out to be more difficult. I had a version of chromedriver sitting in my Downloads directory that I thought my code was referring to, but I couldn't find my Downloads directory in the PATH (I'm using OS X by the way). I tried replacing this file with version 2.8 from here, but it had no effect. I became skeptical that the version in my Downloads directory was the version that was being used in the first place, so I used brew to install it. brew info chromedriver now yields:
chromedriver: stable 2.8
http://code.google.com/p/chromedriver/
/usr/local/Cellar/chromedriver/2.8 (2 files, 21M) *
Built from source
From: https://github.com/Homebrew/homebrew/commits/master/Library/Formula/chromedriver.rb
Looks good. My PATH contains /usr/local/bin, which has a chromedriver link to the location brew installed to. As far as I understand it, this should allow my automation to detect and launch the chromedriver.
Unfortunately, my issue is still unresolved. I remain unable to discover pages. Can anyone confirm that I've done what one normally does to set up the chromedriver?
Side Question: After downloading chromedriver 2.8 directly and also installing it with brew, I tried launching both the downloaded version and the brew version separately to confirm that either version could launch successfully. I'm certain they are both in fact version 2.8, but when I launch either one the console says:
Starting ChromeDriver (v2.2) on port 9515
Is that normal? I certainly wasn't expecting it to say v2.2, but there are no other versions apart from 2.8 installed by brew (so I doubt brew is accidentally using the older version), and when I run the file I downloaded directly, I'm quite sure it's version 2.8 from the Chromedriver website. Is this an oversight on their part, or does v2.2 refer to something else, unlikely though that may seem?

It would be tricky to verify the chrome driver version frequently when you download it with homebrew. I would suggest downloading the driver and maintaining it in a folder mapped in your PATH.
So that maintaining or identifying the driver version will be easy with the below steps:
Go to the folder where you have chromeDriver
Open command prompt pointing the folder
run: chromeDriver -v

ChromeDriver is at version 2.16 now. I would recommend manually updating your driver instead of updating with whatever older version that homebrew wants to update you to.

You can use command line: pip freeze to list down all packages you have installed with their version.
Or you also can use pip show <package name> to check the details of the package, which also includes package version.

Click here
chrome driver version
for checking your chrome driver version.
Now it's time to check the latest release version. So click here latest release version
Compare between;

Related

Codename one version 1.0 is installed even though I install version 6.0 from Eclipse Marketplace

I am using Eclipse 2020-06 (I have made a fresh install of Eclipse instead of upgrading it from an earlier version of Eclipse) and JDK 8 (1.8.0_261). My OS is Windows 10.
JAVA_HOME is set to C:\Program Files\Java\jdk1.8.0_261
When I download "Codename One" plugin from Eclipse Marketplace it shows the version as 6.0 and it says "Installed" at the end of the installation process.
However, when I go to "Help -> Eclipse IDE -> Installation Details" under Eclipse, CodenameOneFeature version is listed as: 1.0.0.201409151325
When I select CodenameOneFeature from this list and hit Update, it says "No updates found". So basically I cannot force it to update to 6.0.
I can confirm that I have the earlier version installed also from the setting of the Codename One projects I create: when I go to Properties -> Java Compiler, the compliance level is set to 1.5 (also 1.5 is used in build.xml file).
BTW, I have also tried installing Eclipse 2019-06 (instead of 2020-06) and/or installing JDK 10 (instead of JDK 8) and/or modifying the eclipse.ini (by adding -vm option) so that it uses the version of JDK I want (instead of setting JAVA_HOME). But no combination of those has solved the problem.
Updated answer:
I found the problem. I broke the update site with a commit a couple of weeks ago. This should be fixed in a couple of hours once server caches refresh.
Original answer:
With Eclipse at this time we only support JDK 8. We're experiencing issues in updating the eclipse plugin to the latest version. Once installed I think you can also use JDK 11 but it doesn't matter since we don't support JDK 11 features.
Once a reasonably new version of the plugin is installed you can press update in Codename One Settings and it will update our libraries to the latest version equivalent to the other IDEs.

tcms-api 5.3 package incompatible with Windows

I attempted to upgrade my tcms-api library from 5.0 to 5.3 using:
pip install tcms-api --upgrade
on a Windows 10 machine, I saw a lot of errors when trying to install the dependent package of kerberos. Even though this is old, I saw a similar set of errors. The package installation failed since the kerberos package isn't supported on Windows and I was left at tcms-api 5.0.
Please file a bug against https://github.com/kiwitcms/tcms-api.
We can do a quick fix by providing 2 package names:
tcms-api and tcms-api[kerberos]
The first one will not install the kerberos package.
The proposed workaround makes sense but changing the underlying kerberos implementation needs careful testing which isn't a quick job.
OTOH https://github.com/kiwitcms/python-social-auth-kerberos uses gssapi which seems to be the latest and most actively maintained implementation of Kerberos for Python. There is an open issue to migrate to that in tcms-api so you can contribute if you want.
As a workaround, I was able to do the following (caveat: I haven't extensively tested my installation yet):
Clone the tcms-api repo from GitHub
Edit setup.py to change the install_requires line to use 'kerberos-sspi' rather than 'kerberos'
Install the following pip packages: Setuptools, Wheel, Twine
CD to repo folder and run: python setup.py bdist_wheel
That creates a package under the dist folder
Run pip install dist\tcms_api-5.3-py3-none-any.whl
Celebrate successful package install
The steps were modified from this page.
Update:
I confirmed the things I need the API to do work with my custom package (create and update test runs). However, I'm in a situation where I don't need to specifically harden my Kiwi instance using kerberos authentication.

MacPorts: install hangs/remains unusable

I've been trying to install MacPorts on a new Mac Pro with a fresh, fully updated Yosemite OS. The installer hangs on 'Running package scripts'. So I tried to build it from source. That works, with the installer stating:
Congratulations, you have successfully installed the MacPorts system.
However, it seems unusable. When I do sudo port install apache2 I get the message:
Error: Port apache2 not found
Simply trying to do a 'self update' (as root):
sh-3.2# port -d selfupdate
DEBUG: MacPorts sources location: /opt/local/var/macports/sources/rsync.macports.org/release/tarballs
---> Updating MacPorts base sources using rsync
receiving file list ... done
base.tar
...and then nothing... I've waited for half an hour, but it won't go any further. I can't find any logs either.
Again: there's nothing special about my setup, it's out-of-the-box Yosemite, only updated through the App store and, of course, I've installed Xcode with command line utilities and formally accepted the license, as is required according to the MacPorts site.
I've also tried uninstalling it, using the instructions from the MacPorts site, and reinstalling. But it does not make a difference.
I've read quite a few forum posts, but I can't find any post relating a problem like this. I hope someone can shed some light on this.
The installer hangs running package scripts because the last statement in these package scripts is exactly this "sudo port selfupdate" that you've been running manually afterwards.
Because this step did never run, your MacPorts installation lacks knowledge about the apache2 port (which is exactly why the installer runs selfupdate to give you a full-featured installation).
Unfortunately Apple's infrastructure (rsync.macports.org) seems to have connectivity problems at the moment, which is causing problems for quite a few people. You can try using one of the mirrors as outlined at https://trac.macports.org/wiki/Mirrors.

Pyramid on Google’s App Engine using buildout resulting in setuptools not found error

I am trying to run pyramid application on google's app engine using buildout. I followed this link gae_buildout and got struck while running the buildout. Its shows "setuptools not found error" despite of seetuptools being installed in the virtual environment. I tried few work arounds and nothing turned fruitful, any thoughts on this ?
Find the error trace below. I am using pyramid 1.4 version.
An internal error occurred due to a bug in either zc.buildout or in a
recipe being used:
Traceback (most recent call last):
File "c:\myenv\newproject\eggs\zc.buildout-2.2.1-py2.7.egg\zc\buildout\buildou
t.py", line 1942, in main
getattr(buildout, command)(args)
File "c:\myenv\newproject\eggs\zc.buildout-2.2.1-py2.7.egg\zc\buildout\buildou
t.py", line 622, in install
installed_files = self[part]._call(recipe.install)
File "c:\myenv\newproject\eggs\zc.buildout-2.2.1-py2.7.egg\zc\buildout\buildou
t.py", line 1366, in _call
return f()
File "c:\myenv\newproject\eggs\rod.recipe.appengine-2.0.2-py2.7.egg\rod\recipe
\appengine\__init__.py", line 377, in install
self.copy_packages(ws, temp_dir)
File "c:\myenv\newproject\eggs\rod.recipe.appengine-2.0.2-py2.7.egg\rod\recipe
\appengine\__init__.py", line 284, in copy_packages
self.write_pkg_resources(ws, lib)
File "c:\myenv\newproject\eggs\rod.recipe.appengine-2.0.2-py2.7.egg\rod\recipe
\appengine\__init__.py", line 267, in write_pkg_resources
assert len(setuptools_eggs) == 1, "setuptools not found"
AssertionError: setuptools not found
Got the same (Ubuntu 12.04) and finally solved the problem by changing ae-sdk-version to 1.8.0 from buildout.cfg
Open buildout.cfg and change the line:
ae-sdk-version=1.7.5
to:
ae-sdk-version=1.8.0
...or the latest one from here. Now seems to be 1.8.5, but 1.8.0 worked for me.
The problem in fact comes because PyPI is not serving last version of pyramid_appengine. It's serving 0.8.1 and should be (latest) 0.8.2-a2. You can download and install in your virtualenv the latest version in a tarball from here: https://pypi.python.org/pypi/pyramid_appengine/
So here's another solution.
It seems that rod.recipe.appengine doesn't work with the setuptools versions of the system, and it doesn't download the last version in that buildout. So the solution is to force to download a newer version of setuptools that rod.recipe.appengine likes.
Edit the versions.cfg file (should appear just the [versions] tag) and add the following line:
[versions]
setuptools = 1.1.7
(other older versions work as well, I tested successfully with 0.9.8)
And now seems to work easier without needing the mentioned patches (thanks Tom) that are harder to update.
This happened to me as well.
I started looking at the code and noticed it was explicitly looking for an egg install of setuptools, and none of the places I had installations of it were eggs for some reason.
I decided I'd go delete them from my site-packages and re-run the tools to download them, and after only killing the copy in my virtual env, and re-running the bootstrap and buildout, it got the egg and everything started working fine.

How to solve 503 error accessing CollabNet Subversion Console?

I'm using Collabnate Subversion Edge.
I'm getting below error when trying to access URL http://localhost:3343/csvn.
Collbnate is set up on Windows Server 2008.
HTTP ERROR: 503
Problem accessing /csvn/. Reason:
Service Unavailable
Powered by Jetty://
How to solve it?
I spent two days fighting with the same problem. It turned out that CollabNet Subversion Edge 4.0.11 does not support Java 8.
The following procedure helped me make CN Subverion Edge 4.0.11 work again on Windows 7:
1) Uninstall CollabNet Subversion
2) Uninstall Java 8 (I had Java 7 and 6 side by side, so after uninstalling the 8, 7 picked up after I added it to PATH variable. It is important to add it at the very beginning of the path, otherwise Windows\System32\java.exe will be taken, which was not good for me also)
3) Install CollabNet Subverion (the important thing is to uncheck the "Run CollabNet ..." check box in the final screen. It looks like the installer is still creating files at the end and only after I have clicked OK in the final screen the needed configuration files have been created in data/conf folder.
4) Make sure that data/conf/httpd.conf file is created. If it is there, got to services (services.msc) and start server manually
Now launch the browser and navigate to localhost:3343/csvn.
Good luck.
1) Install Java 7
2) In file \csvn\svcwrapper\conf\wrapper.conf change from #wrapper.java.command.maxVersion=1.6 to wrapper.java.command.maxVersion=1.7
3) Run \csvn\svcwrapper\bat\runConsole.bat
Good luck.
Check in c:/csvn/data/logs for a log that starts with "console". Then find the error(s) and check what is wrong.
Did you try restarting the service ?
I had the same issue, CollabNet Subversion Edge version 4.0.4. In my case the problem was updating the JAVA_HOME from JDK 1.6 to JDK 1.7.
I finally resolved it changing the file:
C:\PROGRA~1\csvn\svcwrapper\conf\wrapper.conf
I changed the value of the property: wrapper.java.command:java
wrapper.java.command=C:/PROGRA~1/Java/jdk1.6.0_45/bin/java
So the csvn now runs with 1.6 as before. And it works again as a service automatically.
Good luck!!
There's an alternative issue that results in the same error: The database may get corrupted. This is what just happened to me. The above answers where not working in this case. As Subversion Edge 5.0.1 comes bundled with jre8, it would be rather strange if it weren't able to run against it.
To solve the problem, I had to patch the database (luckily, the user database c:\csvn\data\csvn-production-hsqldb.script is a plain text sql file).
Backup files in c:\csvn\data
Delete csvn-production-hsqldb.script and start the service (should come up now)
Exit the service
Save the file which is automatically recreated now
Compare your old file and the new working one
Replace every line starting with INSERT INTO QRTZ in your database with the corresponding lines from the working copy
Copy the new files to the proper place
Start the service
Hope it worked
I had this problem too. Upgrade to SubversionEdge 5.1.4 solved the issue.
We encounter this problem with CollabNet Subversion Edge 3.3.1 every time we patch our JDK 6 install (e.g. IAVM update). We need to install JDK 7 and 8 on this machine also so the installers are confusing the version information in the Windows Registry (not too much of a surprise there). Even if we update JDK 6 last, it gets weird too.
Nevertheless, it turns out the Subversion Console uses the Windows Registry to locate the Java install to launch the Console service. Updating the registry entry HKLM\SOFTWARE\JavaSoft\Java Development Kit\CurrentVersion to 1.6 and having a proper install of JDK 1.6 will restore console operation.

Resources