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

actix-prost: Fail build when selector does not match anything #26

Open
bragov4ik opened this issue Apr 1, 2024 · 0 comments
Open

actix-prost: Fail build when selector does not match anything #26

bragov4ik opened this issue Apr 1, 2024 · 0 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@bragov4ik
Copy link

Description

If selector is written incorrectly and it doesn't match any rpcs, the build just skips generation of actix (server?). This issue becomes non-trivial to debug :)
Instead, it would be useful to fail and report the faulty selector to the user.

Possible solutions

Result of .get there could be used to indicate it:

service
.methods
.iter()
.filter_map(|m| {
map.get(&format!(
"{}.{}.{}",
service.package, service.proto_name, m.proto_name
))
.map(|r| (m, *r))
})
.collect()

@bragov4ik bragov4ik changed the title Fail build when selector does not match anything actix-prost: Fail build when selector does not match anything Apr 1, 2024
@bragov4ik bragov4ik added enhancement New feature or request good first issue Good for newcomers labels Apr 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant