helloSystem / ISO

helloSystem Live and installation ISO
https://github.com/helloSystem/
BSD 3-Clause "New" or "Revised" License
807 stars 58 forks source link

Remaining issues with Falkon browser #60

Open probonopd opened 3 years ago

probonopd commented 3 years ago

Pros

Cons

image

probonopd commented 3 years ago

How to add something to the built-in ad blocker? In uBlock Origin, you would use the pipette tool for this...

image

probonopd commented 3 years ago

According to nowrep on #falkon IRC, you can build without most dependencies. Only kf5-archive is required and ecm is a build-time dep.

https://invent.kde.org/network/falkon/-/blob/master/CMakeLists.txt#L93

To get rid of most kf5 depdencies we'd probably need to build our own pkg using ports.

How to do this whilst minimizing the amount of stuff that needs to be downloaded, so that one can do this in Cirrus CI?

"install deps with pkg, use pourdriere...?"

igalic commented 3 years ago

when this lands, https://github.com/freebsd/poudriere/pull/797 that's how

grahamperrin commented 3 years ago

I imagine that the UA on helloSystem will be same as it is on my FreeBSD-CURRENT:

Mozilla/5.0 (X11; FreeBSD amd64; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Falkon/3.1.0 Chrome/83.0.4103.122 Safari/537.36

Exceptional sites

Teams for friends and family https://teams.live.com/ basics work without a user agent override, which is nice.

Video calling can't be expected to work, for example:

image

– allowances for the camera and microphone can be remembered but still, they don't work. YMMV.

Expect comparable failures for audio calls, without video.

https://github.com/webcompat/web-bugs/issues/25070#issuecomment-751324990 relates, but is probably not specific, to Firefox; tl;dr await improvements by Microsoft and in the meantime, don't expect user agent spoofing to significantly improve the situation.


Various other sites might be not compatible, most notably (and not surprising) KDE bug 415664 – Streaming Video from sites with DRM doesn't work..

For all such sites, I guess the recommendation should be to try Chromium (albeit https://github.com/helloSystem/Menu/issues/29 without global menu integration) or https://github.com/helloSystem/ISO/issues/47 await ease of use of applications such as Google Chrome.

IMHO site incompatibilities need not detract from the appeal of Falkon as a default.

grahamperrin commented 3 years ago

https://github.com/helloSystem/ISO/issues/60#issuecomment-752124152

How to add something to the built-in ad blocker? In uBlock Origin, …

KDE bug 411329 – [Feature Request] adblock: visually block elements

probonopd commented 3 years ago

More important for me would be that meet.jit.si works... Can you get screen sharing in meet.jit.si to work with Falkon?

probonopd commented 3 years ago

Searching in the GitHub code editor does not work. The GitHub search box shows up for a split second, but then the Falkon search box steals focus, and the GitHub search box disappears. Result: Impossible to search in the GitHub online editor. Bug that should be reported upstream? (It works in Chromium.)

grahamperrin commented 3 years ago

https://www.falkon.org/development/https://bugs.kde.org/buglist.cgi?bug_status=UNCONFIRMED&bug_status=CONFIRMED&bug_status=ASSIGNED&bug_status=REOPENED&component=extensions&component=general&list_id=1506993&product=Falkon at a glance, nothing matching.

… GitHub code editor … GitHub search box …

I'm not familiar with this search box, is it the Start searching in file editor feature that's described at https://docs.github.com/en/free-pro-team@latest/github/getting-started-with-github/keyboard-shortcuts#source-code-editing? (I seem to not get this feature in Firefox 84.0.1 on non-helloSystem FreeBSD-CURRENT.)

grahamperrin commented 3 years ago

https://github.com/helloSystem/ISO/issues/60#issuecomment-752764683

▶ KDE bug 431004 – Screen sharing non-functional at meet.jit.si (Jitsi Meet)

probonopd commented 3 years ago

Thanks for testing and submitting. These are incredibly valuable contributions.

probonopd commented 3 years ago

I'm not familiar with this search box,

Go to a file on GitHub, click the "Edit" button, then press ⌘-F for searching. Within the GitHub HTML, a search box then appears. This is it working in Chromium:

https://user-images.githubusercontent.com/2480569/103411935-217b8f00-4b73-11eb-91db-a2fd5747202a.mp4

This does not work for me on Falkon:

https://user-images.githubusercontent.com/2480569/103412031-83d48f80-4b73-11eb-9afc-4e87f8b9abac.mp4

As you can see, for a split second the GitHub search box appears but then Falkon's own search steals its focus, making it close. And the Falkon search does not find anything on that page.

Can you reproduce?

Version: Mozilla/5.0 (X11; FreeBSD amd64; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Falkon/3.1.0 Chrome/80.0.3987.163 Safari/537.36

probonopd commented 3 years ago

Unlike with Adblock Plus I do get Promoted posts on Twitter. This is without changing any ad blocker related settings.

probonopd commented 3 years ago

Regarding https://github.com/helloSystem/ISO/issues/60#issuecomment-752135518:

Maybe @koobs knows or can find out whether there is any way to get a special build variant with only the minimal dependencies into FreeBSD packages? In helloSystem we would like to use this package but without all the dependencies that are not absolutely necessary. And we really would like not to build FreeBSD binary packages just for helloSystem, but rather use what is in FreeBSD packages.

Another such case would be https://github.com/helloSystem/ISO/issues/64.

koobs commented 3 years ago

@probonopd Two options:

1) A flavour for the existing port, similar to git-lite, that disables unnecessary dependencies, or unsets certain OPTIONS 2) A new sub-port off the main one, that disables unnecessary dependencies, or unsets certain OPTIONS

If there's a good case to be made for the value of a special flavor/variant for the existing port for users, I'd go with (1) and fallback to (2) in the event of unfavourable outcomes

probonopd commented 3 years ago

Yes @koobs a -lite flavor is what I had in mind. Looking at the Makefile:

OPTIONS_DEFINE= GNOMEKEYRING KDEINTEGRATION
OPTIONS_DEFAULT=        KDEINTEGRATION
OPTIONS_SUB=    YES

It seems that all we would need would be the KDEINTEGRATION option to be disabled for the -lite build .

Based on this information, what would be the best way to get a -lite build going?

Looking at https://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/makefile-options.html it seems to me that having a KDEINTEGRATION knob that would work not only for Falkon but for many KDE applications would be a very worthwhile thing to have, given that many KDE applications would be perfectly useful as standalone applications outside of KDE Plasma (in fact, many KDE applications have most users outside of KDE Plasma, such as on Windows.) One example would be #64.

image

probonopd commented 3 years ago

Also check the viability of https://qutebrowser.org/.

qutebrowser is a keyboard-focused browser with a minimal GUI. It’s based on Python and PyQt5

This would have the advantage that it could be hacked on without the need for compilation, and could be totally customized for helloSystem.

Since all the heavy lifting happens in QtWebEngine... maybe it could be viable?

Update: Tested it quickly. It's too "keyboard oriented". Has not even a URL bar. But the idea of building a browser around

py37-qt5-webkit

...tempting.

grahamperrin commented 3 years ago

qutebrowser

too "keyboard oriented".

+1

I love its minimalism and I half-tried to get into it a few months ago, maybe with the help of an on-screen cheat sheet, but it's not something that I'd bundle as a default browser.

probonopd commented 3 years ago

How can we add our own search provider to Falkon preconfiguration?

https://github.com/KDE/falkon/blob/94a635c3480fe0d8174f0bc82a72b331052a5ecd/src/lib/opensearch/searchenginesmanager.cpp#L159-L188

I would like to add https://github.com/search?q=org%3AhelloSystem+%s

grahamperrin commented 3 years ago

To identify the relevant file I included a unique word xylophone whilst adding the search engine, then sought the word after quit.

% pwd
/usr/home/grahamperrin/.config/falkon/profiles/default
% grep -R xylophone .
Binary file ./browsedata.db matches
% strings browsedata.db | grep xylophone
helloSystem at GitHub xylophonehttps://github.com/search?q=org%3AhelloSystem+%sAAAAIgBRAFAAaQB4AG0AYQBwAEkAYwBvAG4ARQBuAGcAaQBuAGUAAAABAAAAAYlQTkcNChoKAAAADUlIRFIAAAAQAAAAEAgGAAAAH/P/YQAAAAlwSFlzAAAOxAAADsQBlSsOGwAAAiRJREFUOI2NUzFrFEEU/ua93dwm3u7d7t4RA3aCYCFYnhqNWAYsbASLFLb5BzaWgp2iRVDBIoUpRGxsRRPFwkaw1iAKicnd7dyRnLnbmXkWuQ1LQJOvevP4vu9984ZROIR6vX6FmW8BuKZEZgBAlNoA8NZa+0JrvVrmq1LNjTh+zp63cNi0DGvMcjvLbgOwZQNO03TNI7rwP3EB49ynTqdzGYBlAGjE8bLHPJ8bszrK85vdLNsg5lOk1LaIdASobrfbd0Z5ftfzvDM+8+xkpXJ6sLf3ClEUtaabTZluNiVJkqXxkCqAqdLQapE2SZKlgh9FUYsmmBcP7mfts3G5A2BQMtgBIADgnFspmhPMiwTmWQCwzo0AdI6xgnXr3HB/czxLGD8VlNrs9XrrR6m11j+g1G8AgMgMFdEA1ADQMRIQROrjWkiAnwDAStXSNL1+lDqO43kmirA/+ReRUmtOBFvttnXGvIzD8NK/xEkYXmSip8VZRN5Rbszj0TCHiFjd7/d7u7sfiGgQRVGrIAZBcJWItv0g+MhEJ0sGj0hr/cWv+E+mm82Juu/PVavVhTAMPyultgpipVLZiaKoUU5jRR5kWfb14C8kcfyeiM5Z586LSF9rrUv8sJGmm0w0BQDWmNftLLuxv9Exulk2B6VWmOi7x/wNwEzJ4EQhNsbcK8QAwOVYg8HgzWQQ7EGphu/7y8Ph8A8A1Go1X4mcdcDDTrd7v6z5CyXu2gXXx9U2AAAAAElFTkSuQmCC/////wAAABAAAAAQAAAAAAAAAAE=
% 

– binary, so it might be unreasonably difficult to attempt pre-configuration.

probonopd commented 3 years ago

Well, if worst comes to worst we always have skel ;-)

probonopd commented 3 years ago

Seems to be a sqlite3 database. So probably editable with an sqlite3 editor.

probonopd commented 3 years ago

https://hellosystem.github.io/docs/user/components/applications/falkon

image

igalic commented 3 years ago

those examples (almost) all use g while demonstrating every search engine short cut

probonopd commented 3 years ago

Thanks @igalic, it is fixed on https://hellosystem.github.io/docs/user/components/applications/falkon

koobs commented 3 years ago

Yes @koobs a -lite flavor is what I had in mind. Looking at the Makefile:

OPTIONS_DEFINE= GNOMEKEYRING KDEINTEGRATION
OPTIONS_DEFAULT=        KDEINTEGRATION
OPTIONS_SUB=    YES

It seems that all we would need would be the KDEINTEGRATION option to be disabled for the -lite build .

Based on this information, what would be the best way to get a -lite build going?

  1. Existing port: Create an issue in bugzilla asking for a lite flavour to be added (with request to unset certain option sets), OR
  2. New port: Create an issue in bugzilla with a patch for a new port (based on the existing), but with a PKGNAMESUFFIX=lite and unsettting a certain option set (Ask in #freebsd-ports on freenode IRC if you need help
grahamperrin commented 3 years ago

https://github.com/helloSystem/ISO/issues/60#issuecomment-754213522

In lieu of:

bug Falkon

– use the standard prefix for a port-related bug, in this case:

bug www/falkon

Maybe also add a predefined shortcut for FreshPorts.

probonopd commented 3 years ago

No one knows the www/ part... at least I don't.

grahamperrin commented 3 years ago

It's the defined way of creating and seeking bugs for a port.

Click the two ladybird icons at (for example) https://www.freshports.org/sysutils/bsdisks/

probonopd commented 3 years ago

The ~/.config/falkon/profiles/default/browsedata.db file can be configured e.g, using https://sqliteonline.com/ or a local SQite editor indeed. This is useful eg., for clearing the file from unwanted tables/entries that we do not want to ship as preconfiguration.

Interestingly, this also allows one to set up autocompletion which is not possible through the Falkon UI as far as I know.

We might want to add autocompletion where it is possible, and may want to add a hello search keyword for the helloSystem documentation.

image

probonopd commented 3 years ago
% sudo pkg remove mysql57-server
Passwort: 
Checking integrity... done (0 conflicting)
Deinstallation has been requested for the following 6 packages (of 0 packages in the universe):

Installed packages to be REMOVED:
        (..)
        falkon: 3.1.0
        kaccounts-integration: 20.08.3
        (...)
        kf5-purpose: 5.74.0
        mysql57-server: 5.7.32

When a browser pulls in a MySQL server, then I'd say something is wrong...!

We really need a falkon-lite package.

For now, we are thin-installing Falkon, meaning there is a placeholder but the user has to download it before first use.

probonopd commented 3 years ago

Thanks @crees for creating:

www/falkon: add flavor without KDE integration https://reviews.freebsd.org/D29010

https://svnweb.freebsd.org/ports?view=revision&revision=567285

@crees on IRC:

this quarterly branch has the latest falkon on-- in a couple of days the pkg will be available

Thank you very much :+1:

probonopd commented 3 years ago

Based on http://pkg.freebsd.org/FreeBSD:12:amd64/quarterly/All/falkon-qtonly-3.1.0.txz by @crees I made an .app by essentially extracting the pkg into an .app bundle structure and patching it a bit so that it loads privately bundled libraries:

sed -i -e 's|/usr/local/lib|$ORIGIN/../lib|g' usr/local/bin/falkon
ln -s usr/local/lib .
rm usr/local/bin/falkon-e

This works without the need for patchelf because by coincidence the string /usr/local/lib has the exact same length as $ORIGIN/../lib. Lucky coincidence!

Here it is: https://github.com/helloSystem/ISO/releases/download/assets/Falkon_FreeBSD.zip Please go ahead and test that app on helloSystem ISOs wthout having installed Falkon from pkg beforehand.

It seems to run nicely on the helloSystem ISO, the only issue is that it doesn't find its assets for the theme (such as icons) and plugins, most likely because it is looking for them at a hardcoded absolute rather than relative path.

This would be possibly to patch by editing the source code. In fact, one would need to modify https://github.com/KDE/falkon/blob/master/src/lib/app/datapaths.cpp

We would need to replace QStringList QStandardPaths::standardLocations(QStandardPaths::AppDataLocation);. According to the Qt documentation, this resolves to "~/.local/share/<APPNAME>", "/usr/local/share/<APPNAME>", "/usr/share/<APPNAME>" but clearly /usr is not where these things are located in an .app bundle.

We could use QString QCoreApplication::applicationDirPath() instead and construct a relative path to ../share/falkon/... from there.

For an example, see: https://github.com/KaidanIM/Kaidan/commit/da38011b55a1aa5d17764647ecd699deb4be437f

As a result, it should work both in normal installations and in relocatable installations such as .app bundles.

probonopd commented 3 years ago

We need to optimize the preconfiguration of the ad blocking because the default is inferior to uBlock Origin:

grahamperrin commented 3 years ago

From https://github.com/helloSystem/ISO/issues/109#issuecomment-792950677:

(On a 4GB system, having 10-20 tabs open in the Falkon browser can lead to this situation for me - is this normal? I wonder whether Falkon is smart enough to purge the RAM for the background tabs...)

https://www.freshports.org/www/falkon/ ▶ … https://www.falkon.org/development/ ▶ … KDE bugs:

probonopd commented 3 years ago

Screen sharing non-functional at meet.jit.si (Jitsi Meet)

https://bugs.kde.org/show_bug.cgi?id=431004

@sgorava wrote:

Juraj 2021-04-03 19:54:48 UTC Hello,

Screen sharing is supported by QtWebEngine 5.10+

BUT Falkon does NOT have support for it and will not throw the right notification when this is requested.

Working on adding the support for these, will be done in few days (since my powerful machine is out of reach at the moment).

https://invent.kde.org/network/falkon/-/merge_requests/18/diffs

probonopd commented 3 years ago

It was merged: https://invent.kde.org/network/falkon/-/merge_requests/19

So the next version of Falkon should have Screen Sharing...

SGOrava commented 3 years ago

But according to qutebrowser it is somehow buggy with QtWE lower than 5.13.2. So in falkon for now (open to other ideas) it is available only when QTWE version is higher that 5.13.2.

Link to Qutebrowser solution: https://github.com/qutebrowser/qutebrowser/commit/a733fa9fd0af5438057fc791f6bd78b8a75a8ef5

PS: Since you summoned me.

probonopd commented 3 years ago

Thank you very much for chiming in ·@SGOrava. Do you have any idea what might be causing the missing icons in the second browser window and subsequent ones shown in https://github.com/helloSystem/ISO/issues/60#issue-775927580?

SGOrava commented 3 years ago

Do you have any idea what might be causing the missing icons in the second browser window and subsequent ones shown in #60 (comment)?

I have never encountered such a thing.
Can it be reproduced reliably?

probonopd commented 3 years ago

Yes... but only then QtPlugin is used and QT_QPA_PLATFORMTHEME=panda is set. Maybe the issue is there.

https://github.com/helloSystem/QtPlugin/issues/8

probonopd commented 2 years ago

Screen sharing non-functional at meet.jit.si (Jitsi Meet)

Do newer Falkon versions have this implemented now? https://invent.kde.org/network/falkon/-/merge_requests/18/diffs https://bugs.kde.org/show_bug.cgi?id=431004

Which Falkon version is the first one to contain the patch?

FreeBSD quarterly packages currently have

Maybe we should enquire in #falkon on IRC about a new version. It's a pity that this has been patched over half a year ago but there is no new release yet containing the fix.

TODO: Once a newer Falkon appears, test with https://vermaden.wordpress.com/2021/05/26/freebsd-desktop-part-26-configuration-conferencing-and-meetings/

Alternative: See whether a simple Jitsi Meet application can be made starting from Simple Browser.

grahamperrin commented 2 years ago

447448 – PDF content can not be zoomed in or out

For the given workaround, there's no build-time option:

% cat /usr/local/etc/poudriere.d/options/www_falkon/options 
# This file is auto-generated by 'make config'.
# Options for falkon-3.1.0_1
_OPTIONS_READ=falkon-3.1.0_1
_FILE_COMPLETE_OPTIONS_LIST=GNOMEKEYRING
OPTIONS_FILE_SET+=GNOMEKEYRING
% 

Failure to zoom is an accessibility issue.

Re: https://en.wikipedia.org/wiki/Google_Native_Client#Pepper I don't imagine any modern extension using the Pepper API, so (if possible) preconfigure Falkon in helloSystem to not enable the feature.

probonopd commented 2 years ago

Highlight downloaded file in file manager using D-Bus org.freedesktop.FileManager1.ShowItems

Reported upstream: https://bugs.kde.org/show_bug.cgi?id=460997

@SGOrava would you be willing to accept a patch via https://github.com/KDE/falkon/pulls? (I don't want to deal with the KDE infrastructure.)

SGOrava commented 2 years ago

Highlight downloaded file in file manager using D-Bus org.freedesktop.FileManager1.ShowItems

Reported upstream: https://bugs.kde.org/show_bug.cgi?id=460997

@SGOrava would you be willing to accept a patch via https://github.com/KDE/falkon/pulls? (I don't want to deal with the KDE infrastructure.)

That is just a mirror and pull requests are enabled probably because they cannot be disabled. If you do not want to deal with KDE things than send an email. In the mail you can either use git send-email or provide a link for the patch. I am willing to download it from even Github but I do not come here often, maybe once in a loooooooong while.