Skip to content
Snippets Groups Projects

Fix ImageFileReader error message & add back otb::Logger::BuildFormattedEntry

Merged Victor Poughon requested to merge 1850-imagefilereader into develop

Summary

  • Fix unclear error message in ImageFileReader (see discussion in #1850 (closed))
  • Add back otb::Logger::BuildFormattedEntry override (removed in !379 (merged))

Rationale

  • Fix issue #1850 (closed)
  • Better format for log entries (no redundant spaces and don't show logger name)

Copyright

The copyright owner is CNES and has signed the ORFEO ToolBox Contributor License Agreement.


Check before merging:

  • All discussions are resolved
  • At least 2 :thumbsup: votes from core developers, no :thumbsdown: vote.
  • The feature branch is (reasonably) up-to-date with the base branch
  • Dashboard is green
  • Copyright owner has signed the ORFEO ToolBox Contributor License Agreement

Merge request reports

Merge request pipeline #351 passed

Merge request pipeline passed for 412cb686

Merged by Victor PoughonVictor Poughon 6 years ago (Mar 7, 2019 9:38am UTC)

Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Luc Hermitte
  • Luc Hermitte
  • Luc Hermitte
  • First thing first why did you add otb::Logger::BuildFormattedEntry which is really nice but is a perfect copy past from itk::LoggerBase (except for the assert)?

  • Author Contributor

    It's not the same at all :) Small differences like removing extra spaces and not showing the logger name. I introduced it 2 years ago back when I did the work on improving error message. But yes I copy pasted from the ITK one so I understand your confusion. With the code review from Luc also I just pushed a commit that simplifies it a lot (since we are always in the HUMANREADABLE mode). It should be more clear now.

  • Victor Poughon added 1 commit

    added 1 commit

    • d6cb4b11 - REFAC: refactor otb::Logger::BuildFormattedEntry

    Compare with previous version

  • Victor Poughon resolved all discussions

    resolved all discussions

  • But we need the logger name, don't we? With wrapping of the logger in python coming I think user will be glad to know which application is saying what, right?

  • Other than this matter this looks good!

  • Author Contributor

    Yes good point. I will add back the application name.

  • Victor Poughon resolved all discussions

    resolved all discussions

  • Victor Poughon added 1 commit

    added 1 commit

    • 412cb686 - REFAC: display logger name in log

    Compare with previous version

  • Author Contributor

    ok done! You can see what it looks like here: https://gitlab.orfeo-toolbox.org/snippets/128

  • Great! Those snippets are quiet cool to show the improvements.

  • Victor Poughon mentioned in merge request !405 (merged)

    mentioned in merge request !405 (merged)

  • Author Contributor

    needs votes :)

  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading