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

ISE when doing non-implemented API call with 'text/plain'

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • None
    • Web service
    • None

      We now have TXTSerializer for the genre list, but when users try to request something else as text/plain, we ISE since we're missing a method to error gracefully (see example below).

      Sentry Issue: MUSICBRAINZ-SERVER-1C3

      None: Can't locate object method "output_error" via package "MusicBrainz::Server::WebService::TXTSerializer" at lib/MusicBrainz/Server/ControllerBase/WS/2.pm line 111, <PKGFILE> line 1.
        File "2.pm", line 111, in Catalyst::detach
          $c->res->body($c->stash->{serializer}->output_error(q(This hasn't been implemented yet.)));
        File "Genre.pm", line 85, in Catalyst::dispatch
          $c->detach('not_implemented');
        File "Server.pm", line 388, in MusicBrainz::Server::__ANON__
          $c->$orig(@args)
        File "Server.pm", line 353, in MusicBrainz::Server::with_translations
          $code->();
        File "Server.pm", line 389, in Class::MOP::Method::Wrapped::__ANON__
          });
      ...
      (2 additional frame(s) were not displayed)
      

            reosarevok Nicolás Tamargo
            dev-sentry Dev through Sentry
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                Version Package