-
Notifications
You must be signed in to change notification settings - Fork 6
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
feat: add optional support for serde, dockerfile and HTTP API #56
base: master
Are you sure you want to change the base?
Conversation
Maybe I was a bit too cavalier blindly accepting my IDE's suggestions so there are some unintended consequences. Please let me know if they make a material difference; if they do I'll change them. |
COPY ./Cargo.toml ./Cargo.toml | ||
COPY ./Cargo.lock ./Cargo.lock | ||
|
||
# Create empty source files to trick cargo into building our dependencies |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why? I don't get this. You are actually copying these things further down?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The copy statements below and here are not the same? Do you mind elaborating?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why first "create empty source files" and then copy the real source files? Why not just copy the source files? It says "trick cargo", but I don't get why or what that means.
COPY ./yake_rust/benches ./yake_rust/benches | ||
COPY ./server/src ./server/src | ||
COPY ./python/Cargo.toml ./python/ | ||
COPY ./python/src ./python/src |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems like we are not installing some binary, but rather building everything from scratch in the Dockerfile, so could we get away with not having the python bindings in the Dockerfile? I mean, they are presumably not used and never intended to be used?
Or would we maybe need to make python bindings a "feature" for that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was some sort of issue where it seemed the tests in core Yake were being run by python. I'll look into it more and ping you once I have.
@@ -14,6 +14,7 @@ repository = "https://github.com/quesurifn/yake-rust" | |||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | |||
|
|||
[features] | |||
serde = ["dep:serde"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can omit it. serde = { optional = true }
automatically allocates a feature.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file probably belongs to the /server
folder
I am a bit curious whether LLM was used while working on the issue? :) |
@xamgore For docker, READMEs and cargo.toml yes. Remember the last thing I wrote in Rust was this. I don't really know the language / tool chain yet which includes compiler optimizations and such. |
No description provided.