Announcement

  •  » Beta testing
  •  » [resolved] [2.6.0 RC2] still not instalable

#1 2014-01-11 00:46:30

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

[resolved] [2.6.0 RC2] still not instalable

The installation fails

Code:

[mysql error 1062] Duplicate entry 'smartpocket' for key 'PRIMARY'

INSERT INTO piwigotest_config (param,value,comment)
VALUES ('smartpocket' , 'a:2:{s:4:\"loop\";b:1;s:8:\"autohide\";i:5000;}' , 'loop#autohide');

#1  my_error /homez.59/strangep/www/piwigo_test/include/dblayer/functions_mysqli.inc.php(109)
#2  pwg_query /homez.59/strangep/www/piwigo_test/themes/smartpocket/admin/maintain.inc.php(17)
#3  theme_activate /homez.59/strangep/www/piwigo_test/admin/include/themes.class.php(34)
#4  DummyTheme_maintain::activate /homez.59/strangep/www/piwigo_test/admin/include/themes.class.php(157)
#5  themes::perform_action /homez.59/strangep/www/piwigo_test/admin/include/functions_install.inc.php(84)
#6  activate_core_themes /homez.59/strangep/www/piwigo_test/install.php(368)

why don't we use conf_update_param() in upgrade.inc.php, line 13-16 ?

Additionally I don't understand why the query seems to be executed twice

Offline

 

#2 2014-01-11 00:48:45

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

Re: [resolved] [2.6.0 RC2] still not instalable

I also don't understand what is the point if

Code:

elseif (count(unserialize( $conf['smartpocket'] ))!=2)

is it a migration task from an older version ? or just a safety test ? (seems useless for me)

Offline

 

#3 2014-01-11 00:52:16

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

Re: [resolved] [2.6.0 RC2] still not instalable

and the same error from maintain.inc.php file

I think we should use my wonderful Theme_maintain class interface :-)

at least you can remove theme_install function, because the same script is always executed if needed, in upgrade.inc.php

Offline

 

#4 2014-01-11 15:09:34

flop25
Piwigo Team
2006-07-06
7037

Re: [resolved] [2.6.0 RC2] still not instalable

hi
1- conf_update_param() doesn't use the comment column ; as you've seen, conf_update_param is used when needed
2- that's for the future and also an integrity test
3- is there a doc for your class? If we want to push this as a standard, core themes have to use it, indeed.


To get a better help : Politeness like Hello-A link-Your past actions precisely described
Check my extensions : more than 30 available
who I am and what I do : http://fr.gravatar.com/flop25
My gallery : an illustration of how to integrate Piwigo in your website

Offline

 

#5 2014-01-11 15:36:47

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

Re: [resolved] [2.6.0 RC2] still not instalable

1- is it really useful ? I think nobody cares about the comment
but if you don't want to use this method here you MUST test is the parameter does not already exsists in the table

2- ok

3- check skeleton trunk :) (replace PluginMaintain by ThemeMaintain, and of course the method names, the interface is in functions_plugins.inc.php)

Offline

 

#6 2014-01-11 17:06:42

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

Re: [resolved] [2.6.0 RC2] still not instalable

great, no more errors

Offline

 
  •  » Beta testing
  •  » [resolved] [2.6.0 RC2] still not instalable

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2024 · Contact