Skip to content

Better diagnostics for easily detectable developer errors in QueryUrisLoader #161

@ahwitz

Description

@ahwitz

Hey! At this point in QueryUrisLoader, there's a try/catch that prints additional diagnostics for when the first item returned isn't an integer. There were two other cases where I got an empty NullPointerException with no diagnostics that should be pretty easy to detect:

  • No array is returned by getUris
  • A JS array (without a wrapping xdmp.arrayValues call) is returned by the module

Only asking because there's already developer error diagnostics there, and I had to dig back into the code from the stack trace to figure out what might be going wrong. Would it be possible/worthwhile to add two more NullPointer catches there to help out future developers who run into similar mistakes?

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions