Giter Club home page Giter Club logo

Comments (11)

DrWatson avatar DrWatson commented on September 27, 2024 2

Just to be clear, I modified the file __ init __.py found in /home/pi/oprint/lib/python2.7/site-packages/octoprint_emailnotifier and changed the line:

mailer.send(to=emails, subject=subject, contents=body, validate_email=False)

to

mailer.send(to=emails, subject=subject, contents=body)

Just in case someone else is looking for more direct instructions. You have to restart Octoprint for the changes to take affect.

from octoprint-emailnotifier.

jeffgolden avatar jeffgolden commented on September 27, 2024

Take a look at my pull request -- it appears that yagmail was recently changed and removed the validate_email parameter from the send method. The plugin is trying to reference that parameter in the send method, but it no longer exists. If you remove that parameter (it was set to False anyway) you can get the plugin to work.

from octoprint-emailnotifier.

MikeBrWade avatar MikeBrWade commented on September 27, 2024

@jeffgolden : Great response time, and yep that fixed the issue. Don't you love it when APIs change and mess up your code base! Thanks alot for the quick fix, and hopefully your pull is approved soon to keep others from dealing with this.

NOTE: I will leave the issue open until the pull is accepted (or is closed by the repo owner)

from octoprint-emailnotifier.

ItsMrChops avatar ItsMrChops commented on September 27, 2024

@DrWatson Thanks for your post, got me up and running!

from octoprint-emailnotifier.

hammiesam avatar hammiesam commented on September 27, 2024

@ItsMrChops Hey there, I can't for the life of me locate the init.py file in /home/pi/oprint/lib/python2.7/site-packages/octoprint_emailnotifier

what did you type in while connected via ssh to get to that file?

i'm also getting the "Sending failed. Reason:: send() got an unexpected keyword argument 'validate_email' " error.

Thanks!

from octoprint-emailnotifier.

ItsMrChops avatar ItsMrChops commented on September 27, 2024

I'm a Windows user and know next to nothing about Linux but found I could use Notepad++ and it's NppFTP plugin to connect with SFTP. It has a directory browser and editing files is really easy. I think the .py file name starts with _ maybe. Hope this helps.

from octoprint-emailnotifier.

hammiesam avatar hammiesam commented on September 27, 2024

@ItsMrChops oh wow, somehow i never thought to sftp into my pi to see the directory browser, I've been doing everything in the terminal the entire time! I've connected through sftp and made the change! I just need to wait for the print to finish up before I restart octoprint. Thank you for the tremendous tip!

from octoprint-emailnotifier.

ManuGithubSteam avatar ManuGithubSteam commented on September 27, 2024

This is the path for me:

~/OctoPrint/venv/lib/python2.7/site-packages/octoprint_emailnotifier

from octoprint-emailnotifier.

thauch avatar thauch commented on September 27, 2024

This was the location for me:
~/oprint/lib/python2.7/site-packages/octoprint_emailnotifier

mailer.send(to=emails, subject=subject, contents=body)

Now I am getting this message:
Sending failed. Reason:: Emailaddress "" is not valid according to RFC 2822 standards

Any ideas?
Thanks

Update
I tried sending an email through python and it worked but I had to import yagmail again.
Then I tried again in OctoPrint and was successful. Do I have to import yagmail on every restart?

from octoprint-emailnotifier.

DrWatson avatar DrWatson commented on September 27, 2024

I had the " is not valid according to RFC 2822 standards" error when I was using it too. All I needed to do was save the settings and reopen the configuration for notifier and hit test again and it worked. I think it's just not picking up the live value from the control so saving it and reloading the configuration fixes it.

from octoprint-emailnotifier.

Stady234 avatar Stady234 commented on September 27, 2024

Is this still an open issue? I was able to get it to work under 0.15.1 with only adding one more line to the yagmail setup...

from octoprint-emailnotifier.

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.