Not working for me too

Drupal RC2, latest module (1.37) from CVS

On Releases page - only headers, without any modules in list; in database - string 'N;' in cvsversions column and timestamp of last update. That's all.

No error messages in log of apache and in Drupal logs.

Comments

cog.rusty’s picture

I also see this on PHP4.4, MySQL 4.0. No modules are ever listed.
It does work on localhost using PHP 5.2, MySQL 5.0
I manually executed the update query in settings in both cases.

Possibly a clue:
- In the first case, in the Releases page, I read "The Release Monitor module () monitors Drupal for updates".
- In the second case the empty parentheses contain releasemonitor's cvsid, "(1.37)".

douggreen’s picture

Title: Does not work » Does not work on php4
Assigned: Unassigned » douggreen
Priority: Normal » Critical

As far as I know, this is exclusively a php4 problem. It has been reported, I can reproduce it, and I've mentioned it in other issues (such as 107695). For the sake of clarity, I have changed the title on this issue. I am going to mark the other issues as a duplicate and leave this one open.

The problem is that php4 and php5 treat objects considerably differently, and the my code uses objects fairly heavily to store the projects and modules. I've brought this issue up with the Drupal development list, and I believe that the best solution is to replace the objects with arrays, as this is pretty much the "Drupal way". This switch, though, is not trivial. I hope to get to it within the next week, but no promises.

Thanks for understanding, ... and if there is any way to switch to php5, I'd recommend that you do so.

chrissearle’s picture

Just tracking this issue

ray007’s picture

Just tracking the issue too.

Are there any special problems with the conversion, or just the universal one we all have: time?

Unfortunately, there's currently no way I can switch the server to php5 ...

douggreen’s picture

I developed releasmonitor heavily using objects rather than arrays only to learn that php4 and php5 differ considerably in how these work. It's a fairly major rewrite and a time issue...

denney’s picture

Subscribing to this issue.

ebremer’s picture

Doesn't work for me CentOS 4 with php-4.3.9-3.22

nickistre’s picture

Subscribing.

forseti’s picture

Subscribing.

Andy Ramblings’s picture

Subscribing, for the PHP 4 issue,

pancho’s picture

ditto

pyutaros’s picture

subscribing

pyutaros’s picture

Wow, like pretty freakin amazing. My webhost seems to have a toggle feature for php 4 vs 5. ver 4 = broke. Ver 5 = happy me. And since Doug seems pretty busy here, don't think we're gonna see a fix here any time soon, unless someone wants to look into how php handles arrays differently in ver 4 and try to create a parallel module build.

douggreen’s picture

If some submits a php4 patch, I'd be happy to look at it and hopefully apply it. I would hope that no one creates a parallel version.

munga’s picture

subscribing

Joe One’s picture

subscribing

cordery’s picture

Having taken a brief look at the code it doesnt appear that you are using much of what makes PHP5s object handling different. I'd say the only real difference that would affect this code is that in PHP4 assigning an object to a variable copies the object, while in php5 it creates a reference to the original object. In other words the php4 equivalent of

PHP5 $myvar = $object

is

PHP4 $myvar =& $object.    

If you go through your code and keep in mind that every time you've passed an object around without using a =& reference you are duplicating that object in php4, and thus any changes you make to it will not affect the original object, it should be pretty simple to fix this up.

ray007’s picture

I've tried to do a quick conversion that way and failed.
But then I do not know the code ...

douggreen’s picture

Most of the problem is in _releasemonitor_load_projects. If anyone wants to take a crack at it, that's where you should start.

alkcxy’s picture

subscribing

revival’s picture

subscribing

widhalmt’s picture

subscribing

MacRonin’s picture

Subscribing for the PHP4 issue

jacauc’s picture

Great Module! Hope the php4 issue can be sorted out. Unfortunately, my PHP skills is dangerous.. Will keep an eye on this issue though.
Thanks!

douggreen’s picture

Status: Active » Fixed

Please get the latest 5.x-1.x-dev release. As the Drupal packaging system sometimes takes awhile to package up updates, make sure you have releasemonitor.module 1.43.

yched’s picture

i get a 'call to unknown function is_php4' error on hitting 'requery now' on admin/settings/releasemonitor page

douggreen’s picture

Sorry, I removed the is_php4 function after discovering that this needed to be done with both php4 and php5. Please check out and try again.

ray007’s picture

Status: Fixed » Active

Hmm, looks promising, but still some things to fix ...

The "Requery Now" Button on the settings page returns an empty html document after quite some time.

When starting with an empty version-table in the DB and "Display CVS information and links" not checked, there's a message saying "Status not completely retrieved for ", but I do see some results in the admin/build/releases screen. After a few calls on this page, it only returns an empty html -> white screen.

Haven't yet seen any results with "Display CVS information and links" enabled.

Using version 1.44, re-opening the report.

chrissearle’s picture

Interesting. Once I got the CVS version in - it worked fine. I see all modules with details. It did take two refreshes to get the list but after that - just fine.

When you say empty page - do you mean completely empty (no menus etc etc) or just the release info missing?

A completely empty page is often the sign that the page has taken more memory in generating than the php config allows - so you'd need to up the minimum memory in php.ini.

ray007’s picture

by "empty" I mean: zero-length result from server ... no html tags, no nothing.
I'll check the mem-settings, though I didn't want to change those for the drupal installation ...

And I didn't use a cvs-checkout, but the dev-snapshot from this morning. File-head says version 1.44.

douggreen’s picture

Look at your web server (apache) error log the next to you get the empty page. It will help isolate if it is a programming problem or a system resource problem. If it's anything other than "out-of-memory", please post the error message back here. If it's "out-of-memory", then increase your php memory_limit.

ray007’s picture

Version 1.45 seems to work fine, thanx a lot!

MacRonin’s picture

Just another data point.

I just tried The Release monitor again after upgrading to 1.44

I now get the module listing and the major/minor download buttons. A quick glace seems to have the choices as accurate.

BTW I am on Drupal 5.1 + PHP 4.4.2 and Apache 2.0.53

douggreen’s picture

Status: Active » Fixed
Anonymous’s picture

Status: Fixed » Closed (fixed)