[Git][java-team/ciftools-java][master] 5 commits: Fixing debian/watch (GitHub releases -> tags)

Andrius Merkys (@merkys) gitlab at salsa.debian.org
Sun Dec 5 13:08:50 GMT 2021



Andrius Merkys pushed to branch master at Debian Java Maintainers / ciftools-java


Commits:
80deb401 by Andrius Merkys at 2021-12-05T07:29:00-05:00
Fixing debian/watch (GitHub releases -> tags)

- - - - -
6e9deed9 by Andrius Merkys at 2021-12-05T07:29:27-05:00
New upstream version 3.0.1
- - - - -
e9356470 by Andrius Merkys at 2021-12-05T07:29:38-05:00
Update upstream source from tag 'upstream/3.0.1'

Update to upstream version '3.0.1'
with Debian dir 8354586e33272ce5b8f7160f1be34d0a1566342b
- - - - -
79a73c0f by Andrius Merkys at 2021-12-05T07:32:17-05:00
Refreshing patches.

- - - - -
8f57eb67 by Andrius Merkys at 2021-12-05T07:32:34-05:00
Update changelog for 3.0.1-1 release

- - - - -


11 changed files:

- CHANGELOG.md
- README.md
- debian/changelog
- debian/patches/deactivate_tests_using_network.patch
- debian/watch
- pom.xml
- src/main/java/org/rcsb/cif/text/TokenizerState.java
- src/test/java/org/rcsb/cif/IntegrationTest.java
- src/test/java/org/rcsb/cif/ReaderTest.java
- + src/test/resources/cif/AF-O49373-F1-model_v1.cif
- + src/test/resources/cif/AF-Q76EI6-F1-model_v1.cif


Changes:

=====================================
CHANGELOG.md
=====================================
@@ -3,6 +3,11 @@ CIFTools Changelog
 
 This project uses semantic versioning. Furthermore, this project provides code that was generated from schemata. Any schema change that introduces a breaking change in the generated code is considered as breaking for the whole project. Additional information is provided below when this occurs (named `Breaking schema changes`). Most of these occur in experimental categories and are unlikely to affect your code. `Breaking API changes` will be avoided starting with version 1.0.0.
 
+ciftools-java 3.0.1 - November 2021
+-------------
+### Bug fixes
+* proper handling of strings such as: `''cytochrome P450`
+
 ciftools-java 3.0.0 - September 2021
 -------------
 ### New features


=====================================
README.md
=====================================
@@ -15,7 +15,7 @@ CIFTools is distributed by maven. To get started, append your `pom.xml` by:
 <dependency>
   <groupId>org.rcsb</groupId>
   <artifactId>ciftools-java</artifactId>
-  <version>2.0.2</version>
+  <version>3.0.0</version>
 </dependency>
 ```
 


=====================================
debian/changelog
=====================================
@@ -1,3 +1,11 @@
+ciftools-java (3.0.1-1) unstable; urgency=medium
+
+  * New upstream version 3.0.1
+  * Fixing debian/watch (GitHub releases -> tags)
+  * Refreshing patches.
+
+ -- Andrius Merkys <merkys at debian.org>  Sun, 05 Dec 2021 07:32:27 -0500
+
 ciftools-java (3.0.0-2) unstable; urgency=medium
 
   * Source-only upload


=====================================
debian/patches/deactivate_tests_using_network.patch
=====================================
@@ -85,7 +85,7 @@ Last-Update: 2021-10-17
  import org.junit.jupiter.api.Test;
  import org.rcsb.cif.model.Category;
  import org.rcsb.cif.model.CifFile;
-@@ -313,6 +314,7 @@
+@@ -311,6 +312,7 @@
      /**
       * BinaryCIF might slightly violate the schema and lead to a ClassCastException if not handled.
       */
@@ -93,7 +93,7 @@ Last-Update: 2021-10-17
      @Test
      public void readRcsbAndEbiGeneric() throws IOException {
          CifFile rcsb = CifIO.readById("1acj");
-@@ -329,6 +331,7 @@
+@@ -327,6 +329,7 @@
          assertEquals(83, ebiNdbSeqNum.getRowCount());
      }
  
@@ -101,11 +101,3 @@ Last-Update: 2021-10-17
      @Test
      public void readRcsbAndEbiWithSchema() throws IOException {
          MmCifFile rcsb = CifIO.readById("1acj").as(StandardSchemata.MMCIF);
-@@ -346,6 +349,7 @@
-         assertEquals(83, ebiNdbSeqNum.getRowCount());
-     }
- 
-+    @Disabled("Attempts to use the network")
-     @Test
-     public void whenReadingAlphaFoldData_thenConfidenceScoresAvailable() throws IOException {
-         String id = "AF-Q76EI6-F1-model_v1";


=====================================
debian/watch
=====================================
@@ -1,3 +1,2 @@
 version=4
-
-https://github.com/rcsb/ciftools-java/releases (?:.*?)?@PACKAGE at -(\d[\d.]*)\.tar\.gz
+https://github.com/rcsb/ciftools-java/tags (?:.*?)?@PACKAGE at -(\d[\d.]*)\.tar\.gz


=====================================
pom.xml
=====================================
@@ -3,7 +3,7 @@
     <modelVersion>4.0.0</modelVersion>
     <groupId>org.rcsb</groupId>
     <artifactId>ciftools-java</artifactId>
-    <version>3.0.0</version>
+    <version>3.0.1</version>
     <packaging>jar</packaging>
     <description>
         A Java library for handling text and binary CIF files.
@@ -35,7 +35,7 @@
         <connection>scm:git:git://github.com/rcsb/ciftools-java.git</connection>
         <developerConnection>scm:git:git at github.com:rcsb/ciftools-java.git</developerConnection>
         <url>https://github.com/rcsb/ciftools-java</url>
-      <tag>ciftools-java-3.0.0</tag>
+      <tag>ciftools-java-3.0.1</tag>
   </scm>
 
     <dependencies>
@@ -110,7 +110,7 @@
                         <configuration>
                             <serverId>ossrh</serverId>
                             <nexusUrl>https://oss.sonatype.org/</nexusUrl>
-                            <autoReleaseAfterClose>false</autoReleaseAfterClose>
+                            <autoReleaseAfterClose>true</autoReleaseAfterClose>
                         </configuration>
                     </plugin>
 


=====================================
src/main/java/org/rcsb/cif/text/TokenizerState.java
=====================================
@@ -343,7 +343,7 @@ class TokenizerState {
                 tokenType = CifTokenType.COMMENT;
                 break;
             case '"': case '\'':
-                if (isTripleQuoteAtPosition()) {
+                if (c == '\'' && isTripleQuoteAtPosition()) {
                     eatTripleQuote();
                     tokenType = CifTokenType.VALUE;
                     break;


=====================================
src/test/java/org/rcsb/cif/IntegrationTest.java
=====================================
@@ -19,9 +19,7 @@ import java.io.ByteArrayInputStream;
 import java.io.IOException;
 import java.io.InputStream;
 import java.lang.reflect.Array;
-import java.net.URL;
 import java.nio.charset.StandardCharsets;
-import java.util.OptionalDouble;
 
 import static org.junit.jupiter.api.Assertions.*;
 import static org.rcsb.cif.TestHelper.TEST_CASES;
@@ -345,19 +343,4 @@ public class IntegrationTest {
                 .getNdbSeqNum();
         assertEquals(83, ebiNdbSeqNum.getRowCount());
     }
-
-    @Test
-    public void whenReadingAlphaFoldData_thenConfidenceScoresAvailable() throws IOException {
-        String id = "AF-Q76EI6-F1-model_v1";
-        URL url = new URL("https://alphafold.ebi.ac.uk/files/" + id + ".cif");
-        MmCifFile cifFile = CifIO.readFromURL(url).as(StandardSchemata.MMCIF);
-
-        OptionalDouble averageLocal = cifFile.getFirstBlock()
-                .getMaQaMetricLocal()
-                .getMetricValue()
-                .values()
-                .average();
-
-        assertTrue(averageLocal.isPresent());
-    }
 }


=====================================
src/test/java/org/rcsb/cif/ReaderTest.java
=====================================
@@ -6,14 +6,16 @@ import org.rcsb.cif.model.IntColumn;
 import org.rcsb.cif.schema.StandardSchemata;
 import org.rcsb.cif.schema.mm.AtomSite;
 import org.rcsb.cif.schema.mm.MmCifBlock;
+import org.rcsb.cif.schema.mm.MmCifFile;
 
 import java.io.IOException;
 import java.io.InputStream;
 import java.util.List;
 import java.util.Map;
+import java.util.OptionalDouble;
 
-import static org.junit.jupiter.api.Assertions.assertEquals;
-import static org.junit.jupiter.api.Assertions.assertThrows;
+import static org.junit.jupiter.api.Assertions.*;
+import static org.junit.jupiter.api.Assertions.assertTrue;
 import static org.rcsb.cif.TestHelper.ERROR_MARGIN;
 import static org.rcsb.cif.TestHelper.TEST_CASES;
 
@@ -101,4 +103,30 @@ public class ReaderTest {
 
         );
     }
+
+
+    @Test
+    public void whenReadingAlphaFoldData_thenConfidenceScoresAvailable() throws IOException {
+        String id = "AF-Q76EI6-F1-model_v1";
+        InputStream inputStream = TestHelper.getInputStream("cif/" + id + ".cif");
+        MmCifFile cifFile = CifIO.readFromInputStream(inputStream).as(StandardSchemata.MMCIF);
+
+        OptionalDouble averageLocal = cifFile.getFirstBlock()
+                .getMaQaMetricLocal()
+                .getMetricValue()
+                .values()
+                .average();
+
+        assertTrue(averageLocal.isPresent());
+    }
+
+    @Test
+    public void whenReadingStringWithEmptyQuotation_thenValueAvailable() throws IOException {
+        String id = "AF-O49373-F1-model_v1";
+        InputStream inputStream = TestHelper.getInputStream("cif/" + id + ".cif");
+        MmCifFile cifFile = CifIO.readFromInputStream(inputStream).as(StandardSchemata.MMCIF);
+
+        String gene = cifFile.getFirstBlock().getCategory("af_target_ref_db_details").getColumn("gene").getStringData(0);
+        assertEquals("''cytochrome P450", gene, "Gene name with additional quotes not parsed correctly");
+    }
 }
\ No newline at end of file


=====================================
src/test/resources/cif/AF-O49373-F1-model_v1.cif
=====================================
The diff for this file was not included because it is too large.

=====================================
src/test/resources/cif/AF-Q76EI6-F1-model_v1.cif
=====================================
The diff for this file was not included because it is too large.


View it on GitLab: https://salsa.debian.org/java-team/ciftools-java/-/compare/ca8a71c1e5425a2a558110c3a11255985e370623...8f57eb67c24993f76c5b56184a9d526622a253c8

-- 
View it on GitLab: https://salsa.debian.org/java-team/ciftools-java/-/compare/ca8a71c1e5425a2a558110c3a11255985e370623...8f57eb67c24993f76c5b56184a9d526622a253c8
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-java-commits/attachments/20211205/d7eb0b16/attachment.htm>


More information about the pkg-java-commits mailing list