{"action":"created","issue":{"url":"https://api.github.com/repos/rtCamp/easyengine/issues/521","labels_url":"https://api.github.com/repos/rtCamp/easyengine/issues/521/labels{/name}","comments_url":"https://api.github.com/repos/rtCamp/easyengine/issues/521/comments","events_url":"https://api.github.com/repos/rtCamp/easyengine/issues/521/events","html_url":"https://github.com/rtCamp/easyengine/issues/521","id":71961961,"number":521,"title":"Databases not dropping properly - weakly-referenced object no longer exists","user":{"login":"brennentsmith","id":4530934,"avatar_url":"https://avatars.githubusercontent.com/u/4530934?v=3","gravatar_id":"","url":"https://api.github.com/users/brennentsmith","html_url":"https://github.com/brennentsmith","followers_url":"https://api.github.com/users/brennentsmith/followers","following_url":"https://api.github.com/users/brennentsmith/following{/other_user}","gists_url":"https://api.github.com/users/brennentsmith/gists{/gist_id}","starred_url":"https://api.github.com/users/brennentsmith/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brennentsmith/subscriptions","organizations_url":"https://api.github.com/users/brennentsmith/orgs","repos_url":"https://api.github.com/users/brennentsmith/repos","events_url":"https://api.github.com/users/brennentsmith/events{/privacy}","received_events_url":"https://api.github.com/users/brennentsmith/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-04-29T19:13:09Z","updated_at":"2015-08-14T16:07:45Z","closed_at":null,"body":"It appears that in the Database Drop of a Site Delete process, the code is using a weakly referenced MySQL object that the GC destroys before the operation is completed. The user and additional database are usually not dropped in this circumstance. See: \r\n\r\n```bash\r\nExecuting ee site delete devtest2.wildwingstudios.com --no-prompt\r\nDeleting Database, devtesv1wa29GVCL, user devtesO3MpaVJ1AC\r\nDatabase devtesO3MpaVJ1AC not dropped\r\nDeleted Database successfully.\r\nDeleting Webroot, /var/www/devtest2.wildwingstudios.com\r\nDeleted webroot successfully\r\nReload : nginx     [OK]\r\nDeleted site devtest2.wildwingstudios.com\r\n\r\nErrors\r\nException ignored in: <bound method Cursor.__del__ of <pymysql.cursors.Cursor object at 0x7ff853c4d2e8>>\r\nTraceback (most recent call last):\r\n  File \"/usr/local/lib/python3.4/dist-packages/PyMySQL3-0.4-py3.4.egg/pymysql/cursors.py\", line 41, in __del__\r\n  File \"/usr/local/lib/python3.4/dist-packages/PyMySQL3-0.4-py3.4.egg/pymysql/cursors.py\", line 47, in close\r\nReferenceError: weakly-referenced object no longer exists\r\n\r\nExecuting sudo service nginx reload\r\n * Reloading nginx configuration nginx\r\n   ...done.\r\n```"},"comment":{"url":"https://api.github.com/repos/rtCamp/easyengine/issues/comments/131164455","html_url":"https://github.com/rtCamp/easyengine/issues/521#issuecomment-131164455","issue_url":"https://api.github.com/repos/rtCamp/easyengine/issues/521","id":131164455,"user":{"login":"dethmix","id":13799832,"avatar_url":"https://avatars.githubusercontent.com/u/13799832?v=3","gravatar_id":"","url":"https://api.github.com/users/dethmix","html_url":"https://github.com/dethmix","followers_url":"https://api.github.com/users/dethmix/followers","following_url":"https://api.github.com/users/dethmix/following{/other_user}","gists_url":"https://api.github.com/users/dethmix/gists{/gist_id}","starred_url":"https://api.github.com/users/dethmix/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dethmix/subscriptions","organizations_url":"https://api.github.com/users/dethmix/orgs","repos_url":"https://api.github.com/users/dethmix/repos","events_url":"https://api.github.com/users/dethmix/events{/privacy}","received_events_url":"https://api.github.com/users/dethmix/received_events","type":"User","site_admin":false},"created_at":"2015-08-14T16:07:45Z","updated_at":"2015-08-14T16:07:45Z","body":"Hi, I have got absolutely the same error message while using remote mysql server. Below is full error message:\r\nee site delete test2.com\r\nAre you sure, you want to delete database [y/N]: y\r\nDeleting Database, test2_com, user test2_com\r\nDatabase test2_com not dropped\r\nException ignored in: <bound method Cursor.__del__ of <pymysql.cursors.Cursor object at 0x7f985b68c2b0>>\r\nTraceback (most recent call last):\r\n  File \"/usr/local/lib/python3.4/dist-packages/PyMySQL3-0.4-py3.4.egg/pymysql/cursors.py\", line 41, in __del__\r\n  File \"/usr/local/lib/python3.4/dist-packages/PyMySQL3-0.4-py3.4.egg/pymysql/cursors.py\", line 47, in close\r\nReferenceError: weakly-referenced object no longer exists\r\nDeleted Database successfully.\r\nAre you sure, you want to delete webroot [y/N]: y\r\nDeleting Webroot, /var/www/test2.com\r\nDeleted webroot successfully\r\nReload : nginx     [OK]\r\nDeleted site test2.com\r\n\r\nIn same time I can't reproduce it while using local mysql server. Is there any know solutions for this? EE does remove mysql database from the remote mysql server, but doesn't remove mysql user."}}