Opened 5 years ago

Closed 5 years ago

#700 closed Bug (fixed)

add a check for ZLIB extension at install

Reported by: matt Owned by: vipsoft
Priority: major Milestone: Piwik 0.4.3
Component: Core Keywords:
Cc: Sensitive:

Description

currently we don't check that the user has the zlib extension, but it is required for piwik to work correctly. We should add this check at installation.

Attachments (7)

700_check_zlib.patch (725 bytes) - added by pebosi 5 years ago.
700_systemcheck.patch (2.5 KB) - added by pebosi 5 years ago.
700_gd_systemcheck.patch (2.4 KB) - added by pebosi 5 years ago.
next try
700_spl_systemcheck.patch (2.4 KB) - added by pebosi 5 years ago.
added spl check
700_spl_systemcheck.2.patch (2.5 KB) - added by pebosi 5 years ago.
updated patch
systemCheck.tpl (3.2 KB) - added by pebosi 5 years ago.
updated template file, no patch
700_systemcheck_template.patch (3.6 KB) - added by pebosi 5 years ago.
patch for template file

Download all attachments as: .zip

Change History (22)

comment:1 Changed 5 years ago by matt (mattab)

  • Milestone changed from 1- RobotRock to 1 - Piwik 0.4

comment:2 Changed 5 years ago by pebosi

added a patch to check extensions array for zlib.

Changed 5 years ago by pebosi

comment:3 Changed 5 years ago by pebosi

i created another patch to reduce some code, only a suggestion... (if useful i will modify template too)

regards

Changed 5 years ago by pebosi

comment:4 Changed 5 years ago by vipsoft (robocoder)

pebosi: it looks good with the exception of the changes from lines 488-499. It looks like the version requirement has been reversed; meanwhile, there's no check when the gd extension is missing.

comment:5 Changed 5 years ago by pebosi

my last patch also removes traling spaces...

comment:6 Changed 5 years ago by matt (mattab)

pebosi, your patch is hard to read as you removed all white spaces etc.
can you please submit patch against trunk for only the lines you modified?

Changed 5 years ago by pebosi

next try

comment:7 Changed 5 years ago by pebosi

added patch version without removing whitespaces

comment:8 Changed 5 years ago by matt (mattab)

assuming it has been tested, looks good to me

comment:9 Changed 5 years ago by matt (mattab)

actually we should also add SPL to the list of required extension as of #176

Changed 5 years ago by pebosi

added spl check

comment:10 Changed 5 years ago by vipsoft (robocoder)

Looks good (except for some minor formatting). Can you update the systemCheck template too and test it?

Changed 5 years ago by pebosi

updated patch

Changed 5 years ago by pebosi

updated template file, no patch

comment:11 Changed 5 years ago by pebosi

attached an updated patch and the first version of tempalte file (no patch). i replaced the help text of gd and extension-check with a link to http://piwik.org/docs/requirements/ (needs to be updated then)... only a suggestion ;)

regards

Changed 5 years ago by pebosi

patch for template file

comment:12 Changed 5 years ago by matt (mattab)

  • Milestone changed from 1 - Piwik 0.4 to Piwik 0.4.1

comment:13 Changed 5 years ago by vipsoft (robocoder)

Sorry for not reviewing this sooner.

  • Controller.php: ereg should be replaced with preg_match() for php 5.3
  • systemCheck.tpl: one link to http://piwik.org/docs/requirements/ should be sufficient
  • lang/en.php needs to be updated

We should add/keep the informative help messages (e.g., Installation_SystemCheckPdoHelp). Perhaps:

$needed_functions = array(
    'set_time_limit' => 'Installation_SystemCheckTimeLimitHelp',
    'mail'           => 'Installation_SystemCheckMailHelp',
);

comment:14 Changed 5 years ago by vipsoft (robocoder)

  • Owner set to vipsoft
  • Status changed from new to assigned

comment:15 Changed 5 years ago by vipsoft (robocoder)

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [1368]) fixes #700 - added check for zlib and SPL at install; based on pebosi's patch

Note: See TracTickets for help on using tickets.