<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Firefox version history &#8211; Henry Poon&#039;s Blog</title>
	<atom:link href="https://blog.henrypoon.com/blog/tag/firefox-version-history/feed/" rel="self" type="application/rss+xml" />
	<link>https://blog.henrypoon.com</link>
	<description></description>
	<lastBuildDate>Sun, 02 Oct 2022 04:35:45 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	
<site xmlns="com-wordpress:feed-additions:1">83044199</site>	<item>
		<title>Running Selenium Webdriver on WSL2</title>
		<link>https://blog.henrypoon.com/blog/2020/09/27/running-selenium-webdriver-on-wsl2/</link>
					<comments>https://blog.henrypoon.com/blog/2020/09/27/running-selenium-webdriver-on-wsl2/#respond</comments>
		
		<dc:creator><![CDATA[hp]]></dc:creator>
		<pubDate>Mon, 28 Sep 2020 00:49:34 +0000</pubDate>
				<category><![CDATA[computer stuff]]></category>
		<category><![CDATA[engineering]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[APT]]></category>
		<category><![CDATA[AWK]]></category>
		<category><![CDATA[Bash]]></category>
		<category><![CDATA[COM]]></category>
		<category><![CDATA[Computer architecture]]></category>
		<category><![CDATA[D]]></category>
		<category><![CDATA[Download]]></category>
		<category><![CDATA[Drive]]></category>
		<category><![CDATA[Error message]]></category>
		<category><![CDATA[Firefox]]></category>
		<category><![CDATA[Firefox version history]]></category>
		<category><![CDATA[Flag]]></category>
		<category><![CDATA[Go]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[Graphical user interface testing]]></category>
		<category><![CDATA[IME]]></category>
		<category><![CDATA[IP address]]></category>
		<category><![CDATA[ise]]></category>
		<category><![CDATA[It]]></category>
		<category><![CDATA[Lag]]></category>
		<category><![CDATA[lamb]]></category>
		<category><![CDATA[Language]]></category>
		<category><![CDATA[Lie]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Messages]]></category>
		<category><![CDATA[Net]]></category>
		<category><![CDATA[Operating systems]]></category>
		<category><![CDATA[Parameter]]></category>
		<category><![CDATA[PATH]]></category>
		<category><![CDATA[Port]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[Resolv.conf]]></category>
		<category><![CDATA[Rolling]]></category>
		<category><![CDATA[Run]]></category>
		<category><![CDATA[Selenium]]></category>
		<category><![CDATA[Sleep]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[STR]]></category>
		<category><![CDATA[Struct]]></category>
		<category><![CDATA[Time]]></category>
		<category><![CDATA[ubuntu]]></category>
		<category><![CDATA[Ubuntu version history]]></category>
		<category><![CDATA[USR]]></category>
		<category><![CDATA[Variable]]></category>
		<category><![CDATA[Web development software]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Z]]></category>
		<guid isPermaLink="false">https://blog.henrypoon.com/?p=6269</guid>

					<description><![CDATA[This is a newer version of the post that I made before on how to run Selenium on WSL, but this one is on doing it in WSL2. The instructions are similar at a high level but there are some additional gotchas. You will need: WSL2 setup with Firefox installed (mine uses Ubuntu 20.04) VcXsrv [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">This is a newer version of the post that I made before on <a href="https://blog.henrypoon.com/blog/2017/06/18/running-selenium-webdriver-on-bash-for-windows/" target="_blank" rel="noreferrer noopener">how to run Selenium on WSL</a>, but this one is on doing it in WSL2.  The instructions are similar at a high level but there are some additional gotchas.</p>



<p class="wp-block-paragraph">You will need:</p>



<ul class="wp-block-list"><li><a rel="noreferrer noopener" href="https://msdn.microsoft.com/en-us/commandline/wsl/install_guide" target="_blank">WSL2 setup</a> with Firefox installed (mine uses Ubuntu 20.04)</li><li><a rel="noreferrer noopener" href="https://sourceforge.net/projects/vcxsrv/" target="_blank">VcXsrv</a></li><li><a rel="noreferrer noopener" href="https://github.com/mozilla/geckodriver/releases" target="_blank">geckodriver</a></li></ul>



<h2 class="wp-block-heading">How it works</h2>



<p class="wp-block-paragraph">VcXsrv starts up an X server on the Windows host machine, and what WSL will do is connect to this server to pass on the details of what programs need to be displayed (in this case, the browser window).  Geckodriver is there purely as a middle layer for Selenium to be able to interact with Firefox.</p>



<h2 class="wp-block-heading">VcXsrv setup</h2>



<p class="wp-block-paragraph">This setups the X server so that Windows can display graphical data coming from the Ubuntu instance.</p>



<ol class="wp-block-list"><li>Download and install</li><li>Start it up with the the command line parameter &#8220;-ac&#8221;.  This flag removes access control restrictions for connecting clients (which is okay as long as this server isn&#8217;t exposed on the open Internet and that the only client connecting is the Ubuntu instance)</li><li>Allow connections to VcXsrv on Windows Firewall</li></ol>



<p class="wp-block-paragraph">The &#8220;-ac&#8221; flag and allowing the program through Windows Firewall is pretty important.  When I didn&#8217;t do this, Ubuntu would give me cryptic error messages like &#8220;Broadway display type not supported&#8221;, but once I set up these access controls, everything was fine.</p>



<h2 class="wp-block-heading">Bash setup</h2>



<p class="wp-block-paragraph">Install firefox</p>



<pre class="wp-block-code"><code lang="bash" class="language-bash">sudo apt install firefox</code></pre>



<p class="wp-block-paragraph">Export DISPLAY variable in .bashrc (or for whatever terminal you use, maybe .zshrc, etc.)</p>



<pre class="wp-block-code"><code lang="bash" class="language-bash">export DISPLAY=$(ip route | awk '{print $3; exit}'):0</code></pre>



<p class="wp-block-paragraph">This will configure your DISPLAY variable to use the IP address listed in the resolv.conf file.  The IP address listed there is the IP address of the X server that will be used for displaying the browser window.</p>



<p class="wp-block-paragraph">Start up VcXsrv as described in the above and then try to open Firefox.  The Firefox window should open.</p>



<h2 class="wp-block-heading">Geckodriver setup</h2>



<p class="wp-block-paragraph">This acts purely as the API interface that allows Selenium to interact with Firefox.  Selenium looks for this executable when controlling the web browser.</p>



<ol class="wp-block-list"><li>Download geckodriver (make sure to get the Linux one and not the Windows one)</li><li>Put it in /usr/bin (or alternatively some other folder in your PATH)</li></ol>



<h2 class="wp-block-heading">Selenium sample on Python</h2>



<p class="wp-block-paragraph">I tend to use Python when running Selenium code, and I haven&#8217;t tried it on another language (I imagine the principles are similar).  Here is a piece of sample code for starting up the browser and opening up a website, but really any Selenium code can be used.</p>



<pre class="wp-block-code"><code lang="python" class="language-python">import time

from selenium import webdriver
from selenium.webdriver import DesiredCapabilities

def execute_with_retry(method, max_attempts):
    e = None
    for i in range(0, max_attempts):
        try:
            return method()
        except Exception as e:
            print(e)
            time.sleep(1)
    if e is not None:
        raise e

capabilities = DesiredCapabilities.FIREFOX
capabilities["marionette"] = True
firefox_bin = "/usr/bin/firefox"
browser = execute_with_retry(lambda: webdriver.Firefox(
    firefox_binary=firefox_bin, capabilities=capabilities), 10)

browser.get("https://www.google.com")

time.sleep(10)

browser.close()</code></pre>



<p class="wp-block-paragraph"></p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.henrypoon.com/blog/2020/09/27/running-selenium-webdriver-on-wsl2/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">6269</post-id>	</item>
		<item>
		<title>Disappearing Firefox Icons</title>
		<link>https://blog.henrypoon.com/blog/2011/06/20/disappearing-firefox-icons/</link>
					<comments>https://blog.henrypoon.com/blog/2011/06/20/disappearing-firefox-icons/#respond</comments>
		
		<dc:creator><![CDATA[hp]]></dc:creator>
		<pubDate>Mon, 20 Jun 2011 15:51:37 +0000</pubDate>
				<category><![CDATA[computer stuff]]></category>
		<category><![CDATA[9]]></category>
		<category><![CDATA[APT]]></category>
		<category><![CDATA[Cache]]></category>
		<category><![CDATA[COM]]></category>
		<category><![CDATA[Comment]]></category>
		<category><![CDATA[D]]></category>
		<category><![CDATA[EAR]]></category>
		<category><![CDATA[Firefox]]></category>
		<category><![CDATA[Firefox version history]]></category>
		<category><![CDATA[Free software]]></category>
		<category><![CDATA[Go]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[Google Search]]></category>
		<category><![CDATA[Icon]]></category>
		<category><![CDATA[It]]></category>
		<category><![CDATA[Laptop]]></category>
		<category><![CDATA[Link]]></category>
		<category><![CDATA[Mozilla]]></category>
		<category><![CDATA[Page]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Vol]]></category>
		<category><![CDATA[Web browsers]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows 7]]></category>
		<guid isPermaLink="false">http://henrypoon.mooo.com/blog/disappearing-firefox-icons</guid>

					<description><![CDATA[Here&#8217;s a quick post about resolving an issue about the Firefox icon disappearing and showing a generic Windows icon. It came up while I set up my laptop, A quick Google search gave me a solution. It involves rebuilding the Windows 7 Icon Cache. Link: http://www.heerengandhi.com/2009/07/29/firefox-icon-went-missing-in-windows-7-heres-a-fix/comment-page-1/]]></description>
										<content:encoded><![CDATA[<p>Here&#8217;s a quick post about resolving an issue about the Firefox icon disappearing and showing a generic Windows icon.  It came up while I set up my laptop, A quick Google search gave me a solution.  It involves rebuilding the Windows 7 Icon Cache.</p>
<p>Link: <a href="http://www.heerengandhi.com/2009/07/29/firefox-icon-went-missing-in-windows-7-heres-a-fix/comment-page-1/" target="_blank" rel="noopener noreferrer">http://www.heerengandhi.com/2009/07/29/firefox-icon-went-missing-in-windows-7-heres-a-fix/comment-page-1/</a></p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.henrypoon.com/blog/2011/06/20/disappearing-firefox-icons/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1075</post-id>	</item>
	</channel>
</rss>
