-
Notifications
You must be signed in to change notification settings - Fork 69
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
Fix OSX Compatibility Issues (workarounds included) #63
Comments
Amazon-dash has not been tested on OS X. The Amazon-dash installer does not support OSX. The installer is for Linux so you can ignore the installation step. |
It has now and it works great! I made it turn on my spotify on my machine for fun. With a couple of tweaks and a bit of docs, it would be usable by a lot of devs. |
In a next version I will make sure that there is no error in the installation process. Thank you. Does it work in OS X then? Does the discovery command work for you? |
Yep! I had a dash button make spotify play (using hnarayanan/shpotify cli project). |
Thank you :) |
Can you please give me the exception traceback of this code in OSX?
|
Traceback (most recent call last):
File "/usr/local/bin/amazon-dash", line 6, in <module>
catch(cli)()
File "/usr/local/lib/python2.7/site-packages/amazon_dash/exceptions.py",
line 91, in wrap
return fn(*args, **kwargs)
File "/usr/local/lib/python2.7/site-packages/click/core.py", line 722, in
__call__
return self.main(*args, **kwargs)
File "/usr/local/lib/python2.7/site-packages/click/core.py", line 697, in
main
rv = self.invoke(ctx)
File "/usr/local/lib/python2.7/site-packages/click/core.py", line 1066,
in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/local/lib/python2.7/site-packages/click/core.py", line 895, in
invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python2.7/site-packages/click/core.py", line 535, in
invoke
return callback(*args, **kwargs)
File "/usr/local/lib/python2.7/site-packages/amazon_dash/management.py",
line 100, in run
Listener(config).run(root_allowed=root_allowed)
File "/usr/local/lib/python2.7/site-packages/amazon_dash/listener.py",
line 119, in __init__
self.config = Config(config_path)
File "/usr/local/lib/python2.7/site-packages/amazon_dash/config.py", line
206, in __init__
group=get_file_group(file), perms=os.stat(file).st_mode & 0o777,
File "/usr/local/lib/python2.7/site-packages/amazon_dash/config.py", line
141, in get_file_group
return getgrgid(os.stat(file).st_uid)[0]
KeyError: 'getgrgid(): gid not found: 502'
…On Wed, Jul 18, 2018 at 11:04 AM, Nekmo ***@***.***> wrote:
Can you please give me the exception traceback of this code in OSX?
(not os.getuid() and not only_root_write(file)) or oth_w_perm(file):
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#63 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AA4YTu-Qq_eXn7tUhHDOeDeFg4ccQqtkks5uH3jLgaJpZM4VU5m3>
.
|
OK thanks. I'm going to submit a patched version in the development branch. Please tell me if it works for you. |
Thanks!
…On Wed, Jul 18, 2018 at 11:14 AM, Nekmo ***@***.***> wrote:
OK thanks. I'm going to launch a patched version in the development
branch. Please tell me if it works for you.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#63 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AA4YTsrfF88xf6PsOUJ3PXKf3LCFa7UYks5uH3sGgaJpZM4VU5m3>
.
|
Please install It using: pip install https://github.com/Nekmo/amazon-dash/archive/develop.zip Remember to fix the permissions of the Amazon-dash configuration file: chmod 660 amazon-dash.yml && chown root:root amazon-dash.yml Thanks. |
```chown root:root amazon-dash.yml
chown: root: illegal group name
```
this is the issue, the group on osx can't be root. If we're being this
specific, wouldn't 600 suffice? Ignore the group?
…On Wed, Jul 18, 2018 at 11:22 AM, Nekmo ***@***.***> wrote:
Please install It using:
pip install https://github.com/Nekmo/amazon-dash/archive/develop.zip
Remember to fix the permissions of the Amazon-dash configuration file:
chmod 660 amazon-dash.yml && chown root:root amazon-dash.yml
Thanks.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#63 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AA4YTqbdfSZfCGV3xg_WQh6C-JtJ48bUks5uH3z9gaJpZM4VU5m3>
.
|
Yes, change |
Ok pip install goes:
|
I just launched a new release. I'm going to check it, thanks. |
Please run in your system:
|
➜ tmpluceedockerwgroovy python --version
Python 2.7.10
➜ tmpluceedockerwgroovy easy_install --version
setuptools 18.0.1
➜ tmpluceedockerwgroovy pip --version
pip 9.0.1 from /usr/local/lib/python2.7/site-packages (python 2.7)
…On Wed, Jul 18, 2018 at 4:30 PM, Nekmo ***@***.***> wrote:
Please run in your system:
easy_install --version
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#63 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AA4YTogGe2vIopf4_XyG2MtLLtQVG09dks5uH8UkgaJpZM4VU5m3>
.
|
Your Setuptools version is old (24 Jun 2015), you can upgrade It using: pip install -U setuptools Thanks for notifying. |
then to run
(daemon running) hit the Cascade button and spotify played my song. Thanks! Looks good! |
Thanks for your help :) |
1.0.4
2.7.10
OSX 10.13.4
Description
I tried to run this on OSX. It errors during the install step trying to determine whether I have systemd and during the run step trying to write an error message about the write permissions of the config file, because root is not a valid group.
What I Did
During install it bombs here:
return check_output(['ps', '--no-headers', '-o', 'comm', '1']).strip(b'\n ').decode('utf-8')
So I commented out line 99 in the init of the
install
path re:#if get_init_system() != 'systemd' or not get_systemd_services_path():
which makes it just raise an exceptionraise IsInstallableException('Systemd is not available')
. This is fine though, because that exception is still a successful installation path re: "You must run it manually". I'm just developing on this machine, I'll run everything manually.Then I discovered my dash button mac, and wrote a config file.
When I ran it, it complained about being unable to read a group, which turns out to be in the error handling code. I don't think I care about file permissions at all, least of all write perms. Maybe this should just be a warning?
I commented out all the write permissions error code
It works fine.
Thanks for the program yo.
The text was updated successfully, but these errors were encountered: