#920 mod_storage_internal archive does not behave like other modules when querying an empty archive

Reporter Link Mauve
Owner Zash
Created
Updated
Stars ★ (1)  
Tags
  • Priority-Medium
  • Status-Fixed
  • Type-Defect
  • Milestone-0.10
  1. Link Mauve on

    What steps will reproduce the problem? 1. Don’t have any message in your MAM archive. 2. Query the MAM archive. What is the expected output? What do you see instead? An empty <fin/> element, with a <set/> of count 0. Instead I see an <internal-server-error/> error. What version of the product are you using? On what operating system? Trunk 4720f5ec4171 on Lua 5.2 on ArchLinux. Please provide any additional information below. mod_mam.lua line 146 is the issue, it should check whether the error is that nothing has been logged.

  2. Zash on

    Indeed. It could be argued that it is the internal storage driver behaving unlike others, which would return a noop iterator in this case.

    Changes
    • tags Milestone-0.10 Status-Accepted
    • owner Zash
  3. Zash on

    Fixed in https://hg.prosody.im/0.10/rev/3ff99d49082f Thanks!

    Changes
    • title Don’t consider an empty MAM archive as an internal-server-error mod_storage_internal archive does not behave like other modules when querying an empty archive
    • tags Status-Fixed

New comment