-
Notifications
You must be signed in to change notification settings - Fork 22
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
Remove EntitySource #108
Remove EntitySource #108
Conversation
Codecov Report
@@ Coverage Diff @@
## main #108 +/- ##
==========================================
+ Coverage 61.90% 65.45% +3.54%
==========================================
Files 16 11 -5
Lines 567 495 -72
==========================================
- Hits 351 324 -27
+ Misses 198 152 -46
- Partials 18 19 +1
|
Is there some background on this change? |
a585358
to
32471fb
Compare
Sorry @ncdc - I started this just before I left for holidays. Yeah, the idea was to take Varsha's PR, rebase, fix and put it back here. I'll fill out the description and tie it to a ticket. |
e3c8255
to
beb7312
Compare
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 change looks good to me apart from removal of rand.Seed
.
Updating operator-controller will be fun. And I'll be missing predicates.
cmd/sudoku/sudoku.go
Outdated
// adapted from: https://github.com/go-air/gini/blob/871d828a26852598db2b88f436549634ba9533ff/sudoku_test.go#L10 | ||
variables := make(map[deppy.Identifier]*input.SimpleVariable, 0) | ||
inorder := make([]deppy.Variable, 0) | ||
rand.Seed(time.Now().UnixNano()) |
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.
We are not on Go 1.20 yet in Deppy:
Line 3 in d928511
go 1.19 |
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 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.
I just merged the Go 1.20 bump. Need to rebase here now, it looks like.
Requires another rebase... |
Removes Entity and EntitySource. The solver takes in the Variable Source directly. The constraints, filters, sort or any transformation should be performed on variables before providing it to solver. Signed-off-by: Varsha Prasad Narsing <[email protected]>
Signed-off-by: Per Goncalves da Silva <[email protected]>
Signed-off-by: Per Goncalves da Silva <[email protected]>
Signed-off-by: Per Goncalves da Silva <[email protected]>
Signed-off-by: Per Goncalves da Silva <[email protected]>
beb7312
to
54375ee
Compare
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.
Looks good to me!
This PR replaces #95 by rebasing it and fixing merge conflicts. The intent of this PR is to remove the concepts of EntitySource and Entity from Deppy. The
VariableSource
interface can be implemented with access to specific backend clients (e.g. registry, kube client, etc.) in order to provide theirVariable
s.Closes #97