Comments (10)
The error is quite descriptive itself: your system doesn't provide the required environment variable - XDG_DATA_HOME
.
The Frog implies having access to this var because of https://docs.flatpak.org/es/latest/conventions.html#xdg-base-directories.
You could try to put it in your profile to make Frog work properly.
from frog.
Ah, turns out user directory variables are not set by default. I added them to my ~/.profile
.
โฏ echo $XDG_DATA_HOME
/home/yochanan/.local/share
However, I'm receiving the exact same error.
from frog.
If I run XDG_DATA_HOME="$HOME/.local/share/" frog
, I'm getting somewhere. However, it can't find eng.traineddata
because it's looking in /app/share/appdata/
instead of /usr/share/appdata/
or /usr/share/tessdata/
. It seems to be hardcoded in language_manager.py
.
Traceback (most recent call last):
File "/usr/bin/frog", line 52, in <module>
sys.exit(main.main(VERSION))
File "/usr/lib/python3.9/site-packages/frog/main.py", line 121, in main
app = Application()
File "/usr/lib/python3.9/site-packages/frog/main.py", line 61, in __init__
language_manager.init_tessdata()
File "/usr/lib/python3.9/site-packages/frog/language_manager.py", line 163, in init_tessdata
copyfile(source_path, dest_path)
File "/usr/lib/python3.9/shutil.py", line 264, in copyfile
with open(src, 'rb') as fsrc:
FileNotFoundError: [Errno 2] No such file or directory: '/app/share/appdata/eng.traineddata'
It appears it's trying to copy eng.traineddata
from /usr/share/appdata/
to ~/.local/share/tessdata/
. I copied it there manually and the application runs.
However, selecting Grab the area closes the window and does not allow me to select anything.
(frog:616852): Gtk-CRITICAL **: 12:27:10.731: gtk_bin_remove: assertion 'priv->child == child' failed
Cache downloaded codes, ['eng']
ERROR: g-dbus-error-quark: GDBus.Error:org.freedesktop.DBus.Error.AccessDenied: SelectArea is not allowed (9)
Traceback (most recent call last):
File "/usr/lib/python3.9/site-packages/frog/window.py", line 221, in on_shot_error
self.on_screenshot_error(error)
TypeError: on_screenshot_error() missing 1 required positional argument: 'error'
from frog.
Soon I'll release new version to Flathub. It won't require access to the home folder and also use libportal to take screenshots. I'm not the user of Manjaro but hope it will help.
from frog.
Sounds good. ๐
Technically, my issue has nothing to do with Manjaro or any other distribution. The point is, it isn't currently compatible with installing from source code using sane specifications and guidelines.
from frog.
Ah, that's true. I designed it specifically for elementary OS and have no thought on support the other distros. But the time has come and the Frog is moving towards any compatible (I mean with Screenshot Portal) distro.
from frog.
It's working now with the latest commit with a couple workarounds. Here's my PKGBUILD.
from frog.
FYI, I've added it to the AUR as frog-ocr
and let users know they need to set the XDG_DATA_HOME
variable.
from frog.
Actually, Frog doesn't use XDG_DATA_HOME since 1.0 so doesn't need that notice :)
from frog.
What do you mean? If ~/.local/share/tessdata/eng.traineddata
does not exist it's created on launch. Without the variable set, it can't find where to create it.
Not sure why it needs to do that at all as it's in /usr/share/tessdata/
as part of tesseract-data-eng
.
from frog.
Related Issues (20)
- [Bug] local installation fails to launch HOT 2
- Error in language_row.py module HOT 6
- Detection of non-latin characters HOT 1
- Feature request: pasting an image HOT 1
- [Bug] Failed to extract text from screenshot HOT 2
- Quick snip and copy to clipboard HOT 1
- TypeError: init() missing 1 required positional argument: 'argv' HOT 4
- Localization needs an update HOT 1
- Flathub version uses GNOME 41 HOT 2
- Issue with italian translation. HOT 1
- Awareness Be in company In one goal #log(x^2) ......โยฐfire
- Make it possible to 'Select an area' as the default while making a screenshot HOT 1
- 1 name: Renli 2 on : [push,pull_request] 3 jobs: 4 renli 5. runs-on: ubuntu-latest 6. steps: 7. -uses:action/checkout@v3 8 -uses:chartboost/renli-@v1 9 ID 10 Birth day 11 Birth place #resume #log =scientific = 1know problem 2gadering data3procedure4obsevation5testing hypothesis 6verify conclusion HOT 1
- Language pack download fails HOT 1
- Append preference for the screenshot saving path HOT 3
- Remember the last choice HOT 1
- Pause text playback
- Ask user to star app on Github
- *438.951.276*โ#/ROOT/###6 ++010100-@MMm NEOM London... โโ[rOt]\ =work =ยถยฎ
- Local offline processing vs. network service HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from frog.