Skip to content

Conversation

@PetrHeinz
Copy link
Member

Previously, host needed to include the https:// which is unintuitive:

from logtail import LogtailHandler
import logging

handler = LogtailHandler(
    source_token='$SOURCE_TOKEN', 
    host='https://in.logs.betterstack.com',
)
logger = logging.getLogger(__name__)
logger.setLevel(logging.INFO)
logger.handlers = []
logger.addHandler(handler)

Now, we should also support just ingesting host being sent, as noted in #31:

from logtail import LogtailHandler
import logging

handler = LogtailHandler(
    source_token='$SOURCE_TOKEN', 
    host='in.logs.betterstack.com',
)
logger = logging.getLogger(__name__)
logger.setLevel(logging.INFO)
logger.handlers = []
logger.addHandler(handler)

@PetrHeinz PetrHeinz requested a review from gyfis February 11, 2025 16:20
@PetrHeinz PetrHeinz merged commit 9f766e4 into master Feb 11, 2025
10 checks passed
@PetrHeinz PetrHeinz deleted the ph/fix-host-protocol branch February 11, 2025 16:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants