Skip to content

Conversation

@Davidson-Souza
Copy link
Member

What is the purpose of this pull request?

  • Bug fix
  • Documentation update
  • New feature
  • Test
  • Other: Removing dependency

Which crates are being modified?

  • floresta-chain
  • floresta-cli
  • floresta-common
  • floresta-compact-filters
  • floresta-electrum
  • floresta-watch-only
  • floresta-wire
  • floresta
  • florestad
  • Other:

Description

core2 isn't really well maintained, and is only used in a few very specific cases for floresta. This commit removes it as a dependency.

To acchieve that, I've

  • Used bitcoin::io for things like Read, Write and Cursor
  • Implemented the Error trait inside floresta common

Copy link
Contributor

@luisschwab luisschwab left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 752e4a9

@jaoleal
Copy link
Collaborator

jaoleal commented May 16, 2025

ACK 752e4a9

@JoseSK999
Copy link
Contributor

JoseSK999 commented May 16, 2025

We are supposedly pulling the ioError, Read and Write traits from bitcoin::io but these are not imported in the no-std floresta-common::prelude.

We don't get compilation errors because we use floresta-common with std, but I think we should add these imports to the no-std prelude.

@Davidson-Souza
Copy link
Member Author

We are supposedly pulling the ioError, Read and Write traits from bitcoin::io but these are not imported in the no-std floresta-common::prelude.

We don't get compilation errors because we use floresta-common with std, but I think we should add these imports to the no-std prelude.

Good point! A quick git grep shows that in floresta-chain we pulling this type unconditionally from bitcoin itself. I think we should change this and pull these only from floresta-common for the sake of standardization. I don't think here, tho.

I'll add the re-exports to floresta-common to make it identical in both cases.

@Davidson-Souza Davidson-Souza added dependencies Pull requests that update a dependency file code quality Generally improves code readability and maintainability labels May 17, 2025
@Davidson-Souza
Copy link
Member Author

Oh, nice! I was blessed with the new linting too. I think all pull requests will break from now if they update their branch and trigger a new CI run.

core2 isn't really well maintained, and is only used in a few very
specific cases for floresta. This commit removes it as a dependency.

To acchieve that, I've
 - Used bitcoin::io for things like Read, Write and Cursor
 - Implemented the Error trait inside floresta common
@Davidson-Souza
Copy link
Member Author

Rebased after #489

Copy link
Contributor

@JoseSK999 JoseSK999 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK da6dc6c

@Davidson-Souza Davidson-Souza merged commit d0e2eef into vinteumorg:master May 19, 2025
10 checks passed
@Davidson-Souza Davidson-Souza mentioned this pull request Jun 23, 2025
15 tasks
Davidson-Souza added a commit that referenced this pull request Jun 23, 2025
core2 was made unused by #487, but it's still mentioned is floresta-common. This commit removes it
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

code quality Generally improves code readability and maintainability dependencies Pull requests that update a dependency file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants