Forums / Code Collaboration / Working on new Installer for v1.6.0 ...

Working on new Installer for v1.6.0 ...

Started by wilt on 9 May 2013, 3:44 PM · Views: 15,520

Results 1 to 20 of 42
9 May 2013, 3:44 PM
#1
wilt avatar

wilt

Oji-san

Join Date:
Jun 2003
Location:
Newcastle UK
Posts:
1,934
Plugin Contributions:
3

Working on new Installer for v1.6.0 ...

Hi,

Just wanted to plug the github repository once more, and also announce that we have pushed code for the new installer in v1.6.

https://github.com/zencart/zencart/commit/108d87d307f74884bc871c02512277dc009e820e

We have also uploaded a couple of videos to our youtube channel to show off the new installer.

http://www.youtube.com/zencart

disclaimer: v1.6.0 is work in progress. you should not use the 1.6.0 code on github for a live store until it is officially released and merged to master.

9 May 2013, 4:53 PM
#2
design75 avatar

design75

Totally Zenned

Join Date:
Dec 2009
Location:
Amersfoort, The Netherlands
Posts:
2,862
Plugin Contributions:
5

Re: Working on new Installer for v1.6.0 ...

Nice job on the installer.
One minor thing, why am I required to enter a database password. On my localhost I don't use a password, because it is not necessary. Of-course production server are required to use one. Now i need to add (and remember) a password to the database.

9 May 2013, 6:23 PM
#3
wilt avatar

wilt

Oji-san

Join Date:
Jun 2003
Location:
Newcastle UK
Posts:
1,934
Plugin Contributions:
3

Re: Working on new Installer for v1.6.0 ...

Design75:

Nice job on the installer.
One minor thing, why am I required to enter a database password. On my localhost I don't use a password, because it is not necessary. Of-course production server are required to use one. Now i need to add (and remember) a password to the database.

While it's not necessary, I have a password on my localhost database. I guess we could make the password non-required, given that hosts will definitely set a password.

9 May 2013, 8:37 PM
#4
wilt avatar

wilt

Oji-san

Join Date:
Jun 2003
Location:
Newcastle UK
Posts:
1,934
Plugin Contributions:
3

Re: Working on new Installer for v1.6.0 ...

If you want to remove the requirement yourself, you need to edit zc_install/includes/templates/database_default.php

around line 130 you should see this javascript

$().ready(function() {
  $("#db_setup").validate({
    submitHandler: function(form) {
      ajaxTestDBConnection(form);
    },
    rules: {
      db_host: "required",
      db_user: "required",
      db_password: "required",
      db_name: "required",
      sql_cache_dir: {
        required: function(element) {
          return $("#sql_cache_method").val() == 'file';
        }
      }  
    },
    messages: {
    }
  }); 
});

and you need to remove the line

      db_password: "required",
9 May 2013, 8:55 PM
#5
design75 avatar

design75

Totally Zenned

Join Date:
Dec 2009
Location:
Amersfoort, The Netherlands
Posts:
2,862
Plugin Contributions:
5

Re: Working on new Installer for v1.6.0 ...

Thank you, I will try.
In the mean time I added a password to the database user, and proceeded.
I encountered a new problem. When the databases are created and being filled with the demo data the installation program stops. The progress bar stay at almost filled, end never proceeds any further.
This happen only on my local install with xampp 1.8.1, winxp, php 5.4.7, Apache/2.4.3, 5.5.27 - MySQL
On a normal productoin server all is okay

10 May 2013, 8:40 AM
#6
torvista avatar

torvista

Totally Zenned

Join Date:
Aug 2007
Location:
Gijón, Asturias, Spain
Posts:
2,878
Plugin Contributions:
7

Re: Working on new Installer for v1.6.0 ...

As per the previous poster, I tried this on a local install xampp 181, php 5.4.7 but not using the default configurations for php.ini nor apache httpd.conf due to previous problem solving attempts. Also using virtual hosts rather than alias.

I subscribe to the design theory: "Don't make me think" (or rather "...assume I cannot think").
It looks great and very important for first impressions.

Some nitpicking comments:

  1. I note tabbing between the input fields requires an extra click every time.

  2. Database setup screen: why not check for the existence of the mysql server when entering this page and flag it immediately?

  3. Creating database:
    I got multiple repeat error messages:
    Warning: sha1_file(DIR_FS_CATALOGDIR_WS_INCLUDESconfigure.php): failed to open stream: No such file or directory in D:\My Documents\GitHub\zc-v1-series\zc_install\includes\functions\password_funcs.php on line 118

The read.md says you have to rename the configures, why? They get created and the store works without doing that.

  1. I think the labels stating that you must make a note of your password and the new name of the admin folder should be more in your face.

  2. There are some minor validation errors (using Total Validator) on each page.

  3. Shop: alt-nav looks like the page is broken, no css is loaded.

What about detecting its a localhost install and creating local/configure.php?

Steve

Steve
github.com/torvista: BackupMySQL, Structured Data, Multiple Copy-Move-Delete, Google reCaptcha, Image Checker, Spanish Language Pack and more...

10 May 2013, 8:59 AM
#7
torvista avatar

torvista

Totally Zenned

Join Date:
Aug 2007
Location:
Gijón, Asturias, Spain
Posts:
2,878
Plugin Contributions:
7

Re: Working on new Installer for v1.6.0 ...

I also could not see the wood for the tree:
"Setup Finshed"

Steve
github.com/torvista: BackupMySQL, Structured Data, Multiple Copy-Move-Delete, Google reCaptcha, Image Checker, Spanish Language Pack and more...

10 May 2013, 11:20 AM
#8
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,120
Plugin Contributions:
56

Re: Working on new Installer for v1.6.0 ...

torvista:

What about detecting its a localhost install and creating local/configure.php?

Steve
Oh, nice one!:yes:

10 May 2013, 7:58 PM
#9
wilt avatar

wilt

Oji-san

Join Date:
Jun 2003
Location:
Newcastle UK
Posts:
1,934
Plugin Contributions:
3

Re: Working on new Installer for v1.6.0 ...

Design75:

Thank you, I will try.
In the mean time I added a password to the database user, and proceeded.
I encountered a new problem. When the databases are created and being filled with the demo data the installation program stops. The progress bar stay at almost filled, end never proceeds any further.
This happen only on my local install with xampp 1.8.1, winxp, php 5.4.7, Apache/2.4.3, 5.5.27 - MySQL
On a normal productoin server all is okay

Do you see any relevant info in the logs directory.
Also helpful would be to install firebug in your browser. That might throw up any Javascript errors that are occuring.

I will try and do a run through with a xampp install when I get a chance.

Thanks for the feedback :)

10 May 2013, 8:03 PM
#10
design75 avatar

design75

Totally Zenned

Join Date:
Dec 2009
Location:
Amersfoort, The Netherlands
Posts:
2,862
Plugin Contributions:
5

Re: Working on new Installer for v1.6.0 ...

wilt:

Do you see any relevant info in the logs directory.
Also helpful would be to install firebug in your browser. That might throw up any Javascript errors that are occuring.

I will try and do a run through with a xampp install when I get a chance.

Thanks for the feedback :)

No error-logs, the installer just stops.
I will try again later this evening, and check on the javascripts

10 May 2013, 8:06 PM
#11
wilt avatar

wilt

Oji-san

Join Date:
Jun 2003
Location:
Newcastle UK
Posts:
1,934
Plugin Contributions:
3

Re: Working on new Installer for v1.6.0 ...

torvista:

As per the previous poster, I tried this on a local install xampp 181, php 5.4.7 but not using the default configurations for php.ini nor apache httpd.conf due to previous problem solving attempts. Also using virtual hosts rather than alias.

I subscribe to the design theory: "Don't make me think" (or rather "...assume I cannot think").
It looks great and very important for first impressions.

Some nitpicking comments:

  1. I note tabbing between the input fields requires an extra click every time.

  2. Database setup screen: why not check for the existence of the mysql server when entering this page and flag it immediately?

  3. Creating database:
    I got multiple repeat error messages:
    Warning: sha1_file(DIR_FS_CATALOGDIR_WS_INCLUDESconfigure.php): failed to open stream: No such file or directory in D:\My Documents\GitHub\zc-v1-series\zc_install\includes\functions\password_funcs.php on line 118

The read.md says you have to rename the configures, why? They get created and the store works without doing that.

  1. I think the labels stating that you must make a note of your password and the new name of the admin folder should be more in your face.

  2. There are some minor validation errors (using Total Validator) on each page.

  3. Shop: alt-nav looks like the page is broken, no css is loaded.

What about detecting its a localhost install and creating local/configure.php?

Steve

Thanks for the detailed feedback Steve.

I'll address the tab order asap :)

  1. Database setup screen: why not check for the existence of the mysql server when entering this page and flag it immediately?

Not sure what you mean here. The system checking code should have already tried to see if there is a live mysql server, and if not informed you on the initial screen.

  1. Creating database:

Noted: Will check code.

The read.md says you have to rename the configures, why? They get created and the store works without doing that.

Apologies the read.md is a little out of date, and based on old installer/v1.51

  1. I think the labels stating that you must make a note of your password and the new name of the admin folder should be more in your face.
    Fair enough :)
  1. There are some minor validation errors (using Total Validator) on each page.
    Double fair enough :)
  1. Shop: alt-nav looks like the page is broken, no css is loaded.
    Assume you mean the admin menu alt-nav. You haven't signed an NDA so I can't tell you that there will be changes coming to the admin menu infrastructure.

What about detecting its a localhost install and creating local/configure.php?
Nice idea. will ponder. :)

10 May 2013, 8:23 PM
#12
design75 avatar

design75

Totally Zenned

Join Date:
Dec 2009
Location:
Amersfoort, The Netherlands
Posts:
2,862
Plugin Contributions:
5

Re: Working on new Installer for v1.6.0 ...

I just tried installing again, same result. This time I checked the apache logs, and found the following

[Fri May 10 22:12:17.468750 2013] [:error] [pid 5072:tid 500] [client 127.0.0.1:1050] PHP Warning:  fopen(F:\\xampp\\htdocs\\zen4all.nl160beta/logs/progress.json): failed to open stream: Invalid argument in F:\\xampp\\htdocs\\zen4all.nl160beta\\zc_install\\includes\\classes\\class.zcDatabaseInstaller.php on line 330, referer: http://localhost/zen4all.nl160beta/zc_install/index.php?main_page=database
[Fri May 10 22:12:17.468750 2013] [:error] [pid 5072:tid 500] [client 127.0.0.1:1050] PHP Warning:  fwrite() expects parameter 1 to be resource, boolean given in F:\\xampp\\htdocs\\zen4all.nl160beta\\zc_install\\includes\\classes\\class.zcDatabaseInstaller.php on line 332, referer: http://localhost/zen4all.nl160beta/zc_install/index.php?main_page=database
[Fri May 10 22:12:17.468750 2013] [:error] [pid 5072:tid 500] [client 127.0.0.1:1050] PHP Warning:  fclose() expects parameter 1 to be resource, boolean given in F:\\xampp\\htdocs\\zen4all.nl160beta\\zc_install\\includes\\classes\\class.zcDatabaseInstaller.php on line 333, referer: http://localhost/zen4all.nl160beta/zc_install/index.php?main_page=database
10 May 2013, 9:10 PM
#13
lhungil avatar

lhungil

Totally Zenned

Join Date:
Feb 2012
Location:
mostly harmless
Posts:
1,816
Plugin Contributions:
4

Re: Working on new Installer for v1.6.0 ...

torvista:

...
The read.md says you have to rename the configures, why? They get created and the store works without doing that.
...
Have not played with the installer yet, So apologies if this already happens during an upgrade....

I'd like to see the first step handling the "configure.php" files rename the originals if present, pull in the variables as needed while installing, write brand new "configure.php" files, and optionally delete the old configure.php when done.

This would ensure the old files are present as a "backup" from before upgrading... Make sure people have the most recent (and a clean) version of the "configure.php" (including any changes such as the automatic "admin folder location" change in 1.5)... And make it easier for people to do a manual "diff" to see what has changed (if anything) between versions.

The glass is not half full. The glass is not half empty. The glass is simply too big!
Where are the Zen Cart Debug Logs? Where are the HTTP 500 / Server Error Logs?
Zen Cart related projects maintained by lhûngîl : Plugin / Module Tracker

11 May 2013, 12:19 AM
#14
torvista avatar

torvista

Totally Zenned

Join Date:
Aug 2007
Location:
Gijón, Asturias, Spain
Posts:
2,878
Plugin Contributions:
7

Re: Working on new Installer for v1.6.0 ...

The system checking code should have already tried to see if there is a live mysql server, and if not informed you on the initial screen.
With mysl server off and my pc disconnected from the internet no page detects the absence of the mysql server...it only gets flagged after entering the db details on Database setup page and pressing Continue.

Its a small point but I am thinking brand new user here and a bit of psychology, I know I would want the initial inspection page to tell me that all is not well, but would be irritated on being informed only after filling in form fields...which no doubt would time out before I had fixed the problem.

Languages
I see the installer text has been moved to language defines...I created another to see if it would automagically offer the two choices but no!
Maybe it should detect the presence of other language files and offer the choices automatically. Pretty important for world domination I would say.
Since its only one file it should be easy to get a multi-language installer completed by the community once its finalised.

When the databases are created and being filled with the demo data the installation program stops. The progress bar stay at almost filled, end never proceeds any further.
I had a similar problem with Apsona running locally on php 5.4.7. when importing a csv. It was due to php strict warnings (that initially did not appear) that I could not supress.

I have now tried the installer using the default xampp 1.8.1 php.ini and apache httpd.conf and it works for me using virtual hosts and/or if located in the default xampp \htdocs directory.

/local/whatever
I feel this aspect of zen cart is not well-known and a discussion for another thread which I'll kick-start in due course...

Steve
github.com/torvista: BackupMySQL, Structured Data, Multiple Copy-Move-Delete, Google reCaptcha, Image Checker, Spanish Language Pack and more...

11 May 2013, 2:39 PM
#15
commentics avatar

commentics

New Zenner

Join Date:
Oct 2012
Posts:
7
Plugin Contributions:
1

Re: Working on new Installer for v1.6.0 ...

Similar issue and error messages as 'Design75' in posts #5 and #12.

The 'Loading Demo Data' modal window permanently froze as it was near the end.

Local install of Wamp 2.2 running PHP 5.4.3, MySQL 5.5.24 and Apache 2.4.2 on Windows 7 64 bit with Firefox 20.0.1.

Only change made was to remove the password requirement in post #4.

Apache error log attached (as it exceeded the maximum character limit).

Attachment #12484

11 May 2013, 7:39 PM
#16
wilt avatar

wilt

Oji-san

Join Date:
Jun 2003
Location:
Newcastle UK
Posts:
1,934
Plugin Contributions:
3

Re: Working on new Installer for v1.6.0 ...

Commentics:

Similar issue and error messages as 'Design75' in posts #5 and #12.

The 'Loading Demo Data' modal window permanently froze as it was near the end.

This is a weird error as the file in question must have been written to before if the main sql progress bar completed.

When writing the Ajax/Json progress logging initially, I would see some problems myself, but thought I had ironed them out.

It's more than likely a race condition where the attempt to write to the file is blocked by an ongoing read (due to the asynchronous nature of Ajax)

Will put some code in to test the validity of the file resource, which should hopefully mitigate the race condition.

11 May 2013, 9:33 PM
#17
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,120
Plugin Contributions:
56

Re: Working on new Installer for v1.6.0 ...

My initial comments (the installer interface looks good!):

System Setup Screen

  • Need to determine which 'version' of English is to be used: licence vs license
    **
    Database Setup**
  • I made the change noted in post#4 regarding the database password; I've never set one on my localhost/XAMPP testing
  • What happened to SQL cache method: None?
  • Database Charset dropdown, is there Latin9 (should be latin1?)

Admin Setup

  • Messages regarding initial password (This is your initial temporary password for your Admin Superuser Account. Please ensure you make a note of it.) and initial directory (Your store Admin directory has been automatically renamed. Please ensure you make a note of this directory.) appear below the associated fields; I was confused initially as to which field was associated with the message and think it would flow better if the messages were either above or beside the associated field. I tend to read top->bottom, left->right (that might be different in different cultures).

Setup Finished

  • The message (You need to remove the /zc_install folder so that someone can't re-install your shop again and wipe out your database! Warnings will appear until the folder has been removed ) is overly scary.
    -The message "warnings will appear" is not quite correct because I can't log into the admin without the rename. A "warning" shouldn't be as insistent; the message should read "A message will appear and you will not be able to log into your admin until the folder has been removed." (or something of the ilk).

Admin main page

  • Click the V on General Statistics. TEXT_CANCEL instead of Cancel

Admin Configuration Menu

  • Dropdown shows Cowoa Checkout ... shouldn't it be COWOA (all caps)?
  • Once in Cowoa Checkout, the page title reads "Guest Checkout" ... shouldn't it be the same as the dropdown title?
  • I thought that the zen_trace function was supposed to be included in v1.6.0, but couldn't find it in the Configuration->Logging menu.

Storefront, COWOA checkout

  • Some funky formatting going on with the progress bar:
    Attachment 12488
12 May 2013, 4:12 PM
#18
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,120
Plugin Contributions:
56

Re: Working on new Installer for v1.6.0 ...

Just a couple more questions:

  1. Looking in /zc_install/sql/updates, it appears that there will be an upgrade path from 1.3.9, 1.5.0 or 1.5.1 to v1.6.0 ... but not any earlier release. I just wanted to note this for confirmation and to provide (yet another) heads-up to those store-owners still running a v1.3.8 or earlier store.
  2. There's no mysql_latin1.sql file in /zc_install/sql/install; I'm assuming that that's just an oversight ...
12 May 2013, 6:15 PM
#19
wilt avatar

wilt

Oji-san

Join Date:
Jun 2003
Location:
Newcastle UK
Posts:
1,934
Plugin Contributions:
3

Re: Working on new Installer for v1.6.0 ...

lat9:

Just a couple more questions:

  1. Looking in /zc_install/sql/updates, it appears that there will be an upgrade path from 1.3.9, 1.5.0 or 1.5.1 to v1.6.0 ... but not any earlier release. I just wanted to note this for confirmation and to provide (yet another) heads-up to those store-owners still running a v1.3.8 or earlier store.
  1. There's no mysql_latin1.sql file in /zc_install/sql/install; I'm assuming that that's just an oversight ...

There probably will be an upgrade path for older versions, although we have not yet decided how far back we will go with that path. It almost certainly won't go back to 1.2 as the old installer does.

Yes, the latin1 file was overlooked :blush:

12 May 2013, 6:24 PM
#20
wilt avatar

wilt

Oji-san

Join Date:
Jun 2003
Location:
Newcastle UK
Posts:
1,934
Plugin Contributions:
3

Re: Working on new Installer for v1.6.0 ...

lat9:

My initial comments (the installer interface looks good!):

System Setup Screen

  • Need to determine which 'version' of English is to be used: licence vs license
    K, that's the prob with having core team spread between UK/USA/Canada. :blink:

Database Setup

  • I made the change noted in post#4 regarding the database password; I've never set one on my localhost/XAMPP testing
  • What happened to SQL cache method: None?
  • Database Charset dropdown, is there Latin9 (should be latin1?)
    Ive removed the required option now on the DB password. My bad on missing the None option. Similarly with the latin1/9

Admin Setup

  • Messages regarding initial password (This is your initial temporary password for your Admin Superuser Account. Please ensure you make a note of it.) and initial directory (Your store Admin directory has been automatically renamed. Please ensure you make a note of this directory.) appear below the associated fields; I was confused initially as to which field was associated with the message and think it would flow better if the messages were either above or beside the associated field. I tend to read top->bottom, left->right (that might be different in different cultures).

Agreed, and othere have pointed this out as well. Will try and rejig that page to make the prompts better.

Setup Finished

  • The message (You need to remove the /zc_install folder so that someone can't re-install your shop again and wipe out your database! Warnings will appear until the folder has been removed ) is overly scary.
    -The message "warnings will appear" is not quite correct because I can't log into the admin without the rename. A "warning" shouldn't be as insistent; the message should read "A message will appear and you will not be able to log into your admin until the folder has been removed." (or something of the ilk).

Noted :smile:

Admin main page

  • Click the V on General Statistics. TEXT_CANCEL instead of Cancel

Admin Configuration Menu

  • Dropdown shows Cowoa Checkout ... shouldn't it be COWOA (all caps)?
  • Once in Cowoa Checkout, the page title reads "Guest Checkout" ... shouldn't it be the same as the dropdown title?
  • I thought that the zen_trace function was supposed to be included in v1.6.0, but couldn't find it in the Configuration->Logging menu.

Storefront, COWOA checkout

  • Some funky formatting going on with the progress bar:
    Attachment 12488

COWOA and other checkout stuff will be getting a refresh shortly once I finish and merge the new checkout flow infrastructure code.