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

pync was not properly installed #41

Open
KvashaIhor opened this issue Sep 5, 2018 · 3 comments
Open

pync was not properly installed #41

KvashaIhor opened this issue Sep 5, 2018 · 3 comments
Assignees
Labels

Comments

@KvashaIhor
Copy link

KvashaIhor commented Sep 5, 2018

Hi
I have an "Exception: pync was not properly installed. Head over to https://github.com/SeTeM/pync/ and file a bug." during compiling program with py2app. I've installed an actual version from github, but it didn't work. Also I found here a bug issue #17, but I dont even have this files on package directories.
That's my first topic, so I'll also put my code there, may be it will be useful.

import clipboard
import pync
import time

with open('таблицапринтов.txt') as f:
    content = f.readlines()
content = [x.strip() for x in content]
keydict = {}
for i in range(len(content)):
    k=content[i]
    test = content[i].split()
    keydict[test[0]] = test[len(test)-1]
check=0
while True:
    time.sleep(1.5)
    text = clipboard.paste()
    if not text==check:
     if text in keydict.keys():
        pync.notify('Ссылка в буфере', appIcon='right.png', title='PrintSearch')
        clipboard.copy(keydict[text])
        check=text
     elif not text in keydict.values():
        pync.notify('Ссылки нет в базе', appIcon='wrong.png', title='PrintSearch')
        check=text
  • default setup.py py2app file
    Pls help
@maxkrivich
Copy link
Collaborator

@KvashaIhor any updates? I will check this issue asap.

@maxkrivich maxkrivich self-assigned this Oct 16, 2018
@maxkrivich maxkrivich added the bug label Oct 16, 2018
@edgar-costa
Copy link

The problem is that it goes to get the terminal-notifier app to the wrong path since you use:

else:
            self.app_path = os.path.join(
                os.path.dirname(__file__),
                "vendor/terminal-notifier-%s/terminal-notifier.app" % self.TERMINAL_NOTIFIER_VERSION

The package gets installed in the site-packages dir, and the terminal-notifier does not get copied there.

There is a way to force the package to be installed in the same exact path than the original files are, and then the path is added to sys.path:

pip install -e "." (while you are in the source code root path)

@phirestalker
Copy link

pip install -e "." did not work for me. I still get the error when running a program packaged with py2app. What else can I try?

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

No branches or pull requests

4 participants