Uploaded image for project: 'MusicBrainz Server'
  1. MusicBrainz Server
  2. MBS-8430

SQL exception when undoing creation of a record label: "Controller::Edit->cancel "Failed query: ..." "

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2015-06-29
    • Component/s: Edit system
    • Labels:
      None

      Description

      Recently I created a record label because I couldn't find an exact match for their name, "20/20 vision". Afterwards I looked at a label with a very-similar name, "2020vision", which turns out to be the label I was looking for (links to official pages match up). I have undone all edits involving the label except for one, its creation. When I try to undo the final edit I cause SQL exception:

      33446891 = https://musicbrainz.org/edit/33446891
      (raw edit data) = https://musicbrainz.org/edit/33446891/data

      ----------------------------------------------------------------------------------------------------

      Caught exception in MusicBrainz::Server::Controller::Edit->cancel "Failed query:
      'UPDATE edit SET status = ?, close_time = NOW() WHERE id = ?'
      (5 33446891)
      25P02 DBD::Pg::st execute failed: ERROR: current transaction is aborted, commands ignored until end of transaction block at lib/MusicBrainz/Server/Connector.pm line 42, line 3.

      at lib/Sql.pm line 113
      Sql::_ANON_('25P02 DBD::Pg::st execute failed: ERROR: current transaction...') called at /usr/share/perl5/Try/Tiny.pm line 100
      Try::Tiny::try('CODE(0x160f1740)', 'Try::Tiny::Catch=REF(0x16276768)') called at lib/Sql.pm line 114
      Sql::do('Sql=HASH(0x119e8d20)', 'UPDATE edit SET status = ?, close_time = NOW() WHERE id = ?', 5, 33446891) called at lib/MusicBrainz/Server/Data/Edit.pm line 777
      MusicBrainz::Server::Data::Edit::_close('MusicBrainz::Server::Data::Edit=HASH(0xdc632d8)', 'MusicBrainz::Server::Edit::Label::Create=HASH(0x160d99c0)', 'CODE(0x160f1620)') called at lib/MusicBrainz/Server/Data/Edit.pm line 763
      MusicBrainz::Server::Data::Edit::reject('MusicBrainz::Server::Data::Edit=HASH(0xdc632d8)', 'MusicBrainz::Server::Edit::Label::Create=HASH(0x160d99c0)', 9) called at lib/MusicBrainz/Server/Data/Edit.pm line 769
      MusicBrainz::Server::Data::Edit::cancel('MusicBrainz::Server::Data::Edit=HASH(0xdc632d8)', 'MusicBrainz::Server::Edit::Label::Create=HASH(0x160d99c0)') called at lib/MusicBrainz/Server/Controller/Edit.pm line 151
      MusicBrainz::Server::Controller::Edit::_ANON_() called at lib/Sql.pm line 317
      Sql::_ANON_() called at /usr/share/perl5/Try/Tiny.pm line 76
      eval

      {...} called at /usr/share/perl5/Try/Tiny.pm line 67
      Try::Tiny::try('CODE(0x160f1368)', 'Try::Tiny::Catch=REF(0x160f12c0)') called at lib/Sql.pm line 330
      Sql::_auto_transaction('CODE(0x161ecc50)', 'Sql=HASH(0x119e8d20)') called at lib/Sql.pm line 335
      Sql::_run_in_transaction_one('CODE(0x161ecc50)', 'Sql=HASH(0x119e8d20)') called at lib/Sql.pm line 349
      Sql::run_in_transaction('CODE(0x161ecc50)', 'Sql=HASH(0x119e8d20)') called at lib/MusicBrainz/Server/Model/MB.pm line 19
      MusicBrainz::Server::Model::MB::with_transaction('MusicBrainz::Server::Model::MB=HASH(0xd45bc88)', 'CODE(0x161ecc50)') called at lib/MusicBrainz/Server/Controller/Edit.pm line 162
      MusicBrainz::Server::Controller::Edit::cancel('MusicBrainz::Server::Controller::Edit=HASH(0xf1c9488)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/share/perl5/Catalyst/Action.pm line 65
      Catalyst::Action::execute('Catalyst::Action=HASH(0xf4c4ad8)', 'MusicBrainz::Server::Controller::Edit=HASH(0xf1c9488)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/share/perl5/Catalyst.pm line 1691
      eval {...}

      called at /usr/share/perl5/Catalyst.pm line 1691
      Catalyst::execute('MusicBrainz::Server=HASH(0x11fb9340)', 'MusicBrainz::Server::Controller::Edit', 'Catalyst::Action=HASH(0xf4c4ad8)') called at /usr/share/perl5/Catalyst/Plugin/StackTrace.pm line 94
      Catalyst::Plugin::StackTrace::execute('MusicBrainz::Server=HASH(0x11fb9340)', 'MusicBrainz::Server::Controller::Edit', 'Catalyst::Action=HASH(0xf4c4ad8)') called at /usr/share/perl5/Catalyst/Action.pm line 60
      Catalyst::Action::dispatch('Catalyst::Action=HASH(0xf4c4ad8)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/share/perl5/Catalyst/ActionChain.pm line 38
      Catalyst::ActionChain::dispatch('Catalyst::ActionChain=HASH(0x11f25658)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/share/perl5/Catalyst/Controller.pm line 125
      Catalyst::Controller::_ACTION('MusicBrainz::Server::Controller::Edit=HASH(0xf1c9488)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/share/perl5/Catalyst/Action.pm line 65
      Catalyst::Action::execute('Catalyst::Action=HASH(0xf4c0728)', 'MusicBrainz::Server::Controller::Edit=HASH(0xf1c9488)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/share/perl5/Catalyst.pm line 1691
      eval

      {...} called at /usr/share/perl5/Catalyst.pm line 1691
      Catalyst::execute('MusicBrainz::Server=HASH(0x11fb9340)', 'MusicBrainz::Server::Controller::Edit', 'Catalyst::Action=HASH(0xf4c0728)') called at /usr/share/perl5/Catalyst/Plugin/StackTrace.pm line 94
      Catalyst::Plugin::StackTrace::execute('MusicBrainz::Server=HASH(0x11fb9340)', 'MusicBrainz::Server::Controller::Edit', 'Catalyst::Action=HASH(0xf4c0728)') called at /usr/share/perl5/Catalyst/Action.pm line 60
      Catalyst::Action::dispatch('Catalyst::Action=HASH(0xf4c0728)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/share/perl5/Catalyst/Dispatcher.pm line 257
      Catalyst::Dispatcher::_do_forward('Catalyst::Dispatcher=HASH(0x4960ba8)', 'forward', 'MusicBrainz::Server=HASH(0x11fb9340)', '_ACTION') called at /usr/share/perl5/Catalyst/Dispatcher.pm line 237
      Catalyst::Dispatcher::forward('Catalyst::Dispatcher=HASH(0x4960ba8)', 'MusicBrainz::Server=HASH(0x11fb9340)', '_ACTION') called at /usr/share/perl5/Catalyst.pm line 358
      Catalyst::forward('MusicBrainz::Server=HASH(0x11fb9340)', '_ACTION') called at /usr/share/perl5/Catalyst/Controller.pm line 99
      Catalyst::Controller::_DISPATCH('MusicBrainz::Server::Controller::Edit=HASH(0xf1c9488)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/share/perl5/Catalyst/Action.pm line 65
      Catalyst::Action::execute('Catalyst::Action=HASH(0xf4bc9b0)', 'MusicBrainz::Server::Controller::Edit=HASH(0xf1c9488)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/share/perl5/Catalyst.pm line 1691
      eval {...}

      called at /usr/share/perl5/Catalyst.pm line 1691
      Catalyst::execute('MusicBrainz::Server=HASH(0x11fb9340)', 'MusicBrainz::Server::Controller::Edit', 'Catalyst::Action=HASH(0xf4bc9b0)') called at /usr/share/perl5/Catalyst/Plugin/StackTrace.pm line 94
      Catalyst::Plugin::StackTrace::execute('MusicBrainz::Server=HASH(0x11fb9340)', 'MusicBrainz::Server::Controller::Edit', 'Catalyst::Action=HASH(0xf4bc9b0)') called at /usr/share/perl5/Catalyst/Action.pm line 60
      Catalyst::Action::dispatch('Catalyst::Action=HASH(0xf4bc9b0)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/share/perl5/Catalyst/Dispatcher.pm line 257
      Catalyst::Dispatcher::_do_forward('Catalyst::Dispatcher=HASH(0x4960ba8)', 'forward', 'MusicBrainz::Server=HASH(0x11fb9340)', '/edit/_DISPATCH') called at /usr/share/perl5/Catalyst/Dispatcher.pm line 237
      Catalyst::Dispatcher::forward('Catalyst::Dispatcher=HASH(0x4960ba8)', 'MusicBrainz::Server=HASH(0x11fb9340)', '/edit/_DISPATCH') called at /usr/share/perl5/Catalyst.pm line 358
      Catalyst::forward('MusicBrainz::Server=HASH(0x11fb9340)', '/edit/_DISPATCH') called at /usr/share/perl5/Catalyst/Dispatcher.pm line 105
      Catalyst::Dispatcher::dispatch('Catalyst::Dispatcher=HASH(0x4960ba8)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/share/perl5/Catalyst.pm line 1637
      Catalyst::dispatch('MusicBrainz::Server=HASH(0x11fb9340)') called at lib/MusicBrainz/Server.pm line 333
      MusicBrainz::Server::_ANON_() called at lib/MusicBrainz/Server.pm line 307
      MusicBrainz::Server::with_translations('MusicBrainz::Server=HASH(0x11fb9340)', 'CODE(0x11f91ad8)') called at lib/MusicBrainz/Server.pm line 334
      Class::MOP::Class:::around('CODE(0x3d50418)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/lib/perl5/Class/MOP/Method/Wrapped.pm line 162
      Class::MOP::Method::Wrapped::_ANON_('MusicBrainz::Server=HASH(0x11fb9340)') called at lib/MusicBrainz/Server.pm line 348
      Class::MOP::Class:::around('CODE(0x4960a58)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/lib/perl5/Class/MOP/Method/Wrapped.pm line 162
      Class::MOP::Method::Wrapped::_ANON_('MusicBrainz::Server=HASH(0x11fb9340)') called at lib/MusicBrainz/Server.pm line 387
      Class::MOP::Class:::around('CODE(0xf7911c0)', 'MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/lib/perl5/Class/MOP/Method/Wrapped.pm line 162
      Class::MOP::Method::Wrapped::_ANON_('MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/lib/perl5/Class/MOP/Method/Wrapped.pm line 35
      Class::MOP::Method::Wrapped::_ANON_('MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/lib/perl5/Class/MOP/Method/Wrapped.pm line 91
      MusicBrainz::Server::dispatch('MusicBrainz::Server=HASH(0x11fb9340)') called at /usr/share/perl5/Catalyst.pm line 1987
      Catalyst::_ANON_() called at /usr/share/perl5/Try/Tiny.pm line 76
      eval

      {...}

      called at /usr/share/perl5/Try/Tiny.pm line 67
      Try::Tiny::try('CODE(0x11f9f440)', 'Try::Tiny::Catch=REF(0x11d19ee8)') called at /usr/share/perl5/Catalyst.pm line 1993
      Catalyst::handle_request('MusicBrainz::Server', 'env', 'HASH(0x11fdbec8)', 'response_cb', 'CODE(0x11e8c398)') called at /usr/share/perl5/Catalyst/Plugin/AutoRestart.pm line 117
      Catalyst::Plugin::AutoRestart::handle_request('MusicBrainz::Server', 'env', 'HASH(0x11fdbec8)', 'response_cb', 'CODE(0x11e8c398)') called at /usr/share/perl5/Catalyst/Engine.pm line 682
      Catalyst::Engine::_ANON_('CODE(0x11e8c398)') called at /usr/share/perl5/Starlet/Server.pm line 366
      Starlet::Server::handle_connection('Plack::Handler::Starlet=HASH(0xf221bd0)', 'HASH(0x11fdbec8)', 'IO::Socket::INET=GLOB(0x11e966b0)', 'CODE(0xf7cb4e0)', '', '', '') called at /usr/share/perl5/Starlet/Server.pm line 178
      Starlet::Server::accept_loop('Plack::Handler::Starlet=HASH(0xf221bd0)', 'CODE(0xf7cb4e0)', 156) called at /usr/share/perl5/Plack/Handler/Starlet.pm line 75
      Plack::Handler::Starlet::run('Plack::Handler::Starlet=HASH(0xf221bd0)', 'CODE(0xf7cb4e0)') called at /usr/share/perl5/Plack/Loader.pm line 88
      Plack::Loader::run('Plack::Loader=HASH(0x1f36288)', 'Plack::Handler::Starlet=HASH(0xf221bd0)') called at /usr/share/perl5/Plack/Runner.pm line 263
      Plack::Runner::run('Plack::Runner=HASH(0x1d39468)') called at /usr/bin/plackup line 10
      at lib/Sql.pm line 330"

      Stack trace:

      line 19 MusicBrainz::Server::Model::MB
      line 162 MusicBrainz::Server::Controller::Edit
      line 333 MusicBrainz::Server
      line 307 MusicBrainz::Server
      line 334 MusicBrainz::Server
      line 348 MusicBrainz::Server
      line 387 MusicBrainz::Server

      Request data:

      $VAR1 = {
      'query_parameters' =>

      { 'returnto' => 'https://musicbrainz.org/user/cosmicslice/edits/open?page=3' }

      ,
      'body_parameters' =>

      { 'confirm.edit_note' => 'Rolling back creation of duplicate record label, already exists as "2020vision".' }

      };

      Edits loaded for the page:

      33446891 (raw edit data); fully loaded

      Time: 2015-06-07 20:07:07 UTC

      Host: pingu

      URL: https://musicbrainz.org/edit/33446891/cancel?returnto=https%3A%2F%2Fmusicbrainz.org%2Fuser%2Fcosmicslice%2Fedits%2Fopen%3Fpage%3D3

      ----------------------------------------------------------------------------------------------------
      ----------------------------------------------------------------------------------------------------

      33446891 = https://musicbrainz.org/edit/33446891
      (raw edit data) = https://musicbrainz.org/edit/33446891/data

        Attachments

          Activity

            People

            Assignee:
            bitmap Michael Wiencek
            Reporter:
            cosmicslice Andrew Owenson
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Due:
              Created:
              Updated:
              Resolved:

                Packages

                Version Package
                2015-06-29