Code Monkey home page Code Monkey logo

Comments (7)

Croman12 avatar Croman12 commented on June 4, 2024

Okay so a lot of progress since yesterday. When I manually run the file with the parameter for telegram, I receive a test message on Telegram. There was an error though, and I'm not sure what it means:

`Warning (from warnings module):
File "C:\Users\NAME\AppData\Roaming\Python\Python39\site-packages\apprise\utils.py", line 704
pmatch = re.search(
FutureWarning: Possible nested set at position 12
2022-04-27 00:19:32,082 - 2084 - INFO - Notifying 1 service(s) asynchronously.
2022-04-27 00:19:32,246 - 2084 - INFO - Sent Telegram notification.

`

In NZBGet I still cannot run is and I get the same error message as before, it has to be something with the quotation marks or with how NZBGet is running the script. I run NZBGet as a service as my local Administrator account.

I'm thinking about reinstalling Python on a C:\Python path and hoping it solves the problem, but I'm afraid that I break other scripts that rely on Python.

Again, any help is greatly appreciated, especially since I feel I'm really close now.

EDIT: So I pretty much reinstalled NZBGet and Python. The script works now when I'm running it via Python myself and I receive the test message. The problem is that in NZBGet, I still get this error message:

Executing script Notify.py with command TestServers
Notify: C:\Python310\python.exe: can't open file 'C:\Windows\system32\L': [Errno 2] No such file or directory Script Notify.py with command TestServers failed (terminated with unknown status)

from nzb-notify.

caronc avatar caronc commented on June 4, 2024

Seems like you may not have the Notify.py script in the correct directory. Also reload NZBGet so it can see it (once you've placed it).

You will be able to run tests right from in NZBGet once this is all in place.

If you can run from the command line then you're halfway there for sure. NZBGet needs to be able to access your python.exe file on your PC. Make sure it's in the path and/or configured in NZBGet.

from nzb-notify.

Croman12 avatar Croman12 commented on June 4, 2024

I finally did it. I don't know why, because everything in environment is not directing at all to the system32 folder, but apparently something is still looking for it. I put ".py=C:\Python310\python.exe" in shell override option in nzbget, and everything is working now. Thank you for your help and response!

One quick question, when a download finishes, all the script sends is a picture or should there also be some text in the message?

from nzb-notify.

caronc avatar caronc commented on June 4, 2024

Yes, you should receive text as well. What notification service are you using? In NZBGet you can also send a test notification to make sure it's all hooked up properly.

from nzb-notify.

Croman12 avatar Croman12 commented on June 4, 2024

I use Telegram. When a download starts, I get a notification saying "New file queued for download "NZB". But when the download is finished, I only get the succes image (apprise-success-128x128.png).

EDIT: I checked the logs in NZBGET, this is what I get when a nb if queued:

info Wed Apr 27 2022 15:24:41 Notify: Sent Telegram notification.
info Wed Apr 27 2022 15:24:41 Notify: Notifying 1 service(s) asynchronously.
info Wed Apr 27 2022 15:24:41 Notify: pmatch = re.search(
info Wed Apr 27 2022 15:24:41 Notify: C:\Python310\lib\site-packages\apprise\utils.py:704: FutureWarning: Possible nested set at position 12

This is when the download is finished:

info Wed Apr 27 2022 15:28:37 Post-process-script Notify.py for FILENAME successful
warning Wed Apr 27 2022 15:28:37 Notify: Failed to send Telegram notification to -CHATID: Bad Request: can't parse entities: Unsupported start tag "ul" at byte offset 143, error=400.
info Wed Apr 27 2022 15:28:36 Notify: Notifying 1 service(s) asynchronously.
info Wed Apr 27 2022 15:28:36 Notify: pmatch = re.search(
info Wed Apr 27 2022 15:28:36 Notify: C:\Python310\lib\site-packages\apprise\utils.py:704: FutureWarning: Possible nested set at position 12
info Wed Apr 27 2022 15:28:36 Notify: NZBParse - NZB-File parsed 2 meta entries
info Wed Apr 27 2022 15:28:36 Notify: NZB-File detected: FILENAME.nzb.queued

And what I receive is this (there is nothing missing at the bottom, this is everything):

https://imgur.com/a/Z4b4pPj

from nzb-notify.

caronc avatar caronc commented on June 4, 2024

I did a mini-release of Apprise to fix this here. I believe we're good.

pip install -u apprise and try again.

from nzb-notify.

Croman12 avatar Croman12 commented on June 4, 2024

So I tried what u suggested, i updated apprise (version is now 0.9.8.3). I downloaded a file and all I get on succesful download is still the picture. But the log in NZBGet changed, this is how it looks like now:

info Fri Apr 29 2022 18:44:46 Post-process-script Notify.py for FILENAME successful
warning Fri Apr 29 2022 18:44:46 Notify: Failed to send Telegram notification to -CHATID: Bad Request: can't parse entities: Unsupported start tag "ul" at byte offset 143, error=400.
info Fri Apr 29 2022 18:44:46 Notify: Notifying 1 service(s) asynchronously.
info Fri Apr 29 2022 18:44:46 Notify: NZBParse - NZB-File parsed 0 meta entries
info Fri Apr 29 2022 18:44:46 Notify: NZB-File detected: FILENAME.nzb.queued
info Fri Apr 29 2022 18:44:44 Executing post-process-script Notify.py for FILENAME

from nzb-notify.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.