Kong/insomnia · error · Error

Oops

Error message

Oops

What it means

Generic catch-all inside the response template tag's XPath branch: an unexpected exception escaped while selecting/reading XPath results, and no more specific error applies. Accompanies a failing XPath evaluation where the query itself looked valid.

Solutions

  1. Inspect the underlying cause by simplifying the XPath query step by step
  2. Verify the response body parses as XML
  3. Report/pinpoint the failing node type (attribute vs element vs text) extraction
Defensive patterns

Strategy: try-catch

When it happens

Trigger: Thrown at packages/insomnia/src/common/templating/local-template-tags.ts:793 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of Kong/insomnia@d9bb2b0142 (2026-08-26). Data as JSON: /api/errors/d79d09a16081030e. Report an issue: GitHub.

Appendix: source

Thrown at packages/insomnia/src/common/templating/local-template-tags.ts:793

                  if (selectedValue.nodeType === Node.TEXT_NODE) {
                    return { outer, inner: selectedValue.toString().trim() };
                  }
                  return { outer, inner: null };
                });
            }

            if (results.length === 0) {
              throw new Error(`Returned no results: ${sanitizedFilter}`);
            } else if (results.length > 1) {
              throw new Error(`Returned more than one result: ${sanitizedFilter}`);
            }

            return results[0].inner;
          } catch {
            throw new Error(`Invalid XPath query: ${sanitizedFilter}`);
          }
        }
        throw new Error('Oops');
      },
    },
  },
  {
    templateTag: {
      name: 'request',
      displayName: 'Request',
      description: 'reference value from current request',
      args: [
        {
          displayName: 'Attribute',
          type: 'enum',
          options: [
            {
              displayName: 'Name',
              value: 'name',
              description: 'name of request',
            },

View on GitHub (pinned to d9bb2b0142)