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

Switch protobuf Java to generating with a Python script #1507

Open
spacey-sooty opened this issue Oct 29, 2024 · 5 comments
Open

Switch protobuf Java to generating with a Python script #1507

spacey-sooty opened this issue Oct 29, 2024 · 5 comments

Comments

@spacey-sooty
Copy link
Member

No description provided.

@mcm001
Copy link
Contributor

mcm001 commented Oct 29, 2024

Why? Keeping things in gradle makes tracking task inputs and outputs easier, and is in line with wpilib.

@spacey-sooty
Copy link
Member Author

and is in line with wpilib.

WPILib doesn't do this in Gradle? https://github.com/wpilibsuite/allwpilib/blob/f03e0cdf6a86e8fdb4111bf76d64f73539f19936/wpimath/generate_quickbuf.py#L13

Why? Keeping things in gradle makes tracking task inputs and outputs easier,

If we do keep it in Gradle we shouldn't use the plugin we are right now, we don't use its Java output anyways and we wont be using it for C++ after #1484

@mcm001
Copy link
Contributor

mcm001 commented Oct 29, 2024

Oh since December 2023, TIL. do you know why they switched to committing the generated code?
(Committing generated code is based af, ftr)

@spacey-sooty
Copy link
Member Author

Something about devs being able to read it in the codebase or something

@Gold856
Copy link
Contributor

Gold856 commented Oct 29, 2024

That's the reason for the other generated files, but the quickbuf files have a different reason. Having the quickbuf Java files pregenerated and committed means you don't need the quickbuf plugin available to generate the source files. This only impacts CMake because Gradle will download the plugin for you, and for Photon, there isn't any particular benefit to pregenerating quickbuf files (since CMake is not a build option) other than it's committed to the repo and you can look at it.

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

No branches or pull requests

3 participants