{"action":"created","issue":{"url":"https://api.github.com/repos/jens-maus/yam/issues/210","repository_url":"https://api.github.com/repos/jens-maus/yam","labels_url":"https://api.github.com/repos/jens-maus/yam/issues/210/labels{/name}","comments_url":"https://api.github.com/repos/jens-maus/yam/issues/210/comments","events_url":"https://api.github.com/repos/jens-maus/yam/issues/210/events","html_url":"https://github.com/jens-maus/yam/issues/210","id":148342089,"number":210,"title":"Improved UIDL support and import.","user":{"login":"jens-maus","id":5887769,"avatar_url":"https://avatars.githubusercontent.com/u/5887769?v=3","gravatar_id":"","url":"https://api.github.com/users/jens-maus","html_url":"https://github.com/jens-maus","followers_url":"https://api.github.com/users/jens-maus/followers","following_url":"https://api.github.com/users/jens-maus/following{/other_user}","gists_url":"https://api.github.com/users/jens-maus/gists{/gist_id}","starred_url":"https://api.github.com/users/jens-maus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jens-maus/subscriptions","organizations_url":"https://api.github.com/users/jens-maus/orgs","repos_url":"https://api.github.com/users/jens-maus/repos","events_url":"https://api.github.com/users/jens-maus/events{/privacy}","received_events_url":"https://api.github.com/users/jens-maus/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/jens-maus/yam/labels/%23major","name":"#major","color":"ededed"},{"url":"https://api.github.com/repos/jens-maus/yam/labels/@normal","name":"@normal","color":"ededed"},{"url":"https://api.github.com/repos/jens-maus/yam/labels/enhancement","name":"enhancement","color":"84b6eb"},{"url":"https://api.github.com/repos/jens-maus/yam/labels/fixed","name":"fixed","color":"ededed"},{"url":"https://api.github.com/repos/jens-maus/yam/labels/nightly%20build","name":"nightly build","color":"ededed"},{"url":"https://api.github.com/repos/jens-maus/yam/labels/TCP/IP","name":"TCP/IP","color":"ededed"}],"state":"open","locked":false,"assignee":{"login":"jens-maus","id":5887769,"avatar_url":"https://avatars.githubusercontent.com/u/5887769?v=3","gravatar_id":"","url":"https://api.github.com/users/jens-maus","html_url":"https://github.com/jens-maus","followers_url":"https://api.github.com/users/jens-maus/followers","following_url":"https://api.github.com/users/jens-maus/following{/other_user}","gists_url":"https://api.github.com/users/jens-maus/gists{/gist_id}","starred_url":"https://api.github.com/users/jens-maus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jens-maus/subscriptions","organizations_url":"https://api.github.com/users/jens-maus/orgs","repos_url":"https://api.github.com/users/jens-maus/repos","events_url":"https://api.github.com/users/jens-maus/events{/privacy}","received_events_url":"https://api.github.com/users/jens-maus/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/jens-maus/yam/milestones/1","html_url":"https://github.com/jens-maus/yam/milestones/YAM%202.7","labels_url":"https://api.github.com/repos/jens-maus/yam/milestones/1/labels","id":1705555,"number":1,"title":"YAM 2.7","description":"[[TicketQuery(milestone=YAM 2.7, order=resolution, desc=1, format=table, col=id|type|status|resolution|priority|summary)]]","creator":{"login":"jens-maus","id":5887769,"avatar_url":"https://avatars.githubusercontent.com/u/5887769?v=3","gravatar_id":"","url":"https://api.github.com/users/jens-maus","html_url":"https://github.com/jens-maus","followers_url":"https://api.github.com/users/jens-maus/followers","following_url":"https://api.github.com/users/jens-maus/following{/other_user}","gists_url":"https://api.github.com/users/jens-maus/gists{/gist_id}","starred_url":"https://api.github.com/users/jens-maus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jens-maus/subscriptions","organizations_url":"https://api.github.com/users/jens-maus/orgs","repos_url":"https://api.github.com/users/jens-maus/repos","events_url":"https://api.github.com/users/jens-maus/events{/privacy}","received_events_url":"https://api.github.com/users/jens-maus/received_events","type":"User","site_admin":false},"open_issues":1,"closed_issues":65,"state":"closed","created_at":"2016-04-14T09:49:40Z","updated_at":"2016-04-14T12:13:36Z","due_on":"2011-12-19T23:00:00Z","closed_at":"2016-04-14T09:49:40Z"},"comments":3,"created_at":"2016-04-14T12:13:34Z","updated_at":"2016-04-14T12:13:44Z","closed_at":null,"body":"**:bust_in_silhouette: Originally by _opionline@yahoo.de_ on 2010-09-14 16:52:18 +0200**\n<hr>\nI test the new UIDL support in YAM for some time now and\nas result i have 9 .uidl_... files in the YAM directory.\nIt seems all files contain the uidl's for the latest\nloaded mails. I have only one account configured which \nshould not delete the E-Mails on the Server.\n\nSo here my request:\nYAM should only write the .uidl_ files if 'Delete mail on server'\nis *not* enabled. I see no reason why YAM should write the .uidl_\nfile when this option is enabled.\n\nSuch .uidl_ file(s) produce a lot unnecessarily overhead.\n\nIf YAM is getting mails next time then it load the .uidl_ files\nfor every  account and check the content which must fail because\nthe mail(s) are already deleted on the server.\nSo here YAM loads 9 files but really necessary is only one.\n\nA check for such file before getting mails is ok because\nthe configuration may have been changed and the user now want\nto Delete the mails on the server.\n\nIf the .uidl_ file is finally empty (contain only the header)\nthen YAM should delete the .uidl_ file too.\n\nSummary: YAM sould only remember uidl's for mails which are\nreally still on any server.\n\n\nAdditional a improved import function for the old .uidl file\nwould be nice too. Before YAM 2.7 is going into the wild\nwe should think about a way to get rid of the old .uidl file.\nOtherwise YAM 2.7 and all later versions would still check for\nthe old .uidl file. Now we have the chance to change that.\n\nA possible way is maybe at the first start of YAM 2.7 to\ncheck the configuration and copy the old .uidl file into\nall new .uidl_... files which has 'Delete mail on server'\nnot enabled and delete the old uidl. file afterwards.\n\nNext time YAM is getting mails from this account(s) it\nshould delete not valid entries from the new .uidl_\nfile anyway and if it's ends in an empty file delete\nthe file. (see above)\n\n"},"comment":{"url":"https://api.github.com/repos/jens-maus/yam/issues/comments/209909450","html_url":"https://github.com/jens-maus/yam/issues/210#issuecomment-209909450","issue_url":"https://api.github.com/repos/jens-maus/yam/issues/210","id":209909450,"user":{"login":"jens-maus","id":5887769,"avatar_url":"https://avatars.githubusercontent.com/u/5887769?v=3","gravatar_id":"","url":"https://api.github.com/users/jens-maus","html_url":"https://github.com/jens-maus","followers_url":"https://api.github.com/users/jens-maus/followers","following_url":"https://api.github.com/users/jens-maus/following{/other_user}","gists_url":"https://api.github.com/users/jens-maus/gists{/gist_id}","starred_url":"https://api.github.com/users/jens-maus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jens-maus/subscriptions","organizations_url":"https://api.github.com/users/jens-maus/orgs","repos_url":"https://api.github.com/users/jens-maus/repos","events_url":"https://api.github.com/users/jens-maus/events{/privacy}","received_events_url":"https://api.github.com/users/jens-maus/received_events","type":"User","site_admin":false},"created_at":"2016-04-14T12:13:44Z","updated_at":"2016-04-14T12:13:44Z","body":"**:bust_in_silhouette: Originally by _opionline@yahoo.de_ on 2010-09-17 16:28:37 +0200**\n<hr>\nJens was talking about SMTP Servers but we are talking about POP3 Servers.\n\nI took the trouble and looked in the rfc's:\nFor SMTP look at:\nhttp://tools.ietf.org/html/rfc5321#section-4.1.1.10\nthe important part is:\n\n```\n...\nThe sender MUST NOT intentionally close the transmission channel until\nit sends a QUIT command, and it SHOULD wait until it receives the reply\n...\n```\n\nSo the Servers are not broken because of the word 'SHOULD'.\nYou should know what 'SHOULD' does mean. ;-)\nAt least it means not 'MUST'.\n\nFor the POP3 QUIT command in TRANSACTION State see chapter 6 at:\nhttp://tools.ietf.org/html/rfc1939#page-10\n\nBut here a some other interesting pages about the QUIT command and how a server have to respond to commands at all.\nAfter reading all pages it is still valid what i said before any YAM should only write the UIDL file if it's not receive a response for the QUIT command or YAM doesn't send the QUIT command because of a broken connection or whatever.\n\nTo test the GMX Server i also create a gmx account and it's work like expected:\n\n```\nSERVER[0033]: +OK POP server ready H migmx003\nCLIENT[0021]: USER xxxxxxx@gmx.de\nSERVER[0049]: +OK password required for user \"xxxxxxx@gmx.de\"\n...\nSERVER[0003]: .\nCLIENT[0008]: DELE 3\nSERVER[0005]: +OK\nCLIENT[0006]: QUIT\nSERVER[0028]: +OK POP server signing off\n```\n\nAbout te overhead a can say in the worst case YAM has to check here\nat least 11 (now 12) files and has to update the same amount of files.\nI would say producing such unneeded overhead is not 'really minimal'.\nAdditional a backup program has to do the same things again.\n\n\n\nBTW (off topic):\nAnother issue is the QUIT command in the AUTHORIZATION State:\nIn chapter 4 (Page 4) http://tools.ietf.org/html/rfc1939#page-4\nyou can read:\n\n```\nAfter returning a negative status indicator, the server may close the\nconnection.  If the server does not close the connection, the client\nmay either issue a new authentication command and start again, or the\nclient may issue the QUIT command.\n```\n\nCurrently YAM sends the QUIT command also if the connection is closed\nbut should not do that. YAM should send the QUIT only if the Server does\n*not* close the connection. (or send a new authentication command).\nA possile solution is also the absence of a reply not consider as error.\n\n```\nSERVER[0065]: +OK hello from popgate 2.46.7 on pop102.plus.mail.re2.yahoo.com\nCLIENT[0016]: USER xxxxxxxxx\nSERVER[0024]: +OK password required.\nCLIENT[0016]: PASS xxxxxxxxx\nSERVER[0035]: -ERR [AUTH] invalid user/password\nCLIENT[0006]: QUIT\nSERVER[-001]: \n```\n\nand show 2 errors:\n\nDer Postserver 'xxx' von Konto 'xxx' hat auf den Befehl 'PASS' falsch geantwortet:\n-ERR [AUTH] invalid user/password\n\nand\n\nDer Postserver 'xxx' von Konto 'xxx' hat auf den Befehl 'QUIT' falsch geantwortet:\n\nA user may only see the second error in the error window and does't recognize\nthe first error which show the true cause for the failure.\n\nThat is not so important but should be fixed too IMHO.\n\n\nFor completness I test it on 7 different servers (using a wrong password) and\nonly one ('pop3.arcor.de') doesn't close the connection and respond with a:\n\n```\nCLIENT[0016]: PASS xxxxxxxxx\nSERVER[0020]: -ERR Login failed.\nCLIENT[0006]: QUIT\nSERVER[0028]: +OK Better luck next time.\n```\n\nNice answer IMHO :-)\n"}}