7d364da950
Refactor: update examples to utilize new address paradigm with wildcard support
...
- Introduced `get_wildcard_address` function for explicit wildcard binding.
- Updated examples to use `get_available_interfaces` and `get_optimal_binding_address` for address selection.
- Ensured consistent usage of the new address paradigm across all example files.
- Added tests to verify the implementation of the new address paradigm and wildcard feature.
2025-09-09 12:10:28 +05:30
030deb42b4
refactor: update examples to use available interfaces for listening addresses and improve logging configuration
2025-09-05 20:05:10 +05:30
c5a8f26490
Merge branch 'main' into fix/885-Update-default-Bind-address
2025-09-04 14:17:35 +05:30
87550113a4
chore: Update network address config to use loopback (127.0.0.1) instead of wildcard (0.0.0.0) across multiple examples and utilities.
2025-09-02 03:00:18 +05:30
145727a9ba
Refactor logging code: Remove unnecessary blank lines in logging setup and cleanup functions for improved readability. Update tests to reflect formatting changes.
2025-09-02 01:39:24 +05:30
84c1a7031a
Enhance logging cleanup: Introduce global handler management for proper resource cleanup on exit and during logging setup. Update tests to ensure file handlers are closed correctly across platforms.
2025-09-02 01:23:12 +05:30
64ccce17eb
fix(app): 882 Comprehensive cross-platform path handling utilities
2025-09-01 02:03:51 +05:30
6a24b138dd
feat: Add cross-platform path utilities module
2025-09-01 01:35:32 +05:30
63a8458d45
add import to __init__
2025-08-24 23:40:05 +05:30
ed91ee0c31
refactor(app): 804 refactored find_free_port() in address_validation.py
2025-08-24 23:28:02 +05:30
75ffb791ac
fix: Ensure newline at end of file in address_validation.py and update news fragment formatting
2025-08-24 22:06:07 +05:30
88a1f0a390
cherry pick 7a1198c8c6/libp2p/utils/address_validation.py
2025-08-24 21:17:29 +05:30
ed2716c1bf
feat: Enhance echo example to dynamically find free ports and improve address handling
...
- Added a function to find a free port on localhost.
- Updated the run function to use the new port finding logic when a non-positive port is provided.
- Modified address printing to handle multiple listen addresses correctly.
- Improved the get_available_interfaces function to ensure the IPv4 loopback address is included.
2025-08-22 11:48:37 +05:30
a1b16248d3
fix: correct listening address variable in echo example and streamline address printing
2025-08-19 20:47:18 +05:30
7f6469d5d4
Merge remote-tracking branch 'acul71/feat/804-add-thin-waist-address' into feat/804-add-thin-waist-address
2025-08-19 19:56:20 +05:30
05b372b1eb
Fix linting and type checking issues for Thin Waist feature
2025-08-19 01:11:48 +02:00
9378490dcb
fix: ensure loopback addresses are included in available interfaces
2025-08-18 12:40:38 +05:30
fa174230ba
Refactor echo example to use optimal binding address
...
- Replaced hardcoded listen address with `get_optimal_binding_address` for improved flexibility.
- Imported address validation utilities in `echo.py` and updated `__init__.py` to include new functions.
2025-08-09 01:22:17 +05:30
b840eaa7e1
Implement advanced network discovery example and address validation utilities
...
- Added `network_discover.py` to demonstrate Thin Waist address handling.
- Introduced `address_validation.py` with functions for discovering available network interfaces, expanding wildcard addresses, and determining optimal binding addresses.
- Included fallback mechanisms for environments lacking Thin Waist support.
2025-08-09 01:22:03 +05:30
37e4fee9f8
feat: Add identify-push raw format support and yamux logging improvements
...
- Add comprehensive integration tests for identify-push protocol
- Support both raw protobuf and varint message formats
- Improve yamux logging integration with LIBP2P_DEBUG
- Fix RawConnError handling to reduce log noise
- Add Ctrl+C handling to identify examples
- Enhance identify-push listener/dialer demo
Fixes : #784
2025-07-20 20:19:18 +02:00
4bd24621f0
Merge branch 'main' into identify-fix-varint-go
2025-07-16 10:10:24 -07:00
8ec67289da
feat: add length-prefixed protobuf support to identify protocol
2025-07-13 15:55:37 +02:00
b81168dae9
improve error message
2025-07-13 17:52:05 +05:30
bdadec7519
ft. modernise py-libp2p ( #618 )
...
* fix pyproject.toml , add ruff
* rm lock
* make progress
* add poetry lock ignore
* fix type issues
* fix tcp type errors
* fix text example - type error - wrong args
* add setuptools to dev
* test ci
* fix docs build
* fix type issues for new_swarm & new_host
* fix types in gossipsub
* fix type issues in noise
* wip: factories
* revert factories
* fix more type issues
* more type fixes
* fix: add null checks for noise protocol initialization and key handling
* corrected argument-errors in peerId and Multiaddr in peer tests
* fix: Noice - remove redundant type casts in BaseNoiseMsgReadWriter
* fix: update test_notify.py to use SwarmFactory.create_batch_and_listen, fix type hints, and comment out ClosedStream assertions
* Fix type checks for pubsub module
Signed-off-by: sukhman <sukhmansinghsaluja@gmail.com >
* Fix type checks for pubsub module-tests
Signed-off-by: sukhman <sukhmansinghsaluja@gmail.com >
* noise: add checks for uninitialized protocol and key states in PatternXX
Signed-off-by: varun-r-mallya <varunrmallya@gmail.com >
* pubsub: add None checks for optional fields in FloodSub and Pubsub
Signed-off-by: varun-r-mallya <varunrmallya@gmail.com >
* Fix type hints and improve testing
Signed-off-by: varun-r-mallya <varunrmallya@gmail.com >
* remove redundant checks
Signed-off-by: varun-r-mallya <varunrmallya@gmail.com >
* fix build issues
* add optional to trio service
* fix types
* fix type errors
* Fix type errors
Signed-off-by: varun-r-mallya <varunrmallya@gmail.com >
* fixed more-type checks in crypto and peer_data files
* wip: factories
* replaced union with optional
* fix: type-error in interp-utils and peerinfo
* replace pyright with pyrefly
* add pyrefly.toml
* wip: fix multiselect issues
* try typecheck
* base check
* mcache test fixes , typecheck ci update
* fix ci
* will this work
* minor fix
* use poetry
* fix wokflow
* use cache,fix err
* fix pyrefly.toml
* fix pyrefly.toml
* fix cache in ci
* deploy commit
* add main baseline
* update to v5
* improve typecheck ci (#14 )
* fix typo
* remove holepunching code (#16 )
* fix gossipsub typeerrors (#17 )
* fix: ensure initiator user includes remote peer id in handshake (#15 )
* fix ci (#19 )
* typefix: custom_types | core/peerinfo/test_peer_info | io/abc | pubsub/floodsub | protocol_muxer/multiselect (#18 )
* fix: Typefixes in PeerInfo (#21 )
* fix minor type issue (#22 )
* fix type errors in pubsub (#24 )
* fix: Minor typefixes in tests (#23 )
* Fix failing tests for type-fixed test/pubsub (#8 )
* move pyrefly & ruff to pyproject.toml & rm .project-template (#28 )
* move the async_context file to tests/core
* move crypto test to crypto folder
* fix: some typefixes (#25 )
* fix type errors
* fix type issues
* fix: update gRPC API usage in autonat_pb2_grpc.py (#31 )
* md: typecheck ci
* rm comments
* clean up : from review suggestions
* use | None over Optional as per new python standards
* drop supporto for py3.9
* newsfragments
---------
Signed-off-by: sukhman <sukhmansinghsaluja@gmail.com >
Signed-off-by: varun-r-mallya <varunrmallya@gmail.com >
Co-authored-by: acul71 <luca.pisani@birdo.net >
Co-authored-by: kaneki003 <sakshamchauhan707@gmail.com >
Co-authored-by: sukhman <sukhmansinghsaluja@gmail.com >
Co-authored-by: varun-r-mallya <varunrmallya@gmail.com >
Co-authored-by: varunrmallya <100590632+varun-r-mallya@users.noreply.github.com >
Co-authored-by: lla-dane <abhinavagarwalla6@gmail.com >
Co-authored-by: Collins <ArtemisfowlX@protonmail.com >
Co-authored-by: Abhinav Agarwalla <120122716+lla-dane@users.noreply.github.com >
Co-authored-by: guha-rahul <52607971+guha-rahul@users.noreply.github.com >
Co-authored-by: Sukhman Singh <63765293+sukhman-sukh@users.noreply.github.com >
Co-authored-by: acul71 <34693171+acul71@users.noreply.github.com >
Co-authored-by: pacrob <5199899+pacrob@users.noreply.github.com >
2025-06-09 11:39:59 -06:00
18c6f529c6
Feat/issue 605 debug logging via env variable ( #608 )
...
* feat: Debug Logging via Environment Variable
* refactor: deleted libp2p/utils.py
* fix: double messages logging fix
* doc: add logging info to getting_started.rst
2025-05-20 14:07:22 -06:00