Skip to content

Conversation

@Antrikshgwal
Copy link
Contributor

@Antrikshgwal Antrikshgwal commented Oct 27, 2025

What was wrong?

The current py-libp2p implementation uses hardcoded TTL (Time To Live) values throughout the codebase. This PR(WIP) implements a configurable TTL system across Identify, PubSub, DHT, Host modules, following golibp2p's approach.

Implements discussion #967

How was it fixed?

As the discussed in #967, this PR focuses on phase 1 and 2 of the implementation roadmap.

Phase 1: Core Infrastructure

  • Create TTLConfig dataclass

  • Add configuration validation

  • Create default TTL values based on Go libp2p

Phase 2: Component Updates

  • Update IdentifyPush to use configurable TTL

  • Update PubSub utilities

  • Update DHT utilities

  • Update Host class to accept TTL config

To-Do

  • Clean up commit history
  • Add or update documentation related to these changes
  • Add entry to the release notes

Cute Animal Picture

image

@Antrikshgwal Antrikshgwal marked this pull request as draft October 28, 2025 18:20
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.

1 participant