1) I created User via twitter.
2) Delete this user.
3) Want to create the same user via twitter again.
I get this errors:
•user warning: Duplicate entry '' for key 2 query: INSERT INTO users (created) VALUES (1272111815) in /drupal/modules/user/user.module on line 327.
•warning: array_fill() [function.array-fill]: Number of elements must be positive in /drupal/includes/database.inc on line 253.
•warning: implode() [function.implode]: Invalid arguments passed in /drupal/includes/database.inc on line 253.
•warning: array_keys() [function.array-keys]: The first argument should be an array in /drupal/modules/user/user.module on line 502.
•user warning: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1 query: SELECT p.perm FROM role r INNER JOIN permission p ON p.rid = r.rid WHERE r.rid IN () in /www/htdocs/w00a4e9f/drupal/modules/user/user.module on line 502.
Comments
Comment #1
uniqode commentedI have exactly the same error
Comment #2
uniqode commentedI found the problem if you delete a user it still keep user twitter account. So you need to delete user's twitter accounts from twitter_account table
Comment #3
Anonymous (not verified) commentedTried this in the latest dev branch and it seems solved there. Dunno what the best practice is for these situations but ill close the issue. Reopen it if that is stupid. xD
Comment #4
tstackhouse commentedReopening this, it is still a bug in beta3, the module needs to implement hook_user('delete') and delete entries from the table.
Comment #5
Osiris Indriya commentedSubscribing...
I have the same error. I added the same Twitter account to two users, removed it from one, but I now get this error intermittently.
Comment #6
steinmb commentedUnable to reproduce in the latest 6.x-3 version, fixed?
Comment #8
L1maniac commentedi have this problem too, what is the solution?!
Comment #9
steinmb commented@L1maniac: Hi :) What version are you on and how do you reproduce it?
Comment #10
hedac commentedI didn't delete the user but I have same errors visiting user page
using 6.x-3.0-beta9
Comment #11
mtem27 commentedHi!
What's the correct fix for this? This issue still exists on the 6.x-3.0-beta9 version (Recommended Release)
I tried this http://drupal.org/node/911646, but got an error with duplicate twitter_user_delete function.
While this, http://drupal.org/node/1614488, is the same as the above's function.
There is a twitter_user_delete in twitter.inc for 6.x-3.0-beta9 but is not firing.
Any help is appreciated.
Thanks.
Comment #12
mtem27 commentedComment #13
vb_swapnil commentedHello ,
After setting Twitter username in drupal user account i got following error.
Notice: Undefined property: stdClass::$data in Twitter->request() (line 210 of /home/infogrid/workspace/acquia-drupal/sites/all/modules/twitter/twitter.lib.php).
PDOException: SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'twitter_uid' cannot be null: INSERT INTO {twitter_account} (twitter_uid, screen_name, name, location, description, followers_count, friends_count, statuses_count, favourites_count, url, protected, profile_image_url, profile_background_color, profile_text_color, profile_link_color, profile_sidebar_fill_color, profile_sidebar_border_color, profile_background_image_url, profile_background_tile, verified, created_at, created_time, utc_offset, oauth_token, oauth_token_secret, uid) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4, :db_insert_placeholder_5, :db_insert_placeholder_6, :db_insert_placeholder_7, :db_insert_placeholder_8, :db_insert_placeholder_9, :db_insert_placeholder_10, :db_insert_placeholder_11, :db_insert_placeholder_12, :db_insert_placeholder_13, :db_insert_placeholder_14, :db_insert_placeholder_15, :db_insert_placeholder_16, :db_insert_placeholder_17, :db_insert_placeholder_18, :db_insert_placeholder_19, :db_insert_placeholder_20, :db_insert_placeholder_21, :db_insert_placeholder_22, :db_insert_placeholder_23, :db_insert_placeholder_24, :db_insert_placeholder_25); Array ( [:db_insert_placeholder_0] => [:db_insert_placeholder_1] => [:db_insert_placeholder_2] => [:db_insert_placeholder_3] => [:db_insert_placeholder_4] => [:db_insert_placeholder_5] => [:db_insert_placeholder_6] => [:db_insert_placeholder_7] => [:db_insert_placeholder_8] => [:db_insert_placeholder_9] => [:db_insert_placeholder_10] => [:db_insert_placeholder_11] => [:db_insert_placeholder_12] => [:db_insert_placeholder_13] => [:db_insert_placeholder_14] => [:db_insert_placeholder_15] => [:db_insert_placeholder_16] => [:db_insert_placeholder_17] => [:db_insert_placeholder_18] => [:db_insert_placeholder_19] => [:db_insert_placeholder_20] => [:db_insert_placeholder_21] => [:db_insert_placeholder_22] => 0 [:db_insert_placeholder_23] => [:db_insert_placeholder_24] => [:db_insert_placeholder_25] => 1 ) in twitter_account_save() (line 56 of /home/infogrid/workspace/acquia-drupal/sites/all/modules/twitter/twitter.inc).
Please need help here to resolve above error
Comment #14
mtem27 commentedPer my #11 post above, I came up with a custom module using hook_user. To anyone who wanted to check, below is the code:
Thanks.
Comment #15
tcibah commentedHave the same problem and it fires from the moment Twitter module is enabled, with no Twitter user accounts yet.
It generates tons of error messages in the Watchdog...
Comment #16
tcibah commentedProblem fixed by using the latest development version: twitter-6.x-3.x-dev.tar.gz
Do not forget to clear cache, otherwise an error message in a white scree will popup.
Thanks juampy...
Comment #17
juampynr commentedMarking it as fixed.