Comments

akalsey’s picture

Kyle Browning has been working on porting to D7

https://github.com/kylebrowning/activitystream

ramper’s picture

Thanks. Subscribing.

jennifermontes’s picture

Subscribe

lsolesen’s picture

This issue needs to be resolved before real testing of Kyle Brownings port can be tested: http://drupal.org/node/987430

lsolesen’s picture

https://github.com/kylebrowning/activitystream is sort of in a working state, so it automatically imports the streams, and you can use views to display them. However, #4 still needs to be sorted out, and it seems that there is a "Broken handler activitystream.icon:" when you try to fetch the icon using views.

matt2000’s picture

For #4, checkout how forum_get_topics was upgraded:

http://api.drupal.org/api/drupal/modules--forum--forum.module/function/f...

xurizaemon’s picture

Status: Active » Needs work

Looking at Kyle's port on Github.

Creating a feed throws an error -

PDOException: SQLSTATE[HY000]: General error: 1364 Field 'lastfetch' doesn't have a default value: INSERT INTO {activitystream_accounts} (module, uid, userid, password, feed) VALUES (:module, :uid, :userid, :password, :feed); Array ( [:module] => activitystream_feed [:uid] => 1 [:userid] => [:password] => [:feed] => https://example.org/feed.atom ) in activitystream_save_account() (line 48 of /home/www-home/drupal7/sites/all/modules/activitystream/activitystream.module).

  $schema['activitystream_accounts'] = array(
    'fields' => array(
       /* ... */
       'lastfetch' => array('mysql_type' => 'datetime', 'not null' => TRUE)), //NOTE, see documentation here for why this becomes mysql_type: http://drupal.org/update/modules/6/7#db_specific_types
       );
 

'lastfetch' needs a default value if it's not null, and wants type defs for non-mysql DB backends.

donSchoe’s picture

Subscribing.

littlecow’s picture

Subscribing.

Renegadez’s picture

Subz

BenK’s picture

Subscribing

bochenn’s picture

Have you find a fix for this? I'm having the same problem and i'm not a php-guy so i'm stucked.

Thanks.

Bochenn

xurizaemon’s picture

I've got some work on Github as a fork of kyle's start.

It's not finished but you are welcome to fork and improve it, or just grab a tarball and test and report back ...

EDIT: forgot the URL :P https://github.com/GiantRobot/activitystream

bochenn’s picture

@grobot, your code worked fine. One doubt now. How can I access my activity stream? I followed the steps from this screencast http://www.brianstevenson.com/drupal/screencasts/installing-activitystream

Thanks!

xurizaemon’s picture

Cheers bochenn. I'm sure there will still be a few things to fix but appreciate your testing! I will try to get a patch back here for review in the meantime.

If not seeing any ActivityStream items, check you have the appropriate views enabled (and thus views & views UI modules enabled too).

Afaik my fork builds on and includes all of what what Kyle has done.

xurizaemon’s picture

StatusFileSize
new9.24 KB

I am fairly confident there's lots to be done yet; I have not tested all the builtin modules (Twitter, Delicious appear to work). Review welcome.

This is a patch to be applied to current DRUPAL-7--2. It includes Kyle's latest work on Github, which was committed to CVS in November.

erdembey’s picture

Subscribing

bochenn’s picture

Hi @grobot, i'm not good with git nor patch. Can you send me those files fixed?

Thanks

xurizaemon’s picture

@bochenn, that's OK - you can still contribute by testing!

Comment #13 above has a link to my Github repo which has a "download" link from which you can grab a current tarball of the version I'm working on.

Direct URL: https://github.com/GiantRobot/activitystream/tarball/DRUPAL-7--2

You want to rename the resulting folder from "GiantRobot-activitystream-aabbccdd" to just "activitystream" before installing to your Drupal site.

Please use that to test and report back on your successes or any issues you may find.

Note that you will NOT receive update notifications when using tarballs downloaded from sites other than Drupal.org; you will need to track this issue until some activitystream-7.x-2.x version is released here, at which point you can update your code to the contrib version from Drupal.org.

bochenn’s picture

Thanks @grobot your code is not giving me any errors. But...i can't see the feed in the live site. In the drupal 6 version of the module i could access the feed by browsing http://localhost/stream.
How can I access it in the drupal 7 version?

Thanks in advance, you are awesome!

xurizaemon’s picture

Thanks for identifying this. I see there's a bit of work to do to get ActivityStream updated to use D7 theme layer correctly and will update this issue once I have a chance to do so.

The main issue seems to be that theme() takes an array as the second parameter in D7, where in D6 you could pass multiple parameters. The module has been fixed for this in some places, but not all.

eg (in case someone wants to have a crack at running through this - it's pretty straightforward)
theme('item_list', $items, $title)
becomes
theme('item_list', array('items' => $items, 'title' => $title))

PS. @bochenn - Sounds like you might want to adjust your error reporting settings for local development setup, as you're seeing a blank page where you ought to be seeing a fatal error. Error messages are very useful information :)

xurizaemon’s picture

Also - you may find you can see some ActivityStream items in the block which this module provides?

bochenn’s picture

When i try this url I get this fatal error:

http://localhost/stream

Fatal error: Unsupported operand types in /Applications/MAMP/htdocs/includes/theme.inc on line 817

Is that what you mean?

Thanks

xurizaemon’s picture

Yep, sounds like your error reporting settings are just fine :)

That is the error I meant; theme() is complaining about being passed arguments it doesn't like.

bochenn’s picture

I think I must wait for a stable version to be released.
Thanks

xurizaemon’s picture

StatusFileSize
new20.72 KB

Theme fixes for Twitter and Delicious - still need same fixes to be applied to the other submodules (Feed, Last FM, Flickr, Digg).

Thanks for the nudge @bochenn!

jennifermontes’s picture

Title: Port to Drupal 7? » Port Activity Stream to Drupal 7?

Changed thread title to make it it easier to keep track of.

dooug’s picture

@grobot, I gathered from GitHub that your fork is the most up to date (https://github.com/GiantRobot/activitystream/network) so I cloned what you had there. Let me know if I am mistaken, I am new to GitHub. I will be doing what development/testing I can. So far I have been working on converting the activitystream blocks to use the D7 API.

damienmckenna’s picture

All work on the D7 port should be pulled back to d.o, use sandboxes if needed.

drnikki’s picture

subscribe.

akalsey’s picture

Damien, completely disagree. All work should happen wherever the developers of the code feel is best for them. I've used d.o.'s code repositories for packaging only for quite some time and intend to continue to do so.

sol roth’s picture

subscribe

bochenn’s picture

Hi guys.

I'm sure i'm doing something wrong because i still can't make this to work as it should.

1 - Download the module from https://github.com/GiantRobot/activitystream/
2 - Install/activate the module and sub-modules
3 - Go to User > My user and add the info for each social network i want to get my updates.
4 - I look at the blocks list if there is one block for the ActivityStream but there isn't.

Am I doing something wrong here? Can anyone help me on this?

Thanks

NickLitten’s picture

it would make this a lot clearer if the D7 version was available from the standard Drupal module download page http://drupal.org/node/238197/release

I'm uplifting my main site from D6 to D7 this weekend... will try to figure out which activity-stream port to use and will give some feedback...

Cheers.

mcncyo’s picture

subscribe

akalsey’s picture

The existing ports on github have a number of outstanding blocker-level issues against them. I'm not going to create an official release until these are cleaned up. But there is copy of the 7-2 branch in git. I've turned on the display of dev snapshots for this -- they should appear shortly.

tourendal’s picture

Subscribing

Marc Bijl’s picture

Subscribing

webankit’s picture

+1

devicehandler’s picture

Im getting this error, is there something I am missing? "The website encountered an unexpected error. Please try again later." Sorry forgot to say, this happens each time I attempt to save my user name details for my acounts (twitter, last.fm) :)

zoozi’s picture

Version: 6.x-2.x-dev » 7.x-2.x-dev
Component: Code » Miscellaneous

subscribing.

trothwell’s picture

Do Want.

g76’s picture

sub

xurizaemon’s picture

@devicehandler: turn on visible debugging, or inspect your webserver's logs, to see what's going wrong. Report back the error and we can help.

NickLitten’s picture

Working just fine with my Drupal 7.2 install.... importing from Twitter and Flickr just lovely :)

Status all show as individual nodes - display fine when viewed as RECENT CONTENT or as individual nodes but not using the /stream suffix...

noahadler’s picture

Subscribe! Sounds great!

borazslo’s picture

Subscribing

borazslo’s picture

-> installed, configured the admin settings, added my account informations
-> the new nodes were created ( I can see them on mysite.com/tracker, mysite.com/noder, etc.)

BUT: mysite.com/stream or mysite.com/stream/[myuid] -> Fatal error: Unsupported operand types in [...]/includes/theme.inc on line 830
in watchdog: Notice: Trying to get property of non-object in theme_activitystream_feed_item() (line 160 of [..]/modules/activitystream/activitystream_feed/activitystream_feed.module).

And sometimes/somewhere: (on /user/[myuid]/edit/activitystream ??)
Notice: Undefined variable: error_code in activitystream_flickr_streamapi() (line 32 of [...]/sites/all/modules/activitystream/activitystream_flickr/activitystream_flickr.module).
Notice: Undefined variable: error_msg in activitystream_flickr_streamapi() (line 32 of [...]/sites/all/modules/activitystream/activitystream_flickr/activitystream_flickr.module).

jbucks’s picture

Subscribe

lyricnz’s picture

Seems like these versions would benefit from some simpletests...

danithaca’s picture

subscribing

capnjav’s picture

Subscribing...

Will be installing the most recent port in the next couple of days.

Will get back if I run into any problems, etc.

Thanks @grobot and @akalsey

Arwym’s picture

Subscribing.

elvis2’s picture

I can confirm comment #40. On a new install of activitystream, I enable the module, then goto user/1, add twitter username on /user/1/edit/activitystream, I get the following error:

The changes have been saved.
The website encountered an unexpected error. Please try again later.

I also have the "feed" option enabled, so on my /user/1/edit/activitystream page, I have feed and twitter config options.

tlangston’s picture

subscribing

xurizaemon’s picture

StatusFileSize
new1.27 KB

@elvis42, @devicehandler - took the following steps to attempt to reproduce what you report.

1. Installed clean Drupal7 and ActivityStream (7.x-2.x from Git)
2. Ignored #1257430: "Assigning the return value of new by reference is deprecated" errors from simplepie.inc in ActivityStream Feed submodule errors because I'm on PHP5.3.0
3. Add Twitter username at user/1/edit/activitystream
4. Hit "Save"

PDOException: SQLSTATE[HY000]: General error: 1364 
Field 'lastfetch'; doesn't have a default value: INSERT INTO {activitystream_accounts} (module, uid, userid, password, feed) VALUES (:module, :uid, :userid, :password, :feed); Array
(
    [:module] => activitystream_twitter
    [:uid] => 1
    [:userid] => USERNAME
    [:password] => 
    [:feed] => 
)

The attached patch sets the "lastfetch" value to time 0, but an alternative would be to make this the column default so it wasn't required in the INSERT. I think this is the only insert and therefore this patch is more minimal ...

elvis2’s picture

@grobot, thanks the patch works!

anselm.marie’s picture

subscribing

BarisW’s picture

Subscribing

VinceW’s picture

in reply to #29 and #31

I agree with akalsey when saying:

All work should happen wherever the developers of the code feel is best for them

But I do share the opinion of DamienMcKenna that

All work on the D7 port should be pulled back to d.o

A d.o. release point could give much clarity about which version to have. It then can function as an inventory of the issues to tackle before having a stable release. This could give other developers a change to give a hand (or two) with the further development.

Is there any info available on when to expect a D7 (dev) release of this module on d.o.?

Best,
VinceW

xurizaemon’s picture

How about "all developers should feel that d.o. is the best place for their work to be published" then :)

@akalsey said that there will be a 7.x-2.x release when some blocker level issues with current Github work are fixed. I don't know what issues those are.

ActivityStream 7.x-2.x is available, just not highly visible.

I have a sandbox at http://drupal.org/sandbox/grobot/1285036 now, it has some stuff which hasn't been incorporated into ActivityStream 7.x-2.x yet.

Test either at your peril and keep your bug-spotting notebook handy.

alex ua’s picture

sub

mgifford’s picture

Ran this through Coder and there are several critical warnings in activitystream & activitystream_feed modules. Lots of little spacing warnings too, but those aren't as important. Thanks for providing this quiet release!

VinceW’s picture

@grobot here are some notebook notes :-)

Downloaded, installed and tested: activitystream 7.x-2.x-dev on D7 with PHP 5.3

Tried cloning your sandbox, however experienced same git error/message as in #1074584: warning: remote HEAD refers to nonexistent ref, unable to checkout.

NickLitten’s picture

Dont know if this helps but similar error message here:

Deprecated function: Assigning the return value of new by reference is deprecated in require_once() (line 15 of /home/projex/www/triumph/sites/all/modules/activitystream/activitystream_feed/activitystream_feed.module).

borazslo’s picture

first I have installed the core without any problem
after I have enabled the Feed stream and I had the same error

borazslo’s picture

In the activitystream_feed/simplepie.inc I have replaced every "=& new " with "= new " as suggested in http://goo.gl/dkSPf
so I could enable the Feed stream module without any problem

installed, and in the admin/structure/schema/compare i have received it:
"Field activitystream_accounts.lastfetch: no Schema type for mysql type datetime."
"activitystream_accounts.lastfetch: no type for Schema type :normal."

borazslo’s picture

I have enabled the Twitter module also.
In the /user/1/edit/activitystream I gave my twitter name. And received this:

Deprecated function: Function split() is deprecated in activitystream_save_account() (line 43 of [...]/activitystream.module).
Warning: Invalid argument supplied for foreach() in activitystream_twitter_streamapi() (line 26 of [...]/activitystream_twitter.module)
Notice: Undefined variable: newitems in activitystream_twitter_streamapi()(line 37 of [...]/activitystream_twitter.module).

borazslo’s picture

for the first error:
activitystream.module line 43
from: $arrfeeds = preg_split("/[\n]/", $params['feed']);
to: $arrfeeds = split("\n", $params['feed']);

for the other two:
these were because I have left empty the urls for feeds.
when I have given a valid rss url, the activitystream created the all nodes from this, but...
I saw the titles of the new nodes but without the body. When I edited these nodes I saw the body, but the input format was unassigned. (I assigned an input format manually and it was ok.)

borazslo’s picture

for the input format problems:
in the activitystream_feed/simplepie.inc change the " format => 'full_html' " to " format => '3' " on line 403, 882, 887

kylebrowning’s picture

Status: Needs work » Needs review
StatusFileSize
new129.12 KB

Using the latest head checkout, here is a patch that fixes everything for 5.3 and adds in some views features specifically for 7.x

mgifford’s picture

StatusFileSize
new167.02 KB

I pulled down the git repository & applied the patch provided by @kylebrowning. Got these errors:

warning: squelched 3 whitespace errors
warning: 8 lines add whitespace errors.

Bigger issue is that I ran it through coder and cleaned up a bunch of formatting stuff.. Should be much better now (as far as formatting).

I didn't touch simplepie.inc, phpFlickr.php or the PEAR libraries. Really not sure why PEAR's being included. Most 3rd parties code isn't just embedded in the modules. Should this get moved to the Libraries?

socialnicheguru’s picture

Deprecated function: Function split() is deprecated in activitystream_save_account() (line 43 of activitystream.module).

tried module today and got this error.

mgifford’s picture

So that's just swapping out split() for preg_split() because spit is depreciated in PHP5.3 as per:
http://www.php.net/manual/en/function.preg-split.php

@SocialNicheGuru can you roll up the next patch?

NickLitten’s picture

Can any of you PHP developers load up a 7.xDev compatible version? I have a few websites that were running 6.x Activitystream.. all since uplifted to Droop7. Would be happy to test and report back with results...

dtesenair’s picture

See comment #61. There is a link to a 7.x release. Is that what you were looking for?

NickLitten’s picture

See my reply to comment #61 at #65 ;)

The last set of patches are reporting various errors so as soon as a new patch is ready I will gladly test. Obviously this would be easier to test if it was set as a 'proper' 7x release - there does seems to be a lot of interest in it?

mgifford’s picture

September of last year seems to be the last time that this code was updated - http://drupal.org/sandbox/grobot/1285036

There's definitely interest in this, but perhaps need a kickstarter to or sponsor to work out the errors and stabilize this for a 7.x release.

xurizaemon’s picture

StatusFileSize
new207.96 KB

Rolled all patches above to date into one, attached, includes replacement of split() with explode(). Pushed that to my sandbox, but I haven't been tracking this issue and keeping it up to date so wonder if it's diluting things for it to even be there?

Anyway. Still at least some needs work, a few deprecated warnings appear on edit of user activitystream settings -

Deprecated function: Assigning the return value of new by reference is deprecated in phpFlickr::phpFlickr() (line 89 of drupal-7.14/sites/activitystream-7.x-2.x.example.org/modules/activitystream/activitystream_flickr/phpFlickr.php).
Notice: Undefined index: originalsecret in phpFlickr->buildPhotoURL() (line 306 of drupal-7.14/sites/activitystream-7.x-2.x.example.org/modules/activitystream/activitystream_flickr/phpFlickr.php).
Deprecated function: Function eregi_replace() is deprecated in activitystream_twitter_makelinks() (line 149 of drupal-7.14/sites/activitystream-7.x-2.x.example.org/modules/activitystream/activitystream_twitter/activitystream_twitter.module).

xurizaemon’s picture

StatusFileSize
new169.45 KB

Adds a README edit which was on Github, and corrects above (should have been made via git diff origin/7.x-2.x..sandbox/7.x-2.x rather than git diff origin/DRUPAL-7--2..sandbox/7.x-2.x).

One of the last few patches (and thus rolled into #79 above) seems to have upgraded SimplePie to 1.2.1 which likely resolves #1257430: "Assigning the return value of new by reference is deprecated" errors from simplepie.inc in ActivityStream Feed submodule.

It's two years old now, but jeremyfrench had some commits relating to Fields in his Github fork as well. Might be worth reviewing.

playfulwolf’s picture

Can someone post working D7 version as archive here instead of git?
Willing beta tester.

xurizaemon’s picture

@playwulf better to use the "snapshot" link on git repo of your preference & get the latest snapshot instead of a month-old zipfile

http://drupalcode.org/sandbox/grobot/1285036.git/shortlog/refs/heads/7.x... for my sandbox (activitystream-7.x-2.x.tgz)
http://drupalcode.org/project/activitystream.git/shortlog/refs/heads/7.x... for proper release (untouched by humans since 2010)

until this module gets some maintenance, recommend using it only if you're ready to hack on it or test things and report back here.

testing and reviewing the code in that sandbox is a great way to help.

morbus iff’s picture

As a general FYI, I've been working on ActivityStream 7.x-3.x in git here. The API will not be backwards compatible with earlier versions, and there's currently no (planned) upgrade path. Just throwing it out there. Nothing more to really announce at the moment, past that I have a vested interest in getting it going.

peter feddo’s picture

@Morbus Iff Awesome! Looking forward to seeing this module come back to life. Thanks for your efforts!

morbus iff’s picture

I've just committed a pre-alpha version of Activity Stream to 7.x-3.x.

* This build will allow you to subscribe to RSS and Atom feed items.
* This build will let you define your Twitter username, but nothing happens past that.
* This build starts to show a display of these items at /activitystream.

There's still plenty more to do, of course (documentation, better display, per-user streams, conversion of existing modules, etc.), but it's working well enough to say "it's kinda working". Again, this is a 3.x build, so it is *not* backwards compatible with 1.x or 2.x (which was never completed anyways). I've got a lot planned for the module over the coming months, but will likely release early and release often once I get a decent-enough 1.0 release (probably another 20 development hours away).

morbus iff’s picture

StatusFileSize
new102.56 KB

Example of the current version of the Stream display is attached.

morbus iff’s picture

The CHANGELOG.txt for 7.x-3.x is now starting to make sense:

http://drupalcode.org/project/activitystream.git/blob/refs/heads/7.x-3.x...

morbus iff’s picture

More to do, but the start of the new Activity Stream 7.x-3.x API documentation:

http://drupalcode.org/project/activitystream.git/blob/729e7ec:/activitys...

morbus iff’s picture

7.x-3.0 has been released. http://drupal.org/node/1773956

morbus iff’s picture

Status: Needs review » Fixed
NickLitten’s picture

Thanks Morb, Downloading and will give feedback on my results.... Cheers!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.