- 
                Notifications
    You must be signed in to change notification settings 
- Fork 758
Logging API accepts optional Context at LogRecord init else get_current; deprecates trace_id, span_id, trace_flags #4597
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
          
     Merged
      
      
            xrmx
  merged 28 commits into
  open-telemetry:main
from
tammy-baylis-swi:logs-api-accept-otel-context
  
      
      
   
  Jun 17, 2025 
      
    
  
     Merged
                    Changes from all commits
      Commits
    
    
            Show all changes
          
          
            28 commits
          
        
        Select commit
          Hold shift + click to select a range
      
      816ce49
              
                Logs API/SDK accepts additional otel context
              
              
                tammy-baylis-swi 4783932
              
                Changelog
              
              
                tammy-baylis-swi 5308eee
              
                LoggingHandler translates to LogRecord with current Otel context
              
              
                tammy-baylis-swi a45694c
              
                Add LogRecord init priority for context's span over old span info
              
              
                tammy-baylis-swi f8c56d3
              
                Add LogRecord serialized_context for to_json of arbitrary objects
              
              
                tammy-baylis-swi fa5ec39
              
                Add test coverage
              
              
                tammy-baylis-swi 56172fa
              
                Changelog
              
              
                tammy-baylis-swi 4b38118
              
                lint
              
              
                tammy-baylis-swi ded31f6
              
                Fix tests
              
              
                tammy-baylis-swi bce5a7e
              
                Changelog
              
              
                tammy-baylis-swi 9ff670e
              
                Merge branch 'main' into logs-api-accept-otel-context
              
              
                tammy-baylis-swi 73e7b39
              
                Rm Context inclusion from to_json of LogRecord
              
              
                tammy-baylis-swi 676d9ff
              
                Revision: logs SDK does get_current, overload init and deprecate trac…
              
              
                tammy-baylis-swi a0c817c
              
                Simplify test
              
              
                tammy-baylis-swi 111d8d8
              
                Changelog
              
              
                tammy-baylis-swi bb92b7e
              
                Use typing_extensions deprecated, not custom
              
              
                tammy-baylis-swi 0aad430
              
                Merge branch 'main' into logs-api-accept-otel-context
              
              
                emdneto 172f1c5
              
                Update LogRecord API; simplify test
              
              
                tammy-baylis-swi 84c6b33
              
                Force logrecord api kwarg-only to avoid param order issues
              
              
                tammy-baylis-swi eb28a8d
              
                Add special LogDeprecatedInitWarning that logs once
              
              
                tammy-baylis-swi c4c6aac
              
                Merge branch 'main' into logs-api-accept-otel-context
              
              
                tammy-baylis-swi 04f5da7
              
                Rm deprecated decorator
              
              
                tammy-baylis-swi dca0d41
              
                api too
              
              
                tammy-baylis-swi 52a5e93
              
                catch_warnings instead of assertLogs in test
              
              
                tammy-baylis-swi 069c2f8
              
                changelog
              
              
                tammy-baylis-swi fa6111e
              
                Rm with assertLogs for py3.13 ubuntu test
              
              
                tammy-baylis-swi f709952
              
                Merge branch 'main' into logs-api-accept-otel-context
              
              
                tammy-baylis-swi 87b300c
              
                Merge branch 'main' into logs-api-accept-otel-context
              
              
                emdneto File filter
Filter by extension
Conversations
          Failed to load comments.   
        
        
          
      Loading
        
  Jump to
        
          Jump to file
        
      
      
          Failed to load files.   
        
        
          
      Loading
        
  Diff view
Diff view
There are no files selected for viewing
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  Add this suggestion to a batch that can be applied as a single commit.
  This suggestion is invalid because no changes were made to the code.
  Suggestions cannot be applied while the pull request is closed.
  Suggestions cannot be applied while viewing a subset of changes.
  Only one suggestion per line can be applied in a batch.
  Add this suggestion to a batch that can be applied as a single commit.
  Applying suggestions on deleted lines is not supported.
  You must change the existing code in this line in order to create a valid suggestion.
  Outdated suggestions cannot be applied.
  This suggestion has been applied or marked resolved.
  Suggestions cannot be applied from pending reviews.
  Suggestions cannot be applied on multi-line comments.
  Suggestions cannot be applied while the pull request is queued to merge.
  Suggestion cannot be applied right now. Please check back later.
  
    
  
    
Uh oh!
There was an error while loading. Please reload this page.