Closed ghost closed 5 years ago
Try running bash install-dev-dependencies.sh
without sudo
, and then retry test.sh
. My theory is that sudo bash install-dev-dependencies.sh
is putting the pip
-installed stuff, including selenium
, somewhere that your regular user can't access.
My theory is that sudo bash install-dev-dependencies.sh is putting the pip-installed stuff, including selenium, somewhere that your regular user can't access.
Ah, indeed. I drew the same conclusion when I first hacked on HTTPS Everywhere, a few months back. At that point, I independently took steps the same as the ones you suggested above. IIRC, it worked on that occasion. For some reason (tiredness, probably), this time, when I came to install the dependencies on a different machine, I didn't adequately think through the steps, hence using sudo
... d'oh!
Right, let's give this a new shot:
And then:
Hm, a bit better, but perhaps still not quite as intended?
I see your earlier comment in https://github.com/EFForg/https-everywhere/issues/2801#issuecomment-222246617 where you were having trouble, but for a different reason (?).
Are you using the most current master checkout of HTTPS Everywhere? Also I'm wondering if you can reproduce this on a clean system, for example in a VM. If this is the same system you had before, maybe it's in some kind of half-broken state.
Also, can you please go back and edit your earlier comments in this issue to hide the long outputs in a <details><summary>Click me to expand</summary>(put the output here)</details>
construct to make it easier to skim through the issue? You may need to move the output out of the code blocks.
I see your earlier comment in #2801 (comment) where you were having trouble, but for a different reason (?).
Good catch. Evidently, on that occasion, I did indeed install the dependencies without prefixing sudo
. My memory of the tests having gone smoothly, though, was clearly not entirely accurate.
On that occasion, bash test.sh
reported that 6 out of 7 tests passed.
On this occasion, bash test.sh
reported that 16 out of 16 tests passed.
Are you using the most current master checkout of HTTPS Everywhere?
It was very slightly out of date:
Also I'm wondering if you can reproduce this on a clean system, for example in a VM.
I don't have the facilities to do that at the moment, sorry :(
If this is the same system you had before, maybe it's in some kind of half-broken state.
It's a different system.
Also, can you please go back and edit your earlier comments in this issue to hide the long outputs in a
<details><summary>
Click me to expand</summary>
(put the output here)</details>
construct to make it easier to skim through the issue?
Done. Seems to be working.
You may need to move the output out of the code blocks.
Noted. If it isn't working for you, let me know, and I'll try indenting it 4 spaces instead of using triple backticks as delimiters (or suchlike as you may suggest).
Thanks again for looking into this.
Your edits look fine, thanks. I've had trouble with code blocks in a <details>
tag. It turns out that the triple-tick code blocks don't work if the ticks start on the line immediately after the <details>
tag. You need at least one line buffer. I'm glad I know what the problem is now. Anyway that's a side issue.
The tests work for me using the debian/jessie64 v8.6.1 Vagrant box using HTTPS Everywhere commit 377a21a65003837ce1ecf10ac3a89f04c2f34e5a. Here's the end of the log:
I'm not sure what's wrong for you. I notice your latest log has an extension date of 2016.11.30
and mine is 2016.12.19
. We should be building the same version. Any thoughts there?
Is your system unusually configured or resource-constrained in some way? For example the default RAM allocated for a Vagrant VM is 1GB, and I've found I need to increase that a little for the initial setup to work. I'm not saying RAM is the problem here, but it might help to know if there's anything unusual on your end that you know of.
I notice your latest log has an extension date of 2016.11.30 and mine is 2016.12.19. We should be building the same version. Any thoughts there?
After the git pull
above, the version is now 2016.12.19:
Is your system unusually configured or resource-constrained in some way?
This particular machine has 3GB physical RAM, 2.5GB swap, Core 2 Duo CPU. Should that be sufficient to allow the tests to be run successfully, assuming there are some other processes (desktop environment, web browser, etc) taking up <50% of those resources?
If not, it might be an idea to have a lightweight test suite suitable for older machines or VMs, and a more extensive test suite suitable for more powerful machines.
I doubt it's resources. If you were on a Raspberry Pi or running some kind of strange Debian offshoot, then maybe we could look into that.
chromedriver
is the connector that lets automated tests run against Chrome/ium. It should just work on Debian but for some reason it's not for you. A while ago I got an HTTPS Everywhere development environment working on Fedora (https://github.com/EFForg/https-everywhere/pull/5584) and had to work with chromedriver
. You can try installing chromedriver
manually, getting test.sh
working and then working backwards from that to see why install-dev-dependencies.sh
didn't set it up automatically.
@sampablokuper if you are still experiencing this issue please tell.
On Debian Jessie. Dependencies are satisfied:
Click me to expand
``` $ sudo bash install-dev-dependencies.sh [sudo] password for sampablokuper: + '[' 0 '!=' 0 ']' + type apt-get + BROWSERS='firefox chromium-browser' + CHROMEDRIVER=chromium-chromedriver ++ lsb_release -is + [[ Debian == \D\e\b\i\a\n ]] + BROWSERS='iceweasel chromium' + CHROMEDRIVER=chromedriver + apt-get install libxml2-dev libxml2-utils libxslt1-dev python-dev iceweasel chromium zip sqlite3 python-pip libcurl4-openssl-dev xvfb libssl-dev git chromedriver Reading package lists... Done Building dependency tree Reading state information... Done git is already the newest version. libxml2-dev is already the newest version. libxml2-utils is already the newest version. python-dev is already the newest version. python-pip is already the newest version. sqlite3 is already the newest version. xvfb is already the newest version. zip is already the newest version. chromedriver is already the newest version. chromium is already the newest version. libcurl4-openssl-dev is already the newest version. iceweasel is already the newest version. libxslt1-dev is already the newest version. libssl-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. + git submodule init + git submodule update Submodule path 'translations': checked out 'de755e445735270cc4e1b73882da5ed981e7a2f8' + pip install --user --no-allow-insecure --no-allow-external -r requirements.txt Requirement already satisfied (use --upgrade to upgrade): lxml>=3.3.3 in /usr/lib/python2.7/dist-packages (from -r requirements.txt (line 1)) Requirement already satisfied (use --upgrade to upgrade): pycurl in /usr/lib/python2.7/dist-packages (from -r requirements.txt (line 2)) Requirement already satisfied (use --upgrade to upgrade): regex in /root/.local/lib/python2.7/site-packages (from -r requirements.txt (line 3)) Requirement already satisfied (use --upgrade to upgrade): bsdiff4 in /root/.local/lib/python2.7/site-packages (from -r requirements.txt (line 4)) Requirement already satisfied (use --upgrade to upgrade): python-Levenshtein in /root/.local/lib/python2.7/site-packages (from -r requirements.txt (line 5)) Requirement already satisfied (use --upgrade to upgrade): selenium in /root/.local/lib/python2.7/site-packages (from -r requirements.txt (line 6)) Requirement already satisfied (use --upgrade to upgrade): setuptools in /usr/lib/python2.7/dist-packages (from python-Levenshtein->-r requirements.txt (line 5)) Cleaning up... + cd test/rules + pip install --user -r requirements.txt Requirement already satisfied (use --upgrade to upgrade): pycurl in /usr/lib/python2.7/dist-packages (from -r requirements.txt (line 1)) Requirement already satisfied (use --upgrade to upgrade): regex in /root/.local/lib/python2.7/site-packages (from -r requirements.txt (line 2)) Requirement already satisfied (use --upgrade to upgrade): bsdiff4 in /root/.local/lib/python2.7/site-packages (from -r requirements.txt (line 3)) Requirement already satisfied (use --upgrade to upgrade): python-Levenshtein in /root/.local/lib/python2.7/site-packages (from -r requirements.txt (line 4)) Requirement already satisfied (use --upgrade to upgrade): setuptools in /usr/lib/python2.7/dist-packages (from python-Levenshtein->-r requirements.txt (line 4)) Cleaning up... + cd - /home/sampablokuper/Documents/projects/https-everywhere + cd test/chromium + pip install --user -r requirements.txt Requirement already satisfied (use --upgrade to upgrade): selenium in /root/.local/lib/python2.7/site-packages (from -r requirements.txt (line 1)) Cleaning up... + cd - /home/sampablokuper/Documents/projects/https-everywhere + ln -sf ../../test.sh .git/hooks/pre-push ```But several errors occur running
bash test.sh
:Click me to expand
``` $ bash test.sh + '[' -n '' ']' + git rev-parse ++ git rev-parse --show-toplevel + cd /home/sampablokuper/Documents/projects/https-everywhere + source utils/mktemp.sh +++ which mktemp ++ MKTEMP=/bin/mktemp ++ mktemp ++ /bin/mktemp + TMP=/tmp/tmp.umzZmRgrDJ + trap 'rm "$TMP"' EXIT + '[' -d test/rules ']' + '[' 0 -gt 0 ']' + python2.7 test/rules/src/https_everywhere_checker/check_rules.py test/rules/coverage.checker.config Traceback (most recent call last): File "test/rules/src/https_everywhere_checker/check_rules.py", line 21, in