From: Evgeniy Korneechev <ekorneechev@altlinux.org> To: ALT Linux Team development discussions <devel@lists.altlinux.org> Subject: Re: [devel] Python: модуль webbrowser.py не видит браузер по умолчанию Date: Thu, 18 May 2017 11:18:37 +0300 (MSK) Message-ID: <1430915052.52249.1495095517354.JavaMail.zimbra@remotesystems.ru> (raw) In-Reply-To: <1109682971.112574.1491223428613.JavaMail.zimbra@remotesystems.ru> ДД! Видимо python(3) запускает использует переменную окружения $BROWSER, которая поумолчанию ведет в /usr/bin/xbrowser Поменял в /etc/alternatives/packages.d/firefox вес с 100 на 50 а в */chromium 50 на 100 Теперь python -m webbrowser -t ya.ru открывает в chromium. Для обычного пользователя тоже есть вариант (если вернуть альтернативы в первоначальный вид): export BROWSER=/usr/bin/chromium; python -m webbrowser -t ya.ru Напрашивается решение добавить пользователю в ~/.bashrc экспорт данной переменной. Ну, а значение брать, то что выбрано в Предпочтительных приложениях (mate-default-applications-properties). Вопрос по mate-default-applications-properties: куда он записывает значения ПО по умолчанию, чтобы мне его оттуда взять))? ----- Исходное сообщение ----- > От: "Evgeniy Korneechev" <ekorneechev@altlinux.org> > Кому: "ALT Linux Team development discussions" <devel@lists.altlinux.org> > Отправленные: Понедельник, 3 Апрель 2017 г 15:43:48 > Тема: Python: модуль webbrowser.py не видит браузер по умолчанию > Всем доброго дня! > Имеем Рабочую станцию 8.1 x86_64 с последними обновлениями (на SK Mate также > все) > В Предпочтительных приложения (mate-default-applications-properties) браузер > выбран Chromium, > однако команды ниже открывают почему-то firefox... > $ python -m webbrowser -t ya.ru > $ python3 -m webbrowser -t ya.ru > > LibreOffice и Pidgin например нормально видят нужный браузер. > > Провел тесты - установил midori, epiphany, newmoon и qupzilla. > Теперь Питон открывает при любом раскладе qupzilla.. Удалил ее - теперь > firefox... > > Как это побороть? Кто-нибудь встречался? Баг питона или mate-control-center? > > -- > WBR, Korneechev Evgeniy > BaseALT/ALTLinux Team -- WBR, Korneechev Evgeniy BaseALT/ALTLinux Team
next prev parent reply other threads:[~2017-05-18 8:18 UTC|newest] Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top 2017-04-03 12:43 Evgeniy Korneechev 2017-05-18 8:18 ` Evgeniy Korneechev [this message] 2017-05-18 15:46 ` Yuri Sedunov 2017-05-19 5:48 ` Evgeniy Korneechev 2017-05-19 8:52 ` Sergey V Turchin 2017-05-19 10:03 ` Yuri Sedunov 2017-05-19 10:14 ` Sergey V Turchin
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=1430915052.52249.1495095517354.JavaMail.zimbra@remotesystems.ru \ --to=ekorneechev@altlinux.org \ --cc=devel@lists.altlinux.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
ALT Linux Team development discussions This inbox may be cloned and mirrored by anyone: git clone --mirror http://lore.altlinux.org/devel/0 devel/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 devel devel/ http://lore.altlinux.org/devel \ devel@altlinux.org devel@altlinux.ru devel@lists.altlinux.org devel@lists.altlinux.ru devel@linux.iplabs.ru mandrake-russian@linuxteam.iplabs.ru sisyphus@linuxteam.iplabs.ru public-inbox-index devel Example config snippet for mirrors. Newsgroup available over NNTP: nntp://lore.altlinux.org/org.altlinux.lists.devel AGPL code for this site: git clone https://public-inbox.org/public-inbox.git