Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(40)

Issue 10540151: First pass at version constraint solver. (Closed)

Created:
8 years, 6 months ago by Bob Nystrom
Modified:
8 years, 6 months ago
Reviewers:
nweiz
CC:
reviews_dartlang.org
Visibility:
Public.

Description

First pass at version constraint solver. It does: - Walk dependency graphs. - Unify shared constraints. - Go through Source to get dependency and version information. - Handle the fact that everything is async. - Find best versions that match all constraints. - Error out if it can't find a match or gets stuck in a loop. - Have an OK amount of tests. It does not: - Handle dependencies from different sources. - Integrate with the rest of pub. - Implement an actual "pub update" command. - Do very much to minimize server traffic. (Though it does cache pubspecs it has requested.) Committed: https://code.google.com/p/dart/source/detail?r=8985

Patch Set 1 #

Total comments: 81

Patch Set 2 : Respond to review. #

Patch Set 3 : Use Futures.wait() instead of nested chain() calls. #

Patch Set 4 : Request all versions from the source, and not just the best. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1238 lines, -43 lines) Patch
M utils/pub/package.dart View 1 4 chunks +11 lines, -4 lines 0 comments Download
M utils/pub/pubspec.dart View 1 3 chunks +7 lines, -10 lines 0 comments Download
M utils/pub/source.dart View 1 2 3 2 chunks +24 lines, -0 lines 0 comments Download
M utils/pub/version.dart View 1 5 chunks +224 lines, -6 lines 0 comments Download
A utils/pub/version_solver.dart View 1 2 3 1 chunk +425 lines, -0 lines 0 comments Download
M utils/tests/pub/pubspec_test.dart View 1 2 chunks +19 lines, -0 lines 0 comments Download
A utils/tests/pub/version_solver_test.dart View 1 2 3 1 chunk +277 lines, -0 lines 0 comments Download
M utils/tests/pub/version_test.dart View 1 6 chunks +251 lines, -23 lines 0 comments Download

Messages

Total messages: 8 (0 generated)
Bob Nystrom
Argh, forgot to actually send it out for review yesterday...
8 years, 6 months ago (2012-06-14 21:48:12 UTC) #1
nweiz
https://chromiumcodereview.appspot.com/10540151/diff/1/utils/pub/package.dart File utils/pub/package.dart (right): https://chromiumcodereview.appspot.com/10540151/diff/1/utils/pub/package.dart#newcode65 utils/pub/package.dart:65: // it worth keeping this around? Seems fine to ...
8 years, 6 months ago (2012-06-18 18:29:19 UTC) #2
Bob Nystrom
Thanks! https://chromiumcodereview.appspot.com/10540151/diff/1/utils/pub/package.dart File utils/pub/package.dart (right): https://chromiumcodereview.appspot.com/10540151/diff/1/utils/pub/package.dart#newcode65 utils/pub/package.dart:65: // it worth keeping this around? On 2012/06/18 ...
8 years, 6 months ago (2012-06-20 01:40:04 UTC) #3
nweiz
https://chromiumcodereview.appspot.com/10540151/diff/1/utils/pub/source.dart File utils/pub/source.dart (right): https://chromiumcodereview.appspot.com/10540151/diff/1/utils/pub/source.dart#newcode39 utils/pub/source.dart:39: Future<Version> findVersion(String name, On 2012/06/20 01:40:04, Bob Nystrom wrote: ...
8 years, 6 months ago (2012-06-20 21:08:48 UTC) #4
Bob Nystrom
Thanks! https://chromiumcodereview.appspot.com/10540151/diff/1/utils/pub/source.dart File utils/pub/source.dart (right): https://chromiumcodereview.appspot.com/10540151/diff/1/utils/pub/source.dart#newcode40 utils/pub/source.dart:40: VersionConstraint constraint) { On 2012/06/20 21:08:48, nweiz wrote: ...
8 years, 6 months ago (2012-06-20 22:29:54 UTC) #5
nweiz
https://chromiumcodereview.appspot.com/10540151/diff/1/utils/pub/source.dart File utils/pub/source.dart (right): https://chromiumcodereview.appspot.com/10540151/diff/1/utils/pub/source.dart#newcode40 utils/pub/source.dart:40: VersionConstraint constraint) { On 2012/06/20 22:29:54, Bob Nystrom wrote: ...
8 years, 6 months ago (2012-06-20 23:47:44 UTC) #6
Bob Nystrom
Requests all versions from the source now. PTAL, thanks! https://chromiumcodereview.appspot.com/10540151/diff/1/utils/pub/source.dart File utils/pub/source.dart (right): https://chromiumcodereview.appspot.com/10540151/diff/1/utils/pub/source.dart#newcode40 utils/pub/source.dart:40: ...
8 years, 6 months ago (2012-06-21 00:12:18 UTC) #7
nweiz
8 years, 6 months ago (2012-06-21 00:15:47 UTC) #8
lgtm++

Powered by Google App Engine
This is Rietveld 408576698