Comments (7)
Thanks for reporting this.
I'm currently on vacation now, I'll take a look whenever I'm available. If you already have ideas on fixing, you can draft a PR.
from coinc.
@kamusis I just uploaded an v2 release candidate, please help test it out and share your upgrade experience (There should be dialogue indicate to a help page). If everything went well, I'll drop the pre-release tag.
from coinc.
@tomy0000000 Thank you for the fixing. First of all, all the "cur" command looks perfect now, running smoothly in python3!
but I'm not sure why you decide to check a hardcoding python3 path: /usr/local/bin/python3?
In "V2 migration guide", you mentioned only support homebrew, but on my laptop, python3 is in
❯ which python3
/opt/homebrew/bin/python3
I'm using M1 silicon Macbook Pro, I believed that the default PATH has been changed between homebrew for x86 and for ARM.
My suggestion:
change "cur" script to:
if command -v python3 1>/dev/null 2>&1; then
python3 main.py convert $1
else
echo '{
"items": [
{
"title": "Manual Upgrade is required",
"subtitle": "Hit enter to open migration Guide on GitHub",
"valid": true,
"arg": "open,https://github.com/tomy0000000/Coinc/wiki/V2-Migration-Guide",
"icon": {
"path": "hints/info.png"
}
}
]
}'
fi
In workflow environment variables page, add a PATH variables, you can fill both python3 default path for x86 and ARM into it.
BTW: cur-add/cur-rm/cur-arr are also leaved in python not python3.
from coinc.
I'm using M1 silicon Macbook Pro, I believed that the default PATH has been changed between homebrew for x86 and for ARM.
The reason I decided to use the fixed path is to ensure that the python3
being used is indeed provided by homebrew. Therefore, I'm much prefer to hard code the path rather than having user to figure out how to configure.
I adapt [these] from homebrew installation script, which should be good enough to generate dynamic path. This is what I end up having:
UNAME_MACHINE="$(/usr/bin/uname -m)"
if [[ "${UNAME_MACHINE}" == "arm64" ]]
then
HOMEBREW_PREFIX="/opt/homebrew"
else
HOMEBREW_PREFIX="/usr/local"
fi
if command -v "$HOMEBREW_PREFIX/bin/python3" 1>/dev/null 2>&1; then
$HOMEBREW_PREFIX/bin/python3 main.py convert $1
else
echo '{
"items": [
{
"title": "Manual Upgrade is required",
"subtitle": "Hit enter to open migration Guide on GitHub",
"valid": true,
"arg": "open,https://github.com/tomy0000000/Coinc/wiki/V2-Migration-Guide",
"icon": {
"path": "hints/info.png"
}
}
]
}'
fi
BTW: cur-add/cur-rm/cur-arr are also leaved in python not python3.
That's my mistake, will fix it
I've updated the pre-release, please check it again if you will. :)
from coinc.
UNAME_MACHINE="$(/usr/bin/uname -m)"
check the infra at first is a good method. should be no problem.
I've updated the pre-release, please check it again if you will. :)
I tested the latest version, cur-add/cur-rm/cur-arr are not working, the error still is "python: command not found".
I modified 3 places manually, changed python to python3, now it's OK.
from coinc.
I tested the latest version, cur-add/cur-rm/cur-arr are not working, the error still is "python: command not found".
I modified 3 places manually, changed python to python3, now it's OK.
That is my mistake again, because there is no exception or error detection mechanism built on workflow part, so I did not spot those changes not applying during my own test.
rc3 should fix this issue now :)
from coinc.
Hi tommy, thank you again for the quick response and this amazing workflow 💯
I'll close the issue.
from coinc.
Related Issues (20)
- New bug?: a yellow "update" floating as the first line HOT 6
- [Errno 66] Directory not empty HOT 9
- Error in workflow 'Coinc' HOT 2
- Not getting exchange value HOT 3
- Not compatible with new M1 silicon macOS? HOT 1
- ETH not working @1.3.1 HOT 1
- Change base currency HOT 2
- Always show `Manual Upgrade is required` HOT 1
- Thousands separator HOT 4
- Update Wiki
- Some number trigger have wrong argument configuration
- Improve alias experience
- Alias will be overwritten when updating
- Alias doesn't work for lowercase English words HOT 10
- Error "Error in workflow 'Coinc'" HOT 3
- Error HOT 5
- Support for Number Input with Comma HOT 4
- Error on all operation - " KeyError: 'favorites' " HOT 3
- Please change the name of the workflow HOT 4
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 coinc.