Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display exchange rate conversions in multiple currencies at once #1

Closed
robertmircea opened this issue Dec 31, 2019 · 12 comments
Closed
Labels
enhancement New feature or request

Comments

@robertmircea
Copy link

I would like to make the following suggestion for making currency conversions more useful.

Instead of showing only the base currency conversion when target currency is skipped, it would be very useful to be able to define a list of currencies to be displayed in the results apart of base currency. Of course, the base currency should be displayed first.

As an example:
typing
100 jpy

would produce the following results:

3.91 RON
1 JPY = 0.039 RON

0.82 EUR
0.92 USD
0.70 GBP
[etc]
@biati-digital biati-digital added the enhancement New feature or request label Jan 3, 2020
@biati-digital
Copy link
Owner

Hi, that seems doable, I'll take a look at this as soon as I have some free time

@biati-digital
Copy link
Owner

Version 2.0.0 is out, in this new version you can define multiple base currencies, please check the README.

Please note this new version is a complete rewrite so some things will look different.

@robertmircea
Copy link
Author

I've updated to latest version, but unfortunately is crashing when trying to add a new base currency beside the existing one.

Screenshot 2020-05-18 at 10 42 46

@biati-digital
Copy link
Owner

Sorry about that, did a few tests and everything was working fine, I've no idea what happened to the missing "r" in merge. Anyway I've released and update and improved action modifiers, more in the docs.

@robertmircea
Copy link
Author

Thanks for the update. I've managed to add a secondary base currency, but now when trying to convert, no reply is given:

For example, I have RON and EUR as base currencies set. If I enter "100 usd", no results are returned. I was expecting to see 100 usd converted both in RON and in EUR.

If I explicitly enter "100 usd eur", the conversion works.

A second issue: when adding a base currency, the app is case sensitive meaning that I can add both "eur" and "EUR"

@biati-digital
Copy link
Owner

Hi @robertmircea thank's for trying the update, I'm not able to replicate the errors you mention

1.- https://ibb.co/ypkBW2h

The second issue you mention also should not be happening, if you check the code it does not matter if you enter ron or RON, the code will convert the entered text to uppercase create an array with all the elements, remove duplicates and finally save the configuration.

¿Are you using the latest version?
¿Could you please try to remove all the currencies and add them again?

You can also try to remove the cache, in /youruser/Library/Application Support/Alfred/Workflow Data/com.alfred.calculateanything/ and delete the folder cache. This should not be necessary but you can try it.

@robertmircea
Copy link
Author

robertmircea commented May 22, 2020

I've cleared the cache and it seems to work (partially) meaning:

  1. I have EUR and RON as base currencies
  2. if I enter "100 EUR" or "100 RON", it does NOT display the conversion result in base currencies
  3. if I enter "100 usd" (or any other non-base currency), the conversion result is displayed correctly in both EUR and RON base currencies.
  4. If I enter "100 EUR to RON", it works as expected and displays the result.

The expected result would be that 2) displays the conversion result in all base currencies. Ex. "100 EUR" would display both "100 EUR" and "484 RON".

2020-05-22 23 20 55

@biati-digital
Copy link
Owner

Still, I'm not able to replicate the error.

Screen Shot 2020-05-23 at 17 49 02

Can you please enable debug (see image) and then type 100 eur and share with me the output of the debug window?
Screen Shot 2020-05-23 at 17 51 23

Also can you tell me which version of Mac OS are you using? Catalina, Mojave, etc.

@robertmircea
Copy link
Author

When I type 100 EUR this is the debug info logged. I've also tried "100 EUR RON" after which works.

[14:25:44.456] Calculate Anything[Script Filter] Queuing argument ''
[14:25:44.568] Calculate Anything[Script Filter] Queuing argument '0'
[14:25:44.594] Calculate Anything[Script Filter] Script with argv '(null)' finished
[14:25:44.596] Calculate Anything[Script Filter] {"items": []}
[14:25:44.728] Calculate Anything[Script Filter] Queuing argument '00'
[14:25:44.738] Calculate Anything[Script Filter] Script with argv '(null)' finished
[14:25:44.740] Calculate Anything[Script Filter] {"items": []}
[14:25:44.860] Calculate Anything[Script Filter] Script with argv '(null)' finished
[14:25:44.862] Calculate Anything[Script Filter] {"items": []}
[14:25:45.086] Calculate Anything[Script Filter] Queuing argument '00 '
[14:25:45.220] Calculate Anything[Script Filter] Script with argv '(null)' finished
[14:25:45.222] Calculate Anything[Script Filter] {"items": []}
[14:25:45.333] Calculate Anything[Script Filter] Queuing argument '00 E'
[14:25:45.483] Calculate Anything[Script Filter] Script with argv '(null)' finished
[14:25:45.485] Calculate Anything[Script Filter] {"items": []}
[14:25:45.513] Calculate Anything[Script Filter] Queuing argument '00 EU'
[14:25:45.625] Calculate Anything[Script Filter] Queuing argument '00 EUR'
[14:25:45.649] Calculate Anything[Script Filter] Script with argv '(null)' finished
[14:25:45.652] Calculate Anything[Script Filter] {"items": []}
[14:25:46.000] Calculate Anything[Script Filter] Script with argv '(null)' finished
[14:25:46.006] Calculate Anything[Script Filter] {"items": "\"error\":\"Symbols 'EUR' are invalid for date 2020-05-24.\"" }
[14:25:46.007] ERROR: Calculate Anything[Script Filter] JSON is missing expected keys; items, variables or rerunafter:
{"items": "\"error\":\"Symbols 'EUR' are invalid for date 2020-05-24.\"" }
[14:25:51.297] Calculate Anything[Script Filter] Queuing argument '00 EUR '
[14:25:51.671] Calculate Anything[Script Filter] Script with argv '(null)' finished
[14:25:51.677] Calculate Anything[Script Filter] {"items": "\"error\":\"Symbols 'EUR' are invalid for date 2020-05-24.\"" }
[14:25:52.039] Calculate Anything[Script Filter] Queuing argument '00 EUR R'
[14:25:52.128] Calculate Anything[Script Filter] Queuing argument '00 EUR RO'
[14:25:52.176] Calculate Anything[Script Filter] Script with argv '(null)' finished
[14:25:52.183] Calculate Anything[Script Filter] {"items": []}
[14:25:52.310] Calculate Anything[Script Filter] Script with argv '(null)' finished
[14:25:52.316] Calculate Anything[Script Filter] {"items": []}
[14:25:52.331] Calculate Anything[Script Filter] Queuing argument '00 EUR RON'
[14:25:52.463] Calculate Anything[Script Filter] Script with argv '(null)' finished
[14:25:52.473] Calculate Anything[Script Filter] {"items": [{"title":"484.35RON","subtitle":"1EUR = 4.84RON","arg":"484.35","icon":{"path":"flags\/RON.png"},"mods":{"cmd":{"valid":true,"arg":484.35,"subtitle":"Action this item to copy the amount with no format"},"alt":{"valid":true,"arg":4.84,"subtitle":"Action this item to copy the value of 1 to the clipboard"}}}] }

@biati-digital
Copy link
Owner

there's a new update that fixes some bugs, please try it and let me know if it's working for you.

@robertmircea
Copy link
Author

For me it still doesn't work after reinstall from scratch and cache folder erase. I give up if it works for other users.

@biati-digital
Copy link
Owner

Ok, I understand, if you don't want to keep trying I'll close this issue for now. Feel free to open a new issue if you need some help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants