Skip to content

Commit b5ba164

Browse files
committed
Fixed: Parse reruns were happening in path cases since they didn't had a version and null versions were not registered (register them with *
1 parent c321140 commit b5ba164

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed

source/redub/package_searching/api.d

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ PackageInfo basePackage(string packageName, string packageVersion, string requir
8181
PackageInfo pack;
8282
pack.subPackage = getSubPackageInfoRequiredBy(packageName, requiredBy, pack.packageName);
8383
pack.requiredBy = requiredBy;
84+
pack.bestVersion = SemVer(packageVersion);
8485
pack.requiredVersion = SemVer(packageVersion);
8586
pack.isInternalSubPackage = isInternalSubPackage;
8687
return pack;

source/redub/parsers/json.d

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,7 @@ BuildRequirements parse(JSONValue json, ParseConfig cfg, out BuildConfiguration
327327
if(value.type == JSONType.object) ///Uses path style
328328
{
329329
path = tryStr(value, "path");
330-
version_ = tryStr(value, "version");
330+
version_ = tryStr(value, "version", "*");
331331
repo = tryStr(value, "repository");
332332
visibility = value.tryStr("visibility");
333333
enforce(version_ || path,

source/redub/tree_generators/dub.d

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ private BuildRequirements parseDependency(const ref Dependency dep, const ref Bu
190190

191191
string subPkg = dep.pkgInfo.isInternalSubPackage ? dep.subPackage : null;
192192
string parentName = dep.subPackage ? dep.parentName : null;
193-
BuildRequirements depReq = parseProject(dep.pkgInfo.path, info, dep.subConfiguration, subPkg, null, parentName);
193+
BuildRequirements depReq = parseProject(dep.pkgInfo.path, info, dep.subConfiguration, subPkg, null, parentName, false, dep.version_);
194194
if(getLogLevel() >= LogLevel.vverbose)
195195
{
196196
infos(dep.name, " parsed in ", sw.peek.total!"msecs", "ms");

0 commit comments

Comments
 (0)