Commit 2645e924 authored by Andreas Tille's avatar Andreas Tille
Browse files

New upstream version 0.14.1

parent 13239c5c
Loading
Loading
Loading
Loading
+16 −1
Original line number Diff line number Diff line
@@ -3,7 +3,8 @@ Contributing
============

Contributions are welcome, and they are greatly appreciated! Every little bit
helps, and credit will always be given.
helps, and credit will always be given. For issues that contributors have 
experienced in the past, see the FAQ at the bottom of this document.

You can contribute in many ways:

@@ -240,3 +241,17 @@ Please use concise descriptive commit messages and consider using
   instead of ``my_dict.iteritems()`` use ``six.iteritems(my_dict)``

Thank you very much for contributing to cobrapy!

FAQs
----
Q1. Why do all of the tests that involve loading a pickled model fail on my branch?
	A: Pickling is the standard method for serializing objects in python,
	which is commonly done during operations like multiprocessing.
	Because of this, we need to maintain tests that run on pickled
	models, otherwise contributors may inadvertantly break
	multiprocessing features. If changes you made to cobrapy
	modify attributes of the ``cobra.Model`` class, the pickled
	models stored in the repository won't contain those changes
	and may fail tests that you add or modify. To resolve these
	errors, just run ``cobra/test/data/update_pickles.py`` on your
	branch, which will repickle the models.
+25 −54
Original line number Diff line number Diff line
language: python
python: 3.5
sudo: false
cache:
  pip: true
python:
  - "2.7"
  - "3.5"
  - "3.6"
  - "3.7-dev"

git:
  depth: 2

cache:
  pip: true

branches:
 only:
 - master
@@ -18,54 +24,18 @@ env:

matrix:
  fast_finish: true
  exclude:
    - python: 3.5
  include:
    - os: linux
      python: 3.5
      env:
        - TOXENV=pep8
    - os: linux
      python: 2.7
      env: TOXENV=py27
    - os: linux
      python: 3.5
      env: TOXENV=py35
    - os: linux
      python: 3.6
      env: TOXENV=py36
    - os: linux
      python: 3.7-dev
      env: TOXENV=py37
    - os: linux
      python: 3.5
      env: TOXENV=sbml
    - os: linux
      python: 3.5
      env: TOXENV=array
    #    - os: osx
    #      language: generic
    #      before_install:
    #        - brew update
    #        - brew install --without-readline --without-xz --without-gdbm --without-sqlite python3
    #        - virtualenv env -p python3
    #        - source env/bin/activate
    #    - os: osx
    #      language: generic
    #      before_install:
    #        - brew update
    #        - brew install --without-readline --without-xz --without-gdbm --without-sqlite python2
    #        - virtualenv env -p python2
    #        - source env/bin/activate

before_install:
  - travis_retry pip install -U pip setuptools wheel tox

before_cache:
  - set +e
install:
  - pip install --upgrade pip setuptools wheel tox tox-travis

script:
  - travis_wait tox
  - tox -- --benchmark-skip --cov-report xml --cov-report term
  - bash <(curl -s https://codecov.io/bash)

stages:
  - test
  - name: deploy
    if: tag IS present

# N.B.: Currently, Travis mangles (escapes) the release tag body badly.
#before_deploy:
@@ -75,27 +45,28 @@ deploy:
  - provider: pypi
    skip_cleanup: true
    distributions: sdist bdist_wheel
    install: skip
    script:
      - echo "Deploying COBRApy to PyPI."
    on:
      tags: true
      repo: $GITHUB_REPO
      python: '3.6'
      condition: $TRAVIS_OS_NAME == "linux"
    user: cobrapy
    password: $PYPI_PASSWORD
  - provider: script
    skip_cleanup: true
    install: skip
    script: scripts/deploy_website.sh
    on:
      tags: true
      repo: $GITHUB_REPO
      python: '3.6'
      condition: $TRAVIS_OS_NAME == "linux"
  - provider: releases
    skip_cleanup: true
    install: skip
    script:
    - echo "Releasing COBRApy to GitHub."
    api_key: $GITHUB_TOKEN
    body: "Please see https://github.com/opencobra/cobrapy/tree/${TRAVIS_TAG}/release-notes/${TRAVIS_TAG}.md for the full release notes."
    on:
      tags: true
      repo: $GITHUB_REPO
      python: '3.6'
      condition: $TRAVIS_OS_NAME == "linux"
+933 −0

File added.

Preview size limit exceeded, changes collapsed.

+5 −3
Original line number Diff line number Diff line
@@ -8,12 +8,14 @@ from os import name as _name
from os.path import abspath as _abspath
from os.path import dirname as _dirname

from cobra import flux_analysis, io
from cobra.core import (
    DictList, Gene, Metabolite, Model, Object, Reaction, Species)
    Configuration, DictList, Gene, Metabolite, Model, Object, Reaction,
    Species)
from cobra import flux_analysis
from cobra import io
from cobra.util import show_versions

__version__ = "0.13.4"
__version__ = "0.14.1"

# set the warning format to be prettier and fit on one line
_cobra_path = _dirname(_abspath(__file__))

cobra/config.py

deleted100644 → 0
+0 −10
Original line number Diff line number Diff line
# -*- coding: utf-8 -*-

from __future__ import absolute_import

import logging

log = logging.getLogger(__name__)

non_zero_flux_threshold = 1e-6
ndecimals = 6
Loading