Moodle

Portfolio Box.net: "A required parameter (sesskey) was missing"

Details

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

Description

1. I enabled portfolio
2. I added box.net with API key and updated box.net with the suggested callbackurl (http://jerome.moodle.local:8888/Moodle_HEAD/moodle/portfolio/add.php?postcontrol=1)
3. I went into an empty course
4. I created a discussion
5. I read the discussion
6. I clicked on save => the boxnet login page is displayed
7. I logged into box.net => boxnet returned to this url : http://jerome.moodle.local:8888/Moodle_HEAD/moodle/portfolio/add.php?postcontrol=1&ticket=v3s2jm4302uo6zj725a1cvkbk2d4xdms&auth_token=fdrcpq949mzgcy92oh69tcz2fgz095td

On this page I've got the following error message: "A required parameter (sesskey) was missing"

Issue Links

Activity

Hide
Penny Leach added a comment -

Can you confirm that it works if you change the callback url in box.net to

wwwroot/portfolio/add.php?postcontrol=1&type=boxnet

It may just be that the docs need updating

Show
Penny Leach added a comment - Can you confirm that it works if you change the callback url in box.net to wwwroot/portfolio/add.php?postcontrol=1&type=boxnet It may just be that the docs need updating
Hide
Jerome Mouneyrac added a comment -

Now in the forum post I see:
Only a single portfolio plugin instance is available, it doesn't support multiple exports per session, and there's already an active export in the session using this plugin!

  • line 252 of /lib/portfoliolib.php: call to debugging()
  • line 192 of /lib/portfoliolib.php: call to portfolio_add_button->to_html()
  • line 186 of /mod/forum/discuss.php: call to portfolio_add_button->render()

Only a single portfolio plugin instance is available, it doesn't support multiple exports per session, and there's already an active export in the session using this plugin!

  • line 252 of /lib/portfoliolib.php: call to debugging()
  • line 3514 of /mod/forum/lib.php: call to portfolio_add_button->to_html()
  • line 5853 of /mod/forum/lib.php: call to forum_print_post()
  • line 264 of /mod/forum/discuss.php: call to forum_print_discussion()

Then I deleted the Box.net plugin and re-added it and the message disappeared. (I think it was a problem cause by the recent fix you committed so it's probably not a real bug)

However after box.net redirect to Moodle I see:

Error reading from database

More information about this error
Debug info: Unknown column 'type' in 'where clause'<br /><br />SELECT id FROM mdl_portfolio_tempdata WHERE type = ? AND userid = ?<br />[array ( 0 => 'boxnet', 1 => '2', )]
Stack trace:

  • line 372 of /lib/dml/moodle_database.php: dml_read_exception thrown
  • line 656 of /lib/dml/mysqli_native_moodle_database.php: call to moodle_database->query_end()
  • line 1209 of /lib/dml/moodle_database.php: call to mysqli_native_moodle_database->get_records_sql()
  • line 1284 of /lib/dml/moodle_database.php: call to moodle_database->get_record_sql()
  • line 1263 of /lib/dml/moodle_database.php: call to moodle_database->get_field_sql()
  • line 1242 of /lib/dml/moodle_database.php: call to moodle_database->get_field_select()
  • line 62 of /portfolio/add.php: call to moodle_database->get_field()

I'll retest the plugin when you finish, np

Show
Jerome Mouneyrac added a comment - Now in the forum post I see: Only a single portfolio plugin instance is available, it doesn't support multiple exports per session, and there's already an active export in the session using this plugin!
  • line 252 of /lib/portfoliolib.php: call to debugging()
  • line 192 of /lib/portfoliolib.php: call to portfolio_add_button->to_html()
  • line 186 of /mod/forum/discuss.php: call to portfolio_add_button->render()
Only a single portfolio plugin instance is available, it doesn't support multiple exports per session, and there's already an active export in the session using this plugin!
  • line 252 of /lib/portfoliolib.php: call to debugging()
  • line 3514 of /mod/forum/lib.php: call to portfolio_add_button->to_html()
  • line 5853 of /mod/forum/lib.php: call to forum_print_post()
  • line 264 of /mod/forum/discuss.php: call to forum_print_discussion()
Then I deleted the Box.net plugin and re-added it and the message disappeared. (I think it was a problem cause by the recent fix you committed so it's probably not a real bug) However after box.net redirect to Moodle I see: Error reading from database More information about this error Debug info: Unknown column 'type' in 'where clause'<br /><br />SELECT id FROM mdl_portfolio_tempdata WHERE type = ? AND userid = ?<br />[array ( 0 => 'boxnet', 1 => '2', )] Stack trace:
  • line 372 of /lib/dml/moodle_database.php: dml_read_exception thrown
  • line 656 of /lib/dml/mysqli_native_moodle_database.php: call to moodle_database->query_end()
  • line 1209 of /lib/dml/moodle_database.php: call to mysqli_native_moodle_database->get_records_sql()
  • line 1284 of /lib/dml/moodle_database.php: call to moodle_database->get_record_sql()
  • line 1263 of /lib/dml/moodle_database.php: call to moodle_database->get_field_sql()
  • line 1242 of /lib/dml/moodle_database.php: call to moodle_database->get_field_select()
  • line 62 of /portfolio/add.php: call to moodle_database->get_field()
I'll retest the plugin when you finish, np
Hide
Penny Leach added a comment -

I fixed the sql error now and committed it.

The other debugging message refers to this: (pasting from chat):

08:04 <penny> i updated portfolio so we can have multiple exports in the same session
08:04 <penny> but some plugins can't support that
08:04 <penny> box.net is one of htem
08:04 <penny> the reason is that it doesn't support dynamically constructing the return url to
moodle
08:04 <penny> to pass &id= for example
08:04 <penny> so we can only have one boxnet export per session
08:05 <penny> you can have boxnet and mahara at the same time though, for example
08:05 <penny> just not boxnet and boxnet

See MDL-19356 for more info

Show
Penny Leach added a comment - I fixed the sql error now and committed it. The other debugging message refers to this: (pasting from chat): 08:04 <penny> i updated portfolio so we can have multiple exports in the same session 08:04 <penny> but some plugins can't support that 08:04 <penny> box.net is one of htem 08:04 <penny> the reason is that it doesn't support dynamically constructing the return url to moodle 08:04 <penny> to pass &id= for example 08:04 <penny> so we can only have one boxnet export per session 08:05 <penny> you can have boxnet and mahara at the same time though, for example 08:05 <penny> just not boxnet and boxnet See MDL-19356 for more info
Hide
Jerome Mouneyrac added a comment -

fixed, thanks Penny

Show
Jerome Mouneyrac added a comment - fixed, thanks Penny
Hide
Penny Leach added a comment -

docs fixed now too

Show
Penny Leach added a comment - docs fixed now too

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: