refactor: properly report more error types from dep solver#149
refactor: properly report more error types from dep solver#149andrius-puksta-sensmetry merged 18 commits intomainfrom
Conversation
5b8b3a8 to
8b75a11
Compare
7590c2d to
1e7b3ce
Compare
e8eba6f to
2e45160
Compare
0660cad to
2f583a0
Compare
|
@andrius-puksta-sensmetry Other than doing a regression test for the lexer update it looks good. |
2f583a0 to
236222d
Compare
|
Ran into a problem/bug: std packages have dependency cycles, and it's unclear how to deal with this when cloning one of them:
And so invalid lockfile is generated, which does have all needed projects, but the current project does not have an identifier and thus there is an unsatisfied dependency. Ways to deal with this, none perfect:
This is unsolvable in the general case, since current project has no identifier. I'll implement 2, since it's better than nothing. Any better ideas? |
236222d to
7a3aca6
Compare
|
Added IRIs for current project to lockfile when the IRIs are known. |
victor-linroth-sensmetry
left a comment
There was a problem hiding this comment.
- Remove version constraints from lockfile (also bump lockfile version to 0.3). They are not needed for version resolution and arguably hurt readability a bit.
Agree on the readability. It would be nice for the version constraint compatibility to be checked somewhere though, like maybe when syncing?
2e006ef to
b2c0e65
Compare
This would (I think) require resolving all deps again to be able to check transitive deps, while also pinning the already known deps from lockfile to their known versions while resolving. Or maybe the lockfile should just include version constraints... What do you think @tilowiklundSensmetry? |
There was a problem hiding this comment.
Not checked every line, and isn't confident about all changes etc, but I see it as critical that this PR lands and that we reduce the amount of open PRs from a practical perspective. 👍 for merge sooner rather than later without further review from me
consideRatio
left a comment
There was a problem hiding this comment.
With Victor's review addressed big 👍 for merge!
Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
… meta Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
…info` subcommands Signed-off-by: Andrius Pukšta <andrius.puksta@sensmetry.com>
a883881 to
3879bdf
Compare
|
Included changes described in #192 (comment) (except for the tests). |
|
Wieee excited about getting this merged! |
Changes:
Example lockfile fragment before:
Example after:
cargo test, since we have none. This cleans upcargo testoutput.Fixes
Report a proper error when package was not found:
instead of previous:
Error message could be improved, but at least now it's explicitly checked and handled.
Report a proper error when required package version was not found:
instead of previous:
Fixes #108.
Use
Debugimpls ofreqwest(_middleware)errors to get all error details, sinceDisplayimpls give no details. This makes errors look uglier. Current:Previous:
Other fixes:
sysand add: run package and dependency resolver before adding the requested package to.project.jsonglobal = truetoResolutionOptionsRefactor
sysand syncto not re-read lockfile it just generatedDeps
logosto 0.16; this version changes semantics of regexes to work properly and (probably) no longer be too greedy. This PR does not change our usage oflogos, asidde from fixing line comment parsing.