Skip to content
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

Update and fix examples #2760

Closed
wants to merge 7 commits into from
Closed

Conversation

apenzk
Copy link
Contributor

@apenzk apenzk commented Apr 7, 2024

This PR fixes some readmes and examples in the example section

  • libp2p readme example does not work in its current form, which is fixed in this PR
  • routed echo example missing in the main readme
  • inconsistent style in the examples. Sometimes the main function is in the beginning sometimes at the end. This PR moves the main function in chat.go and proxy.go at the start of the file in line with the other examples.
  • in chat.go the handleStream function is not applied consistently. This is fixed.

@sukunrt
Copy link
Member

sukunrt commented Apr 12, 2024

Thanks for the PR @apenzk. There are too many different changes here, can you break this in to smaller PRs?

  1. libp2p readme example fix
  2. fix docs to include routed echo example
  3. fix consistency with handleStream

There's no reason to move the main function around. It'd be a bit nicer if there were consistency in where the main function is in files, it's infeasible to maintain this consistency without automated tooling.

@apenzk
Copy link
Contributor Author

apenzk commented Apr 12, 2024

@sukunrt done as requested.

@apenzk apenzk closed this Apr 12, 2024
@apenzk apenzk deleted the update-examples-ap branch April 16, 2024 08:12
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.

None yet

2 participants