Skip to content

Commit 9680149

Browse files
committed
disable rank check
1 parent 6ebd95f commit 9680149

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/algorithms/gfa_to_handle.cpp

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -303,7 +303,7 @@ static void add_path_listeners(GFAParser& parser, MutablePathMutableHandleGraph*
303303
string rgfa_path_name;
304304
if (path_rank > 0) {
305305
// Special logic for off-reference paths, which get loaded into special rGFA cover paths
306-
rgfa_path_name = RGFACover::make_rgfa_path_name(path_name, offset, length, true);
306+
rgfa_path_name = RGFACover::make_rgfa_path_name(path_name, offset, length, false);
307307
} else {
308308
// TODO: See if we can split up the path name into a sample/haplotype/etc. to give it a ref sense.
309309
rgfa_path_name = PathMetadata::create_path_name(PathSense::GENERIC,
@@ -1044,7 +1044,13 @@ void GFAParser::parse(istream& in) {
10441044
} else {
10451045
// This path existed already. Make sure we aren't showing a conflicting rank
10461046
if (rgfa_path_rank != get<0>(found->second)) {
1047-
throw GFAFormatError("rGFA path " + rgfa_path_name + " has conflicting ranks " + std::to_string(rgfa_path_rank) + " and " + std::to_string(get<0>(found->second)));
1047+
// vg paths can now write different fragments of the same sample/hap with different ranks
1048+
// (unlike minigraph where all fragments of teh same assembly share a rank)
1049+
// by consequence, this check needs to be disabled.
1050+
// TODO: we still want to check that each individual fragment has consisten ranks
1051+
// so the check should be moved downstream
1052+
//
1053+
// throw GFAFormatError("rGFA path " + rgfa_path_name + " has conflicting ranks " + std::to_string(rgfa_path_rank) + " and " + std::to_string(get<0>(found->second)));
10481054
}
10491055
}
10501056
auto& visit_queue = get<2>(found->second);

0 commit comments

Comments
 (0)