Skip to content

Commit fcfb7f0

Browse files
AlexKaneRUSozzzzzmaksbotan
authored
Version 0.1.3.1. Fixed reading of insertion code for residues in MAE (#34)
Co-authored-by: Bogdan Neterebskii <[email protected]> Co-authored-by: Maxim Koltsov <[email protected]>
1 parent c521fd1 commit fcfb7f0

File tree

5 files changed

+24
-16
lines changed

5 files changed

+24
-16
lines changed

.travis.yml

Lines changed: 17 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,28 @@
11
sudo: false
2-
language: haskell
2+
language: generic
3+
4+
env:
5+
global:
6+
# HACKAGE_PASSWORD
7+
- secure: p4viJPiZUbANBNWynxsHERHnofPaZgrhmZEMZrsocWNV0snrRpYOoFogL1G2WQ7LJH2eMAfWUuwL0kCqoPOu4fiXXliG6h/zL8uKGgikOZ96C4oCptuOG/Ew117Hj1Ao9cp+9hieu4IADjORe7/BtCcpqDTV2kG7No0+O6bano1Ws+X6IVfrMHHB0DfUNqz9nfg6u3+6wAnPqh3AWOTULIdcV+eq2HD3+iBpR+laPiTATQayDMjC8FYWMVr8NsS07Z0I/jYBN1/lhvRH27beH02CzXpqaEcNn8yfuX6bKEPdjOtdPbl01YHBCnBtZpiluDuwj7a7ITDLqhsQ6pA5iduKQthOX75mooyhwQCEhH0KqlwysOT37k9Q4b/DMQAG6cuwyhZrAtXSprDQVDGgOr72RSUDwkiYmORpTno1VWGFg1ToOVPIN2Rel2HEyb/M/SVozV8lmSZ5D+CvomRg7H6SqCxBi8jP1MsRRBeZ1bBXolfVL7+OR2T4d8zmluDJwOrtQ4zfI/mbnvBg91N4fDY4ibdF/fCDav3/I5timmfyqRCGOVzWlhIovbKwo0OYj3xd9q7SP/EL4Xg8IcZedQF8/viCsltWcceLPBKL63eI9XUbk5enB1WDsDMIae7IUAuUjJ9JmX1XzNiSwG+omD+OCLZbh4UUAS3SngZK4KQ=
38

49
# Caching so the next build will be fast too.
510
cache:
611
directories:
712
- $HOME/.stack
813

9-
matrix:
10-
include:
11-
- ghc: 8.6.4
12-
env: STACK_YAML="$TRAVIS_BUILD_DIR/stack.yaml"
13-
1414
before_install:
15-
- mkdir -p ~/.local/bin
16-
- export PATH=$HOME/.local/bin:$PATH
17-
- travis_retry curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'
15+
- curl -sSL https://get.haskellstack.org/ | sh
16+
- stack --version
1817

1918
install:
20-
- travis_wait 60 stack --no-terminal --system-ghc test --only-snapshot
19+
- stack build --test --bench --only-dependencies
2120

22-
script:
23-
- stack --no-terminal --system-ghc test --pedantic
21+
jobs:
22+
include:
23+
- stage: Build and test
24+
script: stack build --pedantic --test --bench --no-run-benchmarks
25+
- stage: Hackage deploy
26+
# n is for "store credentials" question
27+
script: echo -e "ozzzzz\n${HACKAGE_PASSWORD}\nn" | stack upload --pvp-bounds both .
28+
if: tag IS present

ChangeLog.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
## [Unreleased]
44

5+
## [0.1.3.1] - 2020-04-02
6+
### Fixed
7+
- Reading of insertion code for residues in MAE.
8+
59
## [0.1.3.0] - 2020-03-27
610
### Added
711
- Residue index in `Structure`.

package.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: cobot-io
2-
version: 0.1.3.0
2+
version: 0.1.3.1
33
github: "less-wrong/cobot-io"
44
license: BSD3
55
category: Bio

src/Bio/MAE.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ instance StructureModels Mae where
140140
where
141141
name = stripQuotes $ unsafeGetFromContents "s_m_pdb_residue_name" h
142142
residueNumber = unsafeGetFromContents "i_m_residue_number" h
143-
insertionCode = unsafeGetFromContents "s_m_insertion_code" h
143+
insertionCode = getFromContents defaultInsertionCode "s_m_insertion_code" h
144144
atoms = V.fromList $ fmap indexToAtom group
145145

146146
localInds = [0 .. length group - 1]

test/PDBSpec.hs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,5 +145,4 @@ firstPDBModel filepath = do
145145
firstMaeModel :: (MonadIO m) => FilePath -> m Model
146146
firstMaeModel filepath = do
147147
eitherMae <- modelsFromMaeFile filepath
148-
-- `evaluate . force` fails for some reason
149-
pure . V.head $ fromRight undefined eitherMae
148+
liftIO . ef . V.head $ fromRight undefined eitherMae

0 commit comments

Comments
 (0)