问题标签 [iceweasel]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
0 回答
325 浏览

raspberry-pi - 为 Kiosk 打开和关闭 Iceweasel

我正在尝试设置一个在晚上和周末关闭 HDMI 端口的信息亭。我设置了一个 crontab 来关闭它,但是当它打开时屏幕是黑色的,直到一些动作使它重新加载。因此,我试图关闭 Iceweasel 并重新打开全屏以加载屏幕。到目前为止,Iceweasel 关闭,HDMI 端口关闭然后打开,但我无法让 Iceweasel 重新启动。我该怎么做?

终端


run_iceweasel.sh


0 投票
1 回答
6085 浏览

python - 找不到匹配的功能集

嗨,我在我的 Raspberry Pi 上,并使用带有 Selenium 3.4.2 的 Python 3,并且在使 selenium 与 Iceweasel 一起工作时遇到了问题。

从这段代码

我得到这个

版本:

  • 硒 3.4.2
  • 蟒蛇 3
  • Iceweasel 45.9.0esr-1~deb8u1
0 投票
0 回答
167 浏览

python - Raspberry Pi Selenium Python -- Iceweasel 无法正确加载页面

我希望你做得很好。

我编写了一个小脚本来进行一些抓取,以监控我打算购买的产品的价格演变。该脚本在我的 PC 上运行良好,但是当我尝试将它移植到我的 RasPi 上时,它不能完全运行。它可以顺利运行第一页,但是当尝试运行第二页(这是一个著名的电子商务网站)时,页面显示不正确(没有图像,处置不同)结果(我假设)它找不到 XPath。

我尝试了几种解决方法,鉴于页面在 Chromium 上正常运行,我尝试用 driver.Chrome() 替换 driver.Firefox() 但它似乎不起作用(另外我在某处读到它没有,我是只是试试我的运气)

我尝试通过 CSS 选择器交换 XPath,但无法选择似乎是标记子部分的 #text。

我试图无头运行浏览器(以防万一),但它无论如何都不起作用。

因此,我想知道您是否对潜在的解决方案有想法,因为您在这方面比我好得多。

提前感谢您的意见,祝您有美好的一天!

0 投票
2 回答
3587 浏览

python - Selenium Firefox webdriver works on images built from Ubuntu but not on images built from Debian

This is a pretty bizarre situation I have encountered. I have the following simple Python script:

And wrapper for the script:

Additionally I have two Dockerfiles:

Dockerfile A (Ubuntu; works fine):

Dockerfile B (Debian; crashes):

test.py run from the image built from Dockerfile B throws the following exception:

selenium.common.exceptions.WebDriverException: Message: Process unexpectedly closed with status: 1

The geckodriver.log shows the following error:

GTK_BACKEND doesn't match available displays

Has anyone encountered this and know a workaround? It shouldn't need access to a display because it's running headless - unless selenium Firefox options are different in iceweasel than regular Firefox? I expected similar behavior, and I would much prefer to use the Anaconda image

I just tried this which I was almost certain would solve it but it did not work.

EDIT: I do not believe this is a geckodriver issue as I tried the same Dockerfile with firefox-esr instead of iceweasel. Additionally, I tried starting the container interactively and executed firefox -headless (which on ubuntu launches a headless firefox session) it gave the same exact GTK error selenium does.

0 投票
1 回答
778 浏览

python - selenium WebDriverException:在无头 Pi 上发生“连接被拒绝”

编辑:这似乎不是重复的,因为链接的帖子答案中的任何建议都没有修复错误。这是运行脚本后的 geckodriver.log:

我无法在无头 Raspberry Pi 3 B+ 上创建运行 python 3.5 的 webdriver 实例。我跑了

sudo apt-get install python-pip iceweasel xvfb pip install pyvirtualdisplay selenium

安装依赖项。但是,当我运行基本脚本来创建 selenium WebDriver 时,我会收到一条WebDriverException: Message: connection refused消息。

我的代码:

错误信息:

这个来自另一个论坛的答案表明上面的代码应该可以工作。任何帮助表示赞赏。

0 投票
0 回答
59 浏览

python - 如何使用 selenium python 删除 Firefox 中无响应的脚本

我正在selenium使用 python 在raspberry pi. 我已经安装了iceweaselFirefox 的版本。我正在按照此视频的说明进行操作。

我有一个使用 selenium 打开的网站,我试图点击一个链接,该链接将在网站上打开一个页面。通常如果我这样做(没有硒),它工作正常。但是使用 selenium,打开时间太长,并且网站上的加载图标一直显示。由于以下警告消息出现在浏览器中,python selenium 代码无法处理并崩溃。

在此处输入图像描述

下面是代码:

在上面的 python 代码中,selenium 正在点击仪表板页面。一旦这件事发生,我也可以在网站上看到它被点击。但在此之后,它继续加载和加载,然后Unresponsive script警告出现,并显示以下错误:

Script: https://<url>/asse…/angular/angular.js?20190904.1:9336) The alert could not be closed. The browser may be in a wildly inconsistent state, and the alert may still be open. This is not good. If you can reliably reproduce this, please report a new issue at https://github.com/SeleniumHQ/selenium/issues with reproduction steps. Exception message: TypeError: a.document.getElementsByTagName(...)[0].getButton is not a function

我试过使用driver.implicitly_wait(5)

它删除了警告,但浏览器上没有发生任何事情。该页面仍在继续加载,没有任何显示。

如何从 python selenium 处理网页的这种行为。请帮忙。谢谢

0 投票
0 回答
83 浏览

javascript - 如何避免在 Iceweasel 20 上的 bitaddress.org 上使用 Math.Random()

我正在尝试安全地生成钱包地址。我有一台较旧的气隙计算机,上面没有网络硬件。我启动了一个 live USB 并在 Iceweasel 20 中打开了 bitaddress.org 的源文件。它似乎可以工作并生成地址,但如果我打开控制台,它会显示:

“警告:

未找到安全的随机数生成器。

使用 Math.Random(),它在密码学上并不强!”

查看代码,在我看来 bitaddress.org 使用 node.js crypto.randomBytes() 或 window.crypto.getRandomValues()。Iceweasel 20 没有实现 window.crypto.getRandomValues(),而且我不确定如何在气隙计算机上包含 Node.js。

任何帮助表示赞赏。

0 投票
1 回答
344 浏览

debian - Where can I find Iceweasel in Debian?

I have recently installed Debian 10 in a Virtual Machine and wanted to install Iceweasel. At class, we were told to use $apt-cache for searching our language and then proceed with $sudo apt-get install iceweasel-l10n-es-es

However, I can't find Iceweasel through the menu nor typing $iceweasel in the terminal. I know that Iceweasel is a fork of Firefox and indeed I can see Firefox in the menu but I was sure that Iceweasel is a completely diffrent program.

Why can't I execute Iceweasel? Is there anything else I should do to complete the installation successfully?

Thanks.

P.S.: Please explain everything that I should know since I'm a debian newbie :)