Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] More flexible and convenient logging #23712

Closed
wants to merge 26 commits into from
Closed

Commits on Oct 25, 2017

  1. Copy of MicroLogging source (656f937) exports + sysimg

    Some minor edits here to make things suitable for Base.
    c42f committed Oct 25, 2017
    Configuration menu
    Copy the full SHA
    283eb49 View commit details
    Browse the repository at this point in the history
  2. More backend interface renaming

    Use handle_message rather than dispatch_message, as not all message
    handling is pure dispatch (the message may be stored rather than sent
    elsewhere).
    
    Reuse the name dispatch_message internally.
    c42f committed Oct 25, 2017
    Configuration menu
    Copy the full SHA
    99e682c View commit details
    Browse the repository at this point in the history
  3. Convert Pkg to use new Logging

    c42f committed Oct 25, 2017
    Configuration menu
    Copy the full SHA
    9b7c697 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    d81e6d0 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    0bd2397 View commit details
    Browse the repository at this point in the history
  6. Migrate depwarn to new logging infrastructure

    * Forward depwarn() calls to new backend
    * Use caller frame pointer as message id.  This makes initial
      first-pass deduplication of depwarns quite a lot faster.
    * Change --depwarn=error to --depwarn=throw for clarity
    * Introduce defines for log levels into julia.h
    c42f committed Oct 25, 2017
    Configuration menu
    Copy the full SHA
    0b8a7fc View commit details
    Browse the repository at this point in the history
  7. Forward all frontend depwarns to the logging system

    Forward all frontend depwarn messages through to the julia logging
    system for consistency of formatting and dispatch.  Deciding whether a
    depwarn should appear as an thrown error is also now handled outside
    flisp to keep this decision in one place where possible.
    
    Detail:
    
    * Ensure that deprecation-message forwards to the logging system.  Also
      include file and line number metadata
    * Remove jl_parse_depwarn(), flisp *depwarn* and related scheme code as
      this can be handled on the julia side.
    * Rename syntax_deprecation_warnings(false) to
      without_syntax_deprecations, as this was only ever used to turn syntax
      deprecations off.
    * Ensure that all lowering depwarns with existing line number
      information get this passed through as accessible metadata rather than
      as a string.
    * Use distinct functions for depwarns coming from the parser vs
      lowering, as these get line number information in a different way.
    
    TODO:
    * Figure out a decent `id` for the syntax and lowering depwarn messages
    * Make without_syntax_deprecations filter only depwarn messages, rather
      than everything!
    c42f committed Oct 25, 2017
    Configuration menu
    Copy the full SHA
    b747fe5 View commit details
    Browse the repository at this point in the history
  8. Changes ported from MicroLogging

    * Additional exports
    * Fallback error message formatting
    * Minor global logger init min level bug
    c42f committed Oct 25, 2017
    Configuration menu
    Copy the full SHA
    0e52ef1 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    e7798ee View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    e062426 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    40f8697 View commit details
    Browse the repository at this point in the history

Commits on Oct 27, 2017

  1. Configuration menu
    Copy the full SHA
    9fd7e73 View commit details
    Browse the repository at this point in the history

Commits on Oct 30, 2017

  1. Configuration menu
    Copy the full SHA
    7bdf93c View commit details
    Browse the repository at this point in the history
  2. Move core Logging components into Base

    For now this seems like the right thing as error and informational
    reporting is a core requirement for a compiler - parts of the frontend
    and runtime now call the logging system when it's available.
    c42f committed Oct 30, 2017
    Configuration menu
    Copy the full SHA
    d0f143a View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    544c6b9 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    b674a36 View commit details
    Browse the repository at this point in the history

Commits on Nov 1, 2017

  1. Logging tools for use in the runtime C code

    These can be used to transform a lot of printf()'s into log statements.
    c42f committed Nov 1, 2017
    Configuration menu
    Copy the full SHA
    be777bc View commit details
    Browse the repository at this point in the history

Commits on Nov 2, 2017

  1. Add catch_exceptions(::AbstractLogger)

    This allows users to control whether a custom logger type will catch
    exceptions during message creation and log them, or simply allow them to
    pass through.
    c42f committed Nov 2, 2017
    Configuration menu
    Copy the full SHA
    7ed4de5 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    757c92c View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    58fb9e7 View commit details
    Browse the repository at this point in the history
  4. Implement general julia-logmsg function for flisp logging

    Provides a general tool to log information from the flisp frontend code.
    Make the syntax deprecations use this instead of using the purpose built
    syntax_depwarn function on the julia side.
    
    Also reinstate flisp-level awareness of the depwarn level.  It's just
    simpler.
    c42f committed Nov 2, 2017
    Configuration menu
    Copy the full SHA
    34bd483 View commit details
    Browse the repository at this point in the history
  5. Change log level limits to fit well within a flisp fixnum

    This is purely for implementation convenience.  It restricts the levels
    artifically, but it's hard to imagine what anyone would do with more than
    a million custom levels.
    c42f committed Nov 2, 2017
    Configuration menu
    Copy the full SHA
    a127e3f View commit details
    Browse the repository at this point in the history
  6. Remove all uses of --depwarn=error

    This can be handled in a much nicer way by installing a logger in-process.
    
    TODO: Define such a logger and test it!
    c42f committed Nov 2, 2017
    Configuration menu
    Copy the full SHA
    ee8bb6e View commit details
    Browse the repository at this point in the history

Commits on Nov 3, 2017

  1. Configuration menu
    Copy the full SHA
    483c771 View commit details
    Browse the repository at this point in the history

Commits on Nov 4, 2017

  1. Rearrange logging source into a more logical order

    Port from MicroLogging refactoring
    
    Also rearrange exports to avoid exporting AbstractLogger-related methods.
    c42f committed Nov 4, 2017
    Configuration menu
    Copy the full SHA
    bd6a3ae View commit details
    Browse the repository at this point in the history

Commits on Nov 5, 2017

  1. Configuration menu
    Copy the full SHA
    8319628 View commit details
    Browse the repository at this point in the history