Skip to content

Added warning to inform users of known bug and issues fastcc.py #1427

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: devel
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions src/cobra/flux_analysis/fastcc.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""Provide an implementation of FASTCC."""

from typing import TYPE_CHECKING, List, Optional
from warnings import warn
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Linting will complain about the empty line above.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry I think I might not understand, the original is:

""Provide an implementation of FASTCC."""

from typing import TYPE_CHECKING, List, Optional

from optlang.symbolics import Zero

from .helpers import normalize_cutoff


Should there not be an empty line between the built-in functions, but empty lines between: built-ins, other packages, other modules? If so I understand, otherwise I am a bit lost


from optlang.symbolics import Zero

Expand Down Expand Up @@ -33,6 +34,15 @@ def _find_sparse_mode(
The list of reactions to consider as consistent.

"""
warn(
"Use find_blocked_reactions instead as "
"this function contains a known bug "
"which allows reactions with zero net flux to be considered active,"
" as well as known discrepancies between this function "
"and its Matlab implementation "
"present in the COBRA toolbox. "
"Please, see https://github.com/opencobra/cobrapy/issues/1154 for more information."
)
if rxns:
obj_vars = []
vars_and_cons = []
Expand Down
Loading