Download & Extend

multiple twitter accounts causes confusion

Project:Twitter
Version:6.x-3.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:needs work

Issue Summary

if i add a twitter account to my profile, then delete it and add another the system will get confused and use both accounts... if i have a 3rd or 4th it will just get more complicated.
i cannot post to twitter because it posts to whatever my first account created was.

Comments

#1

it's possible that this is related to the problem reported here: #379678: No data added to {twitter_account} since that issue means that new twitter accounts are not added 100% correctly and in this case the delete of the not correctly created account does not remove the relevant row from the twitter_account (or twitter_user table - I can't recall) table.

#2

Attached is a patch to dev that I claim will post to all Twitter accounts a user has where they've entered a password, but not (obviously) for those that don't have a password associated with them. (Adding a cross-reference to http://drupal.org/node/335459 )

AttachmentSize
twitter-multiple-accounts.patch-356379.txt 1.7 KB

#3

Subscribing.

#4

Updating the patch for 2.3. Takes into account whether the password is set for the account, so that it doesn't display an error if it fails for a password not being set (since it would definitely fail).

AttachmentSize
twitter-401-authentication-335459.patch.txt 2.09 KB

#5

Version:6.x-2.x-dev» 6.x-2.4

Updating for 2.4. This only modifies twitter.module: the twitter.inc modifications in the patch appear not to be necessary for this version.

AttachmentSize
twitter-401-authentication-2.4-356379.txt 475 bytes

#6

Version:6.x-2.4» 6.x-2.6

Updating for 2.6. Adds some logic for the messages reported on successful post. It will only post a 'success' message to Drupal if there's a password set on the Twitter account. That is, since only an account with a password set can post to Twitter, it will not display a 'success' message for accounts without passwords in a user's settings.

AttachmentSize
twitter-multiple-accounts-api-356379.txt 1.96 KB

#7

This patch works very well for me so far. Thanks Richard.

#8

subscribing

#9

Still having the same problem as described above:

Add an account. Then delete the account and add another.
Drupal shows new account correctly on user page (the new account) but looking at the database tables I see the old account and all tweets from it and the old tweets from the deleted account are still there.

www.VortexVideBlog.com

#10

Status:active» needs review

patch at #6
is this still an issue in latest dev?

#11

@robby.smith
I think so, or at least it is causing trouble for me running the latest release (by date, the beta 2 is the latest), I get multiple errors like:

user warning: Duplicate entry '0' for key 1 query: INSERT INTO d6_twitter (twitter_id, screen_name, created_at, created_time, text, source, truncated) VALUES (-10314781, 'Flipshotfilm', 'Mon Apr 26 10:05:19 +0000 2010', 1272276319, 'RT @voodoofilm RT @metroteknik: Diskettens dagar är nu officiellt räknade: Sista tillverkaren slutar sin försäljning http://bit.ly/8YAaEW', '<a href=\"http://www.htc.com\" rel=\"nofollow\">HTC Peep</a>', 0) in /users/home/spot/domains/flipshot.se/web/public/includes/common.inc on line 3477.

I did as the original poster did: First add one account, seeing it all work as it was supposed to, the deleting that account and adding a new Twitter account. It imports fine though. Edit: This is not an identical error but it looks to me to be the symptom of the same bug, somewhere...

#12

I made a temporary solution that involved manually copying the twitter ID# into {twitter} table. Now the error message is gone.

#13

I found this thread very useful.
However, there seem to be 2 conversations going on.
The patches that I applied made it possible for me to submit a single request and post the twitter post to multiple accounts.
The main post may not be directly related to this issue.
They appear to have a problem with deleting an account and adding a new one.
I hope this helps, I know that patch will help me.
Now I just need to find the corresponding patch that lets me select which of the multiple accounts I want the post to go to.

peace,
michael

#14

sub

#15

sub +1

#16

Subscribing, greetings, Martijn

#17

Is this only relevant for 6.x, or should it be fixed in the 7.x branch and backported?

#18

7.x is effectively behind 6.x, as a lot of changes will need to be ported forward.

#19

Version:6.x-2.6» 6.x-3.x-dev
Status:needs review» needs work

Hi
Could not find any work on this issue in the 6.x code base. Perhaps we should move this issue to 7.x to get fixed there and then backported to 6.x? This issue is about the same as #418784: Post to multiple twitter accounts

#20

There will be some progress on this and other issues this Saturday, as we are doing a Spanish DrupalConTribute event, where all areas of the module (code, support, new features, documentation, tests) will be improved by a group of people.

http://groups.drupal.org/node/190074

#21

Well, my Spanish is a bit rusty ;) but I was able to read some of it. This is fantastic news. Good luck with your code sprint :)

#22

nobody click here