0

'emayili' 包中的 R 错误。

# Create a message object..
# Add addresses for the sender and recipient.
# Add a subject.
# Add a text body.
to_send<- envelope(to = "xxx@gmail.com",
           from = "xxx@gmail.com",
           subject = "ALERT",
           text="xxx")
smtp<- server(host = "smtp.gmail.com",
          port = 465,
          username = "xxx@gmail.com",
          password = "password form less secure apps setting")

我说 Error: Request failed after 5 attempts 我实际上用 SMTP 测试工具在线测试了几次,似乎它会起作用。我检查了rlang::last_error(),输出是:

<error/purrr_error_rate_excess>
Request failed after 5 attempts
Backtrace:
 1. emayili:::smtp(msg, verbose = TRUE)
 2. purrr:::send_mail(...)
 3. purrr::rate_sleep(rate, quiet = quiet)
 4. purrr:::stop_rate_excess(rate)

然后我跑去rlang::last_trace()看完整的上下文

<error/purrr_error_rate_excess>
Request failed after 5 attempts
Backtrace:
    x
 1. \-emayili:::smtp(msg, verbose = TRUE)
 2.   \-purrr:::send_mail(...)
 3.     \-purrr::rate_sleep(rate, quiet = quiet)
 4.       \-purrr:::stop_rate_excess(rate)

有没有办法解决它?

4

0 回答 0