Comments (6)
Hello,
Looks like the links are not preserved when you clone the repo. The USD currency flag is a symbolic link to US flag.
Looks like git converted USD.svg to a file containting US.svg.
On my computer I am developing locally so it works.
Probably you can confirm this if you copy the US flag to USD currency and restart the launcher.
Also the flags with "time" command should work because they are not symlinks.
cp ~/.local/share/ulauncher/extensions/com.github.tchar.ulauncher-albert-calculate-anything/images/flags/US.svg \
~/.local/share/ulauncher/extensions/com.github.tchar.ulauncher-albert-calculate-anything/images/flags/USD.svg
Now for this to be solved there are 2 ways I guess:
- create copies of all currency flags instead of symlink
- resolve the symlink problem with git
Give me an hour or two shouldn't be that hard to fix
from ulauncher-albert-calculate-anything.
Hello again @Laar3
So I found the issue. If you clone the repo directly to ulauncher extensions through git clone, it works perfectly.
For some reason when you install the extension through ulauncher it doesn't do normal git clone and just copies the contents of the file (in case of symlinks it is the name of the linked file), so you end up with normal text files.
#3 fixes this, please confirm that after you update the extension currency flags are showing.
from ulauncher-albert-calculate-anything.
Hello again @Laar3
So I found the issue. If you clone the repo directly to ulauncher extensions through git clone, it works perfectly.
For some reason when you install the extension through ulauncher it doesn't do normal git clone and just copies the contents of the file (in case of symlinks it is the name of the linked file), so you end up with normal text files.#3 fixes this, please confirm that after you update the extension currency flags are showing.
ive updated but now the currency conversion doesnt do anything at all (all other functions work though) after this i tried removing the extension and manually git cloneing to the .local/share/ulauncher/extensions and the currency conversion still wouldnt work
from ulauncher-albert-calculate-anything.
from ulauncher-albert-calculate-anything.
@Laar3
I should create a logger indipendently from ulauncher because it is not enough as the project grew in size.
All right that's a different issue. Normally if you go to extension preferences disable cache (set to None
) hit save
and then reenable it (hit Save
again) it will fix but if you have the time to give me some logs to fix this generally I would really appreciate it.
If you want to provide the logs read below. In any case please tell me if the issue was fixed after this.
First you can check the cache of the extension.
It should be in ~/.cache/extension_calculate_anything/
and normally you can find 2 files there. One of them should be called currency_data.json
. Can you open that file and confirm the contents with me?
I suspect that the last update timestamp is relatively new and the exchange rates are empty.
If the file is too big you can use this snippet to get the info from currency_data.json
python -c "import os,json;f=open(os.path.expanduser('~/.cache/extension_calculate_anything/currency_data.json'));d=json.loads(f.read());f.close();p=d.get('provider');t=d.get('last_update_timestamp');c=d.get('exchange_rates');print('provider={},timestamp={},currencies={}'.format(p, t, len(c) if c is not None else None))"
Normally by deleting the file and restarting ulauncher it should work.
However to get the proper logs so that I can find out what went wrong before deleting the file close ulauncher and open it in dev mode with no extensions
ulauncher --no-extensions --dev -v |& grep calculate-anything
Open a new terminal and type the VERBOSE
command you see above. Alternatively you can find this command under the extension's preferences when you open ulauncher in dev mode. Should look like this
VERBOSE=1 ULAUNCHER_WS_API=ws://127.0.0.1:5054/com.github.tchar.ulauncher-albert-calculate-anything PYTHONPATH=/usr/lib/python3/dist-packages /usr/bin/python3 ~/.local/share/ulauncher/extensions/com.github.tchar.ulauncher-albert-calculate-anything/main.py
Redirect the log to a file by adding 2>&1 | tee ~/ulauncher-calculate-anything.log
. So the final command should look like this.
VERBOSE=1 ULAUNCHER_WS_API=ws://127.0.0.1:5054/com.github.tchar.ulauncher-albert-calculate-anything PYTHONPATH=/usr/lib/python3/dist-packages /usr/bin/python3 ~/.local/share/ulauncher/extensions/com.github.tchar.ulauncher-albert-calculate-anything/main.py 2>&1 | tee ~/ulauncher-calculate-anything.log
You should see some logs in your terminal.
Type the currency conversion that fails in ulauncher
and then close the terminal and post the logs at ~/ulauncher-calculate-anything.log
over here.
Thanks for taking the time to help me resolve this.
from ulauncher-albert-calculate-anything.
Issue has been marked as stale due to no activity
from ulauncher-albert-calculate-anything.
Related Issues (20)
- [bug] Extension crashed after updating and saving new settings and then crashes instantly on reload HOT 12
- Cannot install the extension HOT 2
- Proxy support [feature] HOT 2
- [feature] Enhance time with specific time/date and timezone conversion HOT 2
- Not working HOT 2
- [feature] Converstion of time to time unit like ms HOT 4
- [bug] HOT 4
- [bug] HOT 6
- [bug] zombie process HOT 9
- An option to make outbound calls on-demand (or disable it totally) HOT 4
- [feature] Use the word "in" as alias for "to" in conversions HOT 6
- [bug] Crashed on Ulauncher 5.14.4 HOT 4
- [bug] Calculation error sin(2*pi) HOT 2
- [bug] Crashed on Ulauncher 5.14.7 HOT 2
- Extension stopped converting: 'currency' is not defined in the unit registry HOT 16
- [bug] If pint is not installed, suggest user restarts ulauncher after install HOT 10
- [bug]Need update on plugin as per the new version of Albert 0.18.10 HOT 2
- Nothing but math is working HOT 13
- [feature] Timestamp calculation (not from today) HOT 1
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 ulauncher-albert-calculate-anything.