<div class="gmail_quote">Boa tarde, pessoal!<br><br>Eu consegui utilizar normalmente a função sendmail do pacote sendmailR na minha máquina. <br>> Sys.info()<br><br><span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"><pre style="font-family:Monospace;font-size:10pt !important;outline-style:none;outline-width:initial;outline-color:initial;border-top-style:none;border-right-style:none;border-bottom-style:none;border-left-style:none;border-width:initial;border-color:initial;white-space:pre-wrap !important;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;line-height:1.3">

 sysname   release                version                                        nodename <span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span>
 "Linux"   "2.6.32-33-generic"  "#71-Ubuntu SMP Wed Jul 20 17:30:40 UTC 2011"    "bruno-laptop" <span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span>
<br><span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"><pre style="font-family:Monospace;font-size:10pt !important;outline-style:none;outline-width:initial;outline-color:initial;border-top-style:none;border-right-style:none;border-bottom-style:none;border-left-style:none;border-width:initial;border-color:initial;white-space:pre-wrap !important;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;line-height:1.3">

machine  login     user<span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span><span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span><span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span>
</pre></span></span><span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"><pre style="font-family:Monospace;font-size:10pt !important;outline-style:none;outline-width:initial;outline-color:initial;border-top-style:none;border-right-style:none;border-bottom-style:none;border-left-style:none;border-width:initial;border-color:initial;white-space:pre-wrap !important;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;line-height:1.3">

"i686"  "unknown" "bruno"<span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span><br>


<br><span style="font-family:arial,helvetica,sans-serif">Mas ao tentar usar o mesmo programa numa máquina Windows, ocorreu um erro que está depois do exemplo reproduzível.<br>Seguem as informações da máquina Windows que eu fiz o teste.<br>

<br>> Sys.info()<br><br></span>sysname      release    version     nodename      machine     login       user<span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span><span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span><span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span><span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span>  <span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span>
"Windows"   "7 x64"   "build 7600"   "RIGEL"       "x86"     "bramos"   "bramos<span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span><span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span><span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span><span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"></span></span>"<br>


<br><span style="font-family:arial,helvetica,sans-serif">Exemplo reproduzível, com argumento do email incorreto por segurança.</span><br><br>#################################################################################<br>


library(sendmailR)<br>from <- sprintf("<sendmailR@%s>", Sys.info()[4])<br>to <-   "<email@valido>"  #Substituir por email válido<br>subject <- "Hello from R"<br>body <- list("It works!", mime_part(iris))
sendmail(from, to, subject, body, control=list(smtpServer="<a href="http://ASPMX.L.GOOGLE.COM" target="_blank">ASPMX.L.GOOGLE.COM</a>"))<br><span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"><pre style="font-family:Monospace;font-size:10pt !important;outline-style:none;outline-width:initial;outline-color:initial;border-top-style:none;border-right-style:none;border-bottom-style:none;border-left-style:none;border-width:initial;border-color:initial;white-space:pre-wrap !important;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;line-height:1.3">

<span style="border-collapse:separate;color:rgb(0, 0, 0);font-family:Arial;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;font-size:medium"><span style="font-family:Monospace;font-size:13px;line-height:17px;text-align:-webkit-left;white-space:pre-wrap"><pre style="font-family:Monospace;font-size:10pt !important;outline-style:none;outline-width:initial;outline-color:initial;border-top-style:none;border-right-style:none;border-bottom-style:none;border-left-style:none;border-width:initial;border-color:initial;white-space:pre-wrap !important;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;line-height:1.3">

#################################################################################</pre></span></span></pre></span></span><div class="im"><br>Erro em writeLines(msg, sock, sep = "\r\n") : argumento 'text' inválido<br>


</div><span style="font-family:arial,helvetica,sans-serif">Alguém tem alguma sugestão do que pode estar acontecendo?</span><br style="font-family:arial,helvetica,sans-serif">
<span style="font-family:arial,helvetica,sans-serif">Obrigado,</span><br style="font-family:arial,helvetica,sans-serif"><font color="#888888"><span style="font-family:arial,helvetica,sans-serif">Bruno</span><br><br></font></pre>

</span></span></pre>
</span></span>
</div><br>