Moodle

Upgrading 2.0 to 2008091611 get mnet related error

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Minor Minor
  • Resolution: Fixed
  • Affects Version/s: 2.0
  • Fix Version/s: 2.0
  • Component/s: MNet
  • Labels:
    None
  • Affected Branches:
    MOODLE_20_STABLE
  • Fixed Branches:
    MOODLE_20_STABLE

Description

While upgrading to current CVS, in the process I got:

Incorrect integer value: '' for column 'public_key_expires' at row 1

INSERT INTO mdl_mnet_host (wwwroot,ip_address,public_key,public_key_expires,last_connect_time,last_log_id,deleted,name) VALUES(?,?,?,?,?,?,?,?)
[array ( 'wwwroot' => '', 'ip_address' => '', 'public_key' => '', 'public_key_expires' => '', 'last_connect_time' => '0', 'last_log_id' => '0', 'deleted' => 0, 'name' => 'All Hosts', )]

  • line 253 of lib/dml/moodle_database.php: call to debugging()
  • line 272 of lib/dml/adodb_moodle_database.php: call to moodle_database->report_error()
  • line 178 of lib/dml/mysqli_adodb_moodle_database.php: call to adodb_moodle_database->insert_record_raw()
  • line 88 of mnet/environment.php: call to mysqli_adodb_moodle_database->insert_record()
  • line 25 of mnet/lib.php: call to mnet_environment->init()
  • line 9 of portfolio/type/mahara/lib.php: call to require_once()
  • line 628 of lib/portfoliolib.php: call to require_once()
  • line 43 of admin/mnet/adminlib.php: call to portfolio_static_function()
  • line 191 of admin/mnet/adminlib.php: call to mnet_get_functions()
  • line 387 of lib/adminlib.php: call to upgrade_RPC_functions()
  • line 76 of admin/index.php: call to upgrade_db()

Ciao

Issue Links

Activity

Hide
Eloy Lafuente (stronk7) added a comment -

Assigning this to Peter Bulmer... am I correct, Peter?

Show
Eloy Lafuente (stronk7) added a comment - Assigning this to Peter Bulmer... am I correct, Peter?
Hide
Eloy Lafuente (stronk7) added a comment -

Peter, I've changed some defaults of the "All hosts" record to be proper zeros. (suggested by Penny). I hope it's ok, now the record is being properly inserted.

One thing that doesn't look "fine", anyway, is that... simply by requiring mnet/lib.php, the mnet_environment->init() is executed (code in global scope). Cannot this be improved? I guess it's to guarantee things to be properly initialised on install/upgrade... if so... I think one method mnet_upgrade() could do the job (and add it to adminlib, instead of automatically launching it by the require_once.

For your consideration... ciao

Show
Eloy Lafuente (stronk7) added a comment - Peter, I've changed some defaults of the "All hosts" record to be proper zeros. (suggested by Penny). I hope it's ok, now the record is being properly inserted. One thing that doesn't look "fine", anyway, is that... simply by requiring mnet/lib.php, the mnet_environment->init() is executed (code in global scope). Cannot this be improved? I guess it's to guarantee things to be properly initialised on install/upgrade... if so... I think one method mnet_upgrade() could do the job (and add it to adminlib, instead of automatically launching it by the require_once. For your consideration... ciao
Hide
Peter Bulmer added a comment -

"I've changed some defaults of the "All hosts" record to be proper zeros. (suggested by Penny). I hope it's ok, now the record is being properly inserted."
That sounds great. I am a little surprised that this bug didn't present more agressively (I haven't suffered at its hands).

re: $MNET->init();
Totally agree with you.

Show
Peter Bulmer added a comment - "I've changed some defaults of the "All hosts" record to be proper zeros. (suggested by Penny). I hope it's ok, now the record is being properly inserted." That sounds great. I am a little surprised that this bug didn't present more agressively (I haven't suffered at its hands). re: $MNET->init(); Totally agree with you.
Hide
Penny Leach added a comment -

closing, and i've linked a separate bug about mnet->init

Show
Penny Leach added a comment - closing, and i've linked a separate bug about mnet->init

People

Dates

  • Created:
    Updated:
    Resolved: