X Tutup
Skip to content

Commit c7261df

Browse files
authored
Merge pull request #1117 from biojava/jd/issue1116
Don't output label_seq_id for non-polymers in mmCIF writing
2 parents 21d61b1 + 274a36a commit c7261df

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
BioJava Changelog
22
-----------------
33

4+
BioJava 7.2.3 - future release
5+
==============================
6+
### Fixed
7+
* Don't use label_seq_id in mmCIF output for non-polymers #1116
8+
49
BioJava 7.2.2
510
==============================
611
### Fixed

biojava-structure/src/main/java/org/biojava/nbio/structure/io/cif/AbstractCifFileSupplier.java

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,12 @@ public void accept(WrappedAtom wrappedAtom) {
308308
}
309309
}
310310
labelEntityId.add(entityId);
311-
labelSeqId.add(seqId);
311+
// see https://github.com/biojava/biojava/issues/1116
312+
if (chain.getEntityInfo().getType() == EntityType.POLYMER) {
313+
labelSeqId.add(seqId);
314+
} else {
315+
labelSeqId.markNextNotPresent();
316+
}
312317
String insCode = "";
313318
if (group.getResidueNumber().getInsCode() != null) {
314319
insCode = Character.toString(group.getResidueNumber().getInsCode());

0 commit comments

Comments
 (0)
X Tutup