The Twitter Tags module provides additional functionality to the Twitter module by parsing and saving hashtag data for Tweets as they're saved. The module is integrated with Views, so site builders can create lists of Tweets filtered by one or more tags. Also if the site is using the core Taxonomy module, taxonomy term data may be related to the Tweets for additional functionality.
Providing this functionality via the Twitter module is becoming more important as it's the defacto standard for integrating with Twitter's API. The ability to manage Tweets via hashtag data has been requested many times in the Twitter module's issue queue but there is still no suitable solution. Twitter Tags is a lightweight extension to provide this functionality.
Project page
https://drupal.org/sandbox/bmoresafety20/1943112
Repository
git clone http://git.drupal.org/sandbox/bmoresafety20/1943112.git twitter_tags
Please be sure to review the 7.x-1.x branch. I've also created a 7.x-1.0-rc1 tag representing the state of the code at the time of this submission.
Similar projects
- Twitter Search - This module is used to query Twitter for certain text searches. It is not integrated with Taxonomy and only has a dev release for D7.
- Twitter Block - This has been a popular way to display Tweets that contain a specific hashtag but is no longer functional because it has not been upgraded to utilize Twitter API v1.1.
Ventral.org review
http://ventral.org/pareview/httpgitdrupalorgsandboxbmoresafety201943112-...
Coder module review
Clean.
Security concerns
This should be a very low-risk module. It parses the text of a Tweet, saves hashtag data to the database, and provides it back via existing (vetted) Views functionality.
Reviews of other projects
- [D7] Diversity Enricher
- [D7] Webform Email Reply (several comments/reviews)
- [D7] Age Verification Module
Thanks.
| Comment | File | Size | Author |
|---|---|---|---|
| #11 | twitter_tags_view.txt | 3.53 KB | dsnopek |
| #1 | twitter_tags_view.txt | 4.69 KB | kerasai |
Comments
Comment #1
kerasai commentedQuick steps to get see this running:
Comment #2
PA robot commentedWe are currently quite busy with all the project applications and we prefer projects with a review bonus. Please help reviewing and put yourself on the high priority list, then we will take a look at your project right away :-)
Also, you should get your friends, colleagues or other community members involved to review this application. Let them go through the review checklist and post a comment that sets this issue to "needs work" (they found some problems with the project) or "reviewed & tested by the community" (they found no major flaws).
I'm a robot and this is an automated message from Project Applications Scraper.
Comment #3
mavin commentedHi,
I'm trying to enable your module, but for that I need to enable the Twitter module. Unfortunately, it depends on oauth_common module which has no release for D7.
Comment #4
kerasai commented@mavin Use the the oauth_common module that is contained in the OAuth project.
Comment #5
kerasai commentedComment #6
mavin commentedOK thank you.
Maybe you should add a list of modules depending on yours in the description and README file.
Comment #7
pandaski commentedManual review:
Better to add more module dependencies or requirements in info/install file.
Using the drush pm-enable twitter_tags finally got the following message:
Although it is a twitter module related issue, better to add the information in README.txt and project page.
oauth module could be added in the requirements to resolve the oauth_common issue. https://drupal.org/project/oauth
Comment #8
ayesh commentedCan this module handle multiple hashtags in a single tweet ?
In
twitter_tags_set_tags(), it handles multiple hashtags but when it comes to display them, it seems that the View will show multiple rows for each hashtag found in a particular tweet.For example, if there is a tweet "#omg #zombies", Views module will show this tweet in a single line. But as your views integration adds a simple join, it will cause Views to display this very same tweet twice, because there are 2 rows in twitter_tags table.
I could not test this yet (I'm not with my own laptop now) but as far as I can remember, this type of views join causes multiple rows.
Also, consider adding all the data in a single database query. db_insert function can handle multiple row inserts in a single database trip.
I will test this awesome work later and will post results.
Comment #9
kerasai commented@Ayesh Thanks for taking a look.
Dependencies
I've updated the project page with additional information on the OAuth module needed for Twitter. I'll get it into the README the next time I'm in the code.
Views Integration
I see what you're saying with the join. Right now it's going to return duplicate rows only if you filter on multiple hashtags or you render data from the matching taxonomy term. I'll look into the handlers that the join is using yto see if there is a better solution for joining multiples.
DB Insert
I'll also take a look at inserting multiple rows in one shot. I wasn't aware that db_insert() provided that functionality.
Thanks again for reviewing, let me know if you see anything else worth a second look.
Comment #10
kerasai commentedPushed a few changes into 7.x-1.x branch for the dependency information and the db insert. Coder review and Ventral are still happy.
Still looking into the Views integration part. I was hoping there would be a handler that would be usable as-is but that does not seem to be the case. I'm going to continue looking at that, worst case scenario I'll have to provide a custom handler that extends views_handler_field_prerender_list similar to how Taxonomy and other modules are implemented.
Comment #11
dsnopekI did manual testing and it works! One note: the view linked above in comment #1 didn't work for me because it requires a relationship to a Taxonomy Vocabulary that I don't have. I've attached a new exported view that works for me.
Coding standards look good in both Coder and a quick read through. Quick security audit looks good - no HTML is generated anywhere (it's all done by standard views handlers from the views module).
I have a couple minor notes about the API documentation in comments:
twitter_tags_twitter_status_save(),twitter_tags_set_tags(), andtwitter_tags_find_tags()) that take a $status parameter. The doc block should include a@paramfor it per this document: https://drupal.org/coding-standards/docs#paramtwitter_tags_find_tags()should have a@returnper this document: https://drupal.org/coding-standards/docs#return@filesays: "Twitter Taxonomy module hooks" which is wrong - it should probably be something like "Install, update, and uninstall functions for the Twitter Tags module" (copied from https://drupal.org/coding-standards/docs#file)However, minor nitpicks like those aren't enough to prevent an RTBC.
Great work!
Comment #12
kerasai commentedComments in source corrected per #11.
Comment #13
kerasai commentedAdding PAReview: review bonus tag, with reviews listed in issue summary.
Comment #14
klausimanual review:
But that is not an application blocker, so ...
Thanks for your contribution, kerasai!
I updated your account so you can promote this to a full project and also create new projects as either a sandbox or a "full" project.
Here are some recommended readings to help with excellent maintainership:
You can find lots more contributors chatting on IRC in #drupal-contribute. So, come hang out and stay involved!
Thanks, also, for your patience with the review process. Anyone is welcome to participate in the review process. Please consider reviewing other projects that are pending review. I encourage you to learn more about that process and join the group of reviewers.
Thanks to the dedicated reviewer(s) as well.
Comment #15
dsnopekHuzzah! Congrats, @kerasai! :-)
Comment #16.0
(not verified) commentedAdded review bonus