Skip to content

Conversation

SuchitraSwain
Copy link

@SuchitraSwain SuchitraSwain commented Sep 30, 2025

What was wrong?

Issue #944

How was it fixed?

Summary of approach.

To-Do

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

Cute Animal Picture

put a cute animal picture link inside the parentheses

mystical-prog and others added 19 commits June 29, 2025 23:22
🔧 **Core Fixes**
- Replace os.path.join() with join_paths() in docs/conf.py and test files
- Remove os.path.dirname() usage from libp2p/utils/paths.py
- Fix hard-coded Windows paths in test files
- Update test patterns to use proper cross-platform path handling

🚀 **CI/CD Enhancements**
- Add path audit to pre-commit hooks for early detection
- Create dedicated CI workflow (.github/workflows/path-audit.yml)
- Fail CI on high-priority path issues (P0/P1)
- Test across Python 3.10, 3.11, 3.12

📚 **Documentation Updates**
- Add comprehensive 'Cross-Platform Path Handling' section to contributing.rst
- Include best practices, examples, and migration guidelines
- Document audit script usage and requirements

📊 **Results**
- Reduced total path issues from 968 to 957
- Eliminated all P0 (high-priority) temp_hardcode issues
- Significantly reduced P1 (medium-priority) issues
- Established automated validation to prevent future issues

✅ **Benefits**
- Cross-platform compatibility across Windows, macOS, Linux
- Automated validation prevents regression
- Clear developer guidance and examples
- Centralized path utilities reduce inconsistencies

Fixes libp2p#944
@yashksaini-coder
Copy link
Contributor

@SuchitraSwain Currently fixing the pubusb test suite failure on this one.

@yashksaini-coder
Copy link
Contributor

@SuchitraSwain I've fixed the gossipsub failing test cases. The test suite does not have a proper pytest-trio implementation.

@seetadev
Copy link
Contributor

seetadev commented Oct 8, 2025

@yashksaini-coder : Appreciate the efforts. Re-run the CI/CD pipeline. Lets try and have a proper pytest-trio implementation here. I also realize that there are couple of other important test cases that need to be addressed here too.

CCing @acul71 for his feedback and pointers too.

Hi Luca: we might have to address important test case scenarios before we head towards final review on this PR. Would like you to collaborate here. @yashksaini-coder did fix gossipsub and pubsub CI/CD issues recently too.

@sumanjeet0012
Copy link
Contributor

@yashksaini-coder The PR is progressing well. I just wanted to highlight that some commits related to flood publishing (e.g., this commit) are included in this PR. Could you please rebase the PR on the latest main branch and fix the CI/CD issues?

@yashksaini-coder
Copy link
Contributor

@yashksaini-coder The PR is progressing well. I just wanted to highlight that some commits related to flood publishing (e.g., this commit) are included in this PR. Could you please rebase the PR on the latest main branch and fix the CI/CD issues?

Yes I've refactored the code, and performed all tests

@seetadev
Copy link
Contributor

seetadev commented Oct 8, 2025

@yashksaini-coder : Awesome, great to hear. Re-ran the CI/CD pipeline. Waiting for the test results.

@yashksaini-coder
Copy link
Contributor

yashksaini-coder commented Oct 9, 2025

@seetadev Requesting another run again, fixed the timeout issue for the gossipsub_backward_compatibility test

@seetadev
Copy link
Contributor

seetadev commented Oct 9, 2025

@yashksaini-coder : Definitely, Yash :) Appreciate the efforts.

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.

6 participants