Skip to content

Err(Parse(Invalid(...)) ) on most methods to select/examine/fetch from gmail  #106

@softprops

Description

@softprops

First off, thank you for your work on this crate.

I'm having trouble getting almost all session methods to work with authenticating with an app password with gmail

let domain = "...";
let tls = TlsConnector::builder().build().unwrap();

let client = imap::connect((domain, 993), domain, &tls)
            .expect(&format!("failed to connect to {}", domain));

let mut session = client.login(username, app_password).expect("failed to authenticate with domain");

println!("{:#?}", session. select("INBOX").expect("failed to select inbox"));

In this example and many others I'll get Parse(Invalid(...)) errors. When I view the bytes as a string in this case I see

 "* FLAGS (\\Answered \\Flagged \\Draft \\Deleted \\Seen $NotPhishing $Phishing OIB-Seen-INBOX OIB-Seen-OIB/Business OIB-Seen-OIB/Entertainment OIB-Seen-OIB/Finance OIB-Seen-OIB/Groups OIB-Seen-OIB/Home OIB-Seen-OIB/Jobs OIB-Seen-OIB/News OIB-Seen-OIB/Shopping OIB-Seen-OIB/Social Networking OIB-Seen-OIB/Travel OIB-Seen-[Gmail]/All Mail OIB-Seen-[Gmail]/Important OIB-Seen-[Gmail]/Spam OIB-Seen-[Gmail]/Trash)\r\n"

I'm not familiar with imap at the protocol level but am I missing something here?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions