Repository: cfrioux/MeneTools (language: python)

Issue:
Filter the presence of seeds in the scope by removing seeds absent from the network
### Context
When running `mene scope`, one can provide a set of seeds that contain any metabolite, including some that do not belong to the considered metabolic network.

### Current behaviour
As the definition of the scope includes the seeds, these non-relevant compounds will be outputted as belonging to the scope. 

### Solution?
We could exclude these from the scope, and why not create a predicate to distinguish them as it might be a good debugging tool to catch these compounds. 

While we are making modifications, we could also create the predicate "non_produced_seeds" as a complement to "produced_seeds" to help filter seeds after computation.

@ArnaudBelcour what do you think? Will it have any unwanted consequence on m2m?


Filter the presence of seeds in the scope by removing seeds absent from the network
### Context
When running `mene scope`, one can provide a set of seeds that contain any metabolite, including some that do not belong to the considered metabolic network.

### Current behaviour
As the definition of the scope includes the seeds, these non-relevant compounds will be outputted as belonging to the scope. 

### Solution?
We could exclude these from the scope, and why not create a predicate to distinguish them as it might be a good debugging tool to catch these compounds. 

While we are making modifications, we could also create the predicate "non_produced_seeds" as a complement to "produced_seeds" to help filter seeds after computation.

@ArnaudBelcour what do you think? Will it have any unwanted consequence on m2m?




Discussion / hints:

Fix patch:
diff --git a/.github/workflows/pythonpublish.yml b/.github/workflows/pythonpublish.yml
index 32a42ee..b647234 100644
--- a/.github/workflows/pythonpublish.yml
+++ b/.github/workflows/pythonpublish.yml
@@ -21,12 +21,12 @@ jobs:
     - name: Install dependencies
       run: |
         python -m pip install --upgrade pip
-        pip install setuptools wheel twine
+        pip install setuptools wheel twine build
         pip install -r requirements.txt
     - name: Build and publish
       env:
         TWINE_USERNAME: ${{ secrets.PYPI_USERS }}
         TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
       run: |
-        python setup.py sdist bdist_wheel
+        python -m build
         twine upload dist/*
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 7e1e928..1a83978 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,15 @@
 # Changelog
 
+# MeneTools v3.4.0 (2024-02-28)
+
+## Modify
+
+* Filter the presence of seeds in the scope by removing seeds absent from the network (issue #15)
+* Modify if statement that will be deprecated in the future
+* Replace use of pkg_resources that will become deprecated
+* Move from `setup.py`/`setup.cfg` to `pyproject.toml`
+* Update license year
+
 # MeneTools v3.3.0 (2023-01-05)
 
 ## Add
diff --git a/README.md b/README.md
index d54d2e5..3cc305e 100644
--- a/README.md
+++ b/README.md
@@ -132,6 +132,14 @@ from menetools import run_menescope
 model = run_menescope(draft_sbml='required',seeds_sbml='required',output='optional')
 ```
 
+The outputs for menecope are
+
+- As a control: seeds that were provided but do not appear in the metabolic network.
+- The _scope_ i.e. compounds that are in the seeds and those that are produced from the seeds
+- Two subsets to distinguish seed status
+  - those that can be produced by the metabolic network. For such seeds, the organism would have the metabolic capability to renew the production in addition to what was available in the environement. 
+  - those that cannot be produced by the metabolic network. For such seeds, there is no alternative other than relying on the environmental composition.
+
 ### MENEACTI
 
 Meneacti is a python3 tool that retrieve the activable reactions from
@@ -296,4 +304,3 @@ model = run_menescope_inc(draft_sbml='required',seeds_sbml='required',targets_sb
 Many thanks to
 * [@Aluriak](https://github.com/Aluriak) for his awesome work with [Clyngor](https://github.com/Aluriak/clyngor).
 * [@mablt](https://github.com/mablt) for his contribution to MeneSeed.
-
diff --git a/menetools/__init__.py b/menetools/__init__.py
index acdd1af..0a10594 100644
--- a/menetools/__init__.py
+++ b/menetools/__init__.py
@@ -1,4 +1,4 @@
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
@@ -22,6 +22,6 @@
 from menetools.menescope_inc import run_menescope_inc
 
 
-__version__="3.3.0"
+__version__="3.4.0"
 """Define the version of the package.
 """
diff --git a/menetools/__main__.py b/menetools/__main__.py
index bc9962c..d2da8f1 100644
--- a/menetools/__main__.py
+++ b/menetools/__main__.py
@@ -1,4 +1,4 @@
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
@@ -14,9 +14,7 @@
 
 import argparse
 import logging
-import pkg_resources
 import sys
-import time
 
 logger = logging.getLogger('menetools')
 logger.setLevel(logging.DEBUG)
@@ -26,6 +24,7 @@
 logger.addHandler(out_hdlr)
 logger.propagate = True
 
+from menetools import __version__ as VERSION
 from menetools.menescope import run_menescope
 from menetools.meneacti import run_meneacti
 from menetools.menecheck import run_menecheck
@@ -36,7 +35,6 @@
 from menetools.menescope_inc import run_menescope_inc
 from shutil import which
 
-VERSION = pkg_resources.get_distribution("menetools").version
 LICENSE = """Copyright (C) Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 This program is free software: you can redistribute it and/or modify
 it under the terms of the GNU Lesser General Public License as published by
@@ -217,7 +215,7 @@ def main():
 
     scope_parser = subparsers.add_parser(
         "scope",
-        help="Get producible metabolites in a metabolic network, starting from seeds.",
+        help="Get producible metabolites in a metabolic network, starting from seeds. The outputs for menecope are (i) As a control: seeds that were provided but do not appear in the metabolic network., (ii) The _scope_ i.e. compounds that are in the seeds and those that are produced from the seeds, (iii) Two subsets to distinguish seed status. (iii-a) those that can be produced by the metabolic network. For such seeds, the organism would have the metabolic capability to renew the production in addition to what was available in the environement. (iii-b) those that cannot be produced by the metabolic network. For such seeds, there is no alternative other than relying on the environmental composition.",
         parents=[
             parent_parser_d, parent_parser_s, parent_parser_o
         ]
diff --git a/menetools/encodings/get_scope.lp b/menetools/encodings/get_scope.lp
index 04e39fc..7aa969e 100644
--- a/menetools/encodings/get_scope.lp
+++ b/menetools/encodings/get_scope.lp
@@ -10,12 +10,18 @@
 % You should have received a copy of the GNU Lesser General Public License
 % along with this program.  If not, see <http://www.gnu.org/licenses/>
 
+% filter seeds by removing those that never occur in the metabolic network
+true_seed(M) :- seed(M), reactant(M, _).
+true_seed(M) :- seed(M), product(M, _).
+
+absent_seed(M) :- seed(M), not true_seed(M).
+
 % scope of the seeds in the metabolic network
 dscope(M) :- product(M,R), dreaction(R),
                 dscope(M2) : reactant(M2,R).
     dscope(M) :- reactant(M,R), dreaction(R), reversible(R),
                 dscope(M2) : product(M2,R).
-    dscope(M) :- seed(M).
+    dscope(M) :- true_seed(M).
 
 % activated reactions in the metabolic network
 activated(R) :- dreaction(R),
@@ -24,8 +30,14 @@ activated(R) :- dreaction(R), reversible(R),
             dscope(M2) : product(M2,R).
 
 % seeds that can also be produced
-produced_seed(M):- product(M,R), dreaction(R), activated(R), seed(M).
-produced_seed(M):- reactant(M,R), dreaction(R), activated(R), reversible(R), seed(M).
+produced_seed(M):- product(M,R), dreaction(R), activated(R), true_seed(M).
+produced_seed(M):- reactant(M,R), dreaction(R), activated(R), reversible(R), true_seed(M).
+
+non_produced_seed(M):- true_seed(M), not produced_seed(M).
+
 
 #show dscope/1.
 #show produced_seed/1.
+#show non_produced_seed/1.
+#show absent_seed/1.
+#show activated/1.
diff --git a/menetools/meneacti.py b/menetools/meneacti.py
index 111b791..6f29f65 100644
--- a/menetools/meneacti.py
+++ b/menetools/meneacti.py
@@ -1,7 +1,7 @@
 #!/usr/bin/python3
 #-*- coding: utf-8 -*-
 
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
diff --git a/menetools/menecheck.py b/menetools/menecheck.py
index c8a7a6e..f7ae54e 100644
--- a/menetools/menecheck.py
+++ b/menetools/menecheck.py
@@ -1,7 +1,7 @@
 #!python
 # -*- coding: utf-8 -*-
 
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
diff --git a/menetools/menecof.py b/menetools/menecof.py
index 858a4e3..3f6a1e1 100644
--- a/menetools/menecof.py
+++ b/menetools/menecof.py
@@ -1,7 +1,7 @@
 #!/usr/bin/python
 #-*- coding: utf-8 -*-
 
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
diff --git a/menetools/menedead.py b/menetools/menedead.py
index 2d3cfea..662e990 100644
--- a/menetools/menedead.py
+++ b/menetools/menedead.py
@@ -1,7 +1,7 @@
 #!python
 # -*- coding: utf-8 -*-
 
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
diff --git a/menetools/menepath.py b/menetools/menepath.py
index 5a6bba3..bca950b 100644
--- a/menetools/menepath.py
+++ b/menetools/menepath.py
@@ -1,7 +1,7 @@
 #!/usr/bin/python3
 #-*- coding: utf-8 -*-
 
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
diff --git a/menetools/menescope.py b/menetools/menescope.py
index 89de3cc..37700a1 100644
--- a/menetools/menescope.py
+++ b/menetools/menescope.py
@@ -1,7 +1,7 @@
 #!/usr/bin/python3
 #-*- coding: utf-8 -*-
 
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
@@ -62,6 +62,8 @@ def run_menescope(draft_sbml,seeds_sbml,output=None):
     model = query.get_scope(draftnet, seeds)
     scope = []
     produced_seeds = []
+    non_produced_seeds = []
+    absent_seeds = []
     for pred in model:
         if pred == 'dscope':
             for a in model[pred, 1]:
@@ -69,10 +71,22 @@ def run_menescope(draft_sbml,seeds_sbml,output=None):
         if pred == 'produced_seed':
             for a in model[pred, 1]:
                 produced_seeds.append(a[0])
+        if pred == 'non_produced_seed':
+            for a in model[pred, 1]:
+                non_produced_seeds.append(a[0])
+        if pred == 'absent_seed':
+            for a in model[pred, 1]:
+                absent_seeds.append(a[0])
     logger.info(' ' + str(len(scope)) + ' compounds on scope:')
     logger.info('\n'.join(scope))
+    logger.info(' ' + str(len(produced_seeds)) + ' seeds are producible:')
+    logger.info('\n'.join(produced_seeds))
+    logger.info(' ' + str(len(non_produced_seeds)) + ' seeds are not producible:')
+    logger.info('\n'.join(non_produced_seeds))
+    logger.info(' ' + str(len(absent_seeds)) + ' seeds that were provided as input are absent from the network:')
+    logger.info('\n'.join(absent_seeds))
 
-    results = {'scope': scope, 'produced_seeds': produced_seeds}
+    results = {'scope': scope, 'produced_seeds': produced_seeds, 'non_produced_seeds': non_produced_seeds, 'absent_seeds': absent_seeds}
     if output:
         with open(output, "w") as output_file:
             json.dump(results, output_file, indent=True, sort_keys=True)
diff --git a/menetools/menescope_inc.py b/menetools/menescope_inc.py
index 3cff906..34138e5 100644
--- a/menetools/menescope_inc.py
+++ b/menetools/menescope_inc.py
@@ -1,7 +1,7 @@
 #!/usr/bin/python3
 #-*- coding: utf-8 -*-
 
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
diff --git a/menetools/meneseed.py b/menetools/meneseed.py
index e41d26a..9a5b8e1 100644
--- a/menetools/meneseed.py
+++ b/menetools/meneseed.py
@@ -1,7 +1,7 @@
 #!python
 # -*- coding: utf-8 -*-
 
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
diff --git a/menetools/query.py b/menetools/query.py
index 6694962..8d444a0 100644
--- a/menetools/query.py
+++ b/menetools/query.py
@@ -1,4 +1,4 @@
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
diff --git a/menetools/sbml.py b/menetools/sbml.py
index 6175c28..7ff291d 100644
--- a/menetools/sbml.py
+++ b/menetools/sbml.py
@@ -1,7 +1,7 @@
 #!/usr/bin/python
 # -*- coding: utf-8 -*-
 
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
@@ -245,7 +245,7 @@ def readSBMLspecies_clyngor(filename, speciestype) :
     model = get_model(sbml)
 
     listOfSpecies = get_listOfSpecies(model)
-    if listOfSpecies:
+    if listOfSpecies is not None:
         for e in listOfSpecies:
             if e.tag[0] == "{":
                 uri, tag = e.tag[1:].split("}")
diff --git a/menetools/utils.py b/menetools/utils.py
index 6c8fe51..512bd78 100644
--- a/menetools/utils.py
+++ b/menetools/utils.py
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
+# Copyright (C) 2017-2024 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Lesser General Public License as published by
 # the Free Software Foundation, either version 3 of the License, or
diff --git a/pyproject.toml b/pyproject.toml
new file mode 100644
index 0000000..e2a982a
--- /dev/null
+++ b/pyproject.toml
@@ -0,0 +1,39 @@
+[build-system]
+requires = ["setuptools>=61.0"]
+build-backend = "setuptools.build_meta"
+
+[project]
+name = "MeneTools"
+dynamic = ["version"]
+authors = [{name = "Clemence Frioux", email = "clemence.frioux@inria.fr"}]
+readme = "README.md"
+description = "Metabolic Network Topology Analysis Tools"
+license = {text = "LGPL-3.0-or-later"}
+dependencies = [
+  'clyngor_with_clingo',
+  'clyngor'
+]
+
+classifiers =[
+  'Programming Language :: Python :: 3.6',
+  'Programming Language :: Python :: 3.7',
+  'Programming Language :: Python :: 3.8',
+  'Operating System :: MacOS :: MacOS X',
+  'Operating System :: Unix',
+]
+
+[project.scripts]
+mene = "menetools.__main__:main"
+
+[project.urls]
+Homepage = "https://github.com/cfrioux/MeneTools"
+Changelog = "https://github.com/cfrioux/MeneTools/blob/main/CHANGELOG.md"
+
+[tool.setuptools]
+packages = ['menetools']
+package-dir = {'menetools' = 'menetools'}
+package-data = {'menetools' = ['encodings/*.lp']}
+
+[tool.setuptools.dynamic]
+version = { attr = "menetools.__version__" }
+dependencies = {file = ["requirements.txt"]}
diff --git a/setup.cfg b/setup.cfg
deleted file mode 100644
index 217e060..0000000
--- a/setup.cfg
+++ /dev/null
@@ -1,4 +0,0 @@
-[metadata]
-description-file = README.md
-version = attr: menetools.__version__
-
diff --git a/setup.py b/setup.py
deleted file mode 100644
index ae955ec..0000000
--- a/setup.py
+++ /dev/null
@@ -1,43 +0,0 @@
-# -*- coding: utf-8 -*-
-
-# Copyright (C) 2017-2023 Clémence Frioux & Arnaud Belcour - Inria Dyliss - Pleiade
-# This program is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU Lesser General Public License for more details.
-
-# You should have received a copy of the GNU Lesser General Public License
-# along with this program.  If not, see <http://www.gnu.org/licenses/>
-
-from setuptools import setup
-
-setup(
-    name             = 'MeneTools',
-    url              = 'https://github.com/cfrioux/MeneTools',
-    license          = 'GPLv3+',
-    description      = 'Metabolic Network Topology Analysis Tools',
-    long_description = 'Python Metabolic Network Topology Tools. Analyze the \
-topology of metabolic networks. Explore producibility, production paths and \
-needed initiation sources. \
-More information on usage and troubleshooting on Github: https://github.com/cfrioux/MeneTools',
-    author           = 'Clemence Frioux',
-    author_email     = 'clemence.frioux@inria.fr',
-    classifiers      =[
-                            'Programming Language :: Python :: 3.6',
-                            'Programming Language :: Python :: 3.6',
-                            'Programming Language :: Python :: 3.7',
-                            'Programming Language :: Python :: 3.8',
-                            'Operating System :: MacOS :: MacOS X',
-                            'Operating System :: Unix',
-                        ],
-    packages         = ['menetools'],
-    package_dir      = {'menetools' : 'menetools'},
-    package_data     = {'menetools' : ['encodings/*.lp']},
-    entry_points     = {'console_scripts': ['mene = menetools.__main__:main']},
-    install_requires = ['clyngor_with_clingo']
-)
diff --git a/toy/tiny_toy/seeds.xml b/toy/tiny_toy/seeds.xml
index 98c2b1d..e43a35e 100644
--- a/toy/tiny_toy/seeds.xml
+++ b/toy/tiny_toy/seeds.xml
@@ -16,6 +16,8 @@
 </listOfCompartments>
 <listOfSpecies>
   <species id="M_S_c" name="M_S_c" compartment="C_c"/>
+  <species id="M_foo_c" name="M_foo_c" compartment="C_c"/>
+  <species id="M_l_c" name="M_l_c" compartment="C_c"/>
 </listOfSpecies>
 <listOfReactions>
 </listOfReactions>


Test patch:
diff --git a/test/menetools_test.py b/test/menetools_test.py
index 2e4cd86..f05b938 100644
--- a/test/menetools_test.py
+++ b/test/menetools_test.py
@@ -66,21 +66,27 @@ def test_menecof_cli():
 
 def test_menescope():
     print("*** test menescope ***")
-    scope = 8
-    compounds = ['M_e_c', 'M_g_c', 'M_S_c', 'M_f_c', 'M_S_b', 'M_i_c', 'M_d_c', 'M_T3_c']
+    scope = 9
+    compounds = ['M_e_c', 'M_g_c', 'M_S_c', 'M_f_c', 'M_S_b', 'M_i_c', 'M_d_c', 'M_T3_c', 'M_l_c']
     seeds_produced = ['M_S_c']
+    missing_seeds = ['M_foo_c']
+    seeds_non_produced = ['M_l_c']
     results = run_menescope(DRAFT_PATH, SEED_PATH)
 
     assert set(results['scope']) == set(compounds)
     assert len(results['scope']) == scope
     assert set(results['produced_seeds']) == set(seeds_produced)
+    assert set(results['non_produced_seeds']) == set(seeds_non_produced)
+    assert set(results['absent_seeds']) == set(missing_seeds)
 
 
 def test_menescope_cli():
     print("*** test menescope cli ***")
-    scope = 8
-    compounds = ['M_e_c', 'M_g_c', 'M_S_c', 'M_f_c', 'M_S_b', 'M_i_c', 'M_d_c', 'M_T3_c']
+    scope = 9
+    compounds = ['M_e_c', 'M_g_c', 'M_S_c', 'M_f_c', 'M_S_b', 'M_i_c', 'M_d_c', 'M_T3_c', 'M_l_c']
     seeds_produced = ['M_S_c']
+    missing_seeds = ['M_foo_c']
+    seeds_non_produced = ['M_l_c']
 
     subprocess.call(['mene', 'scope', '-d', DRAFT_PATH,
                         '-s', SEED_PATH,  '--output', 'test.json'])
@@ -90,6 +96,8 @@ def test_menescope_cli():
     assert set(results['scope']) == set(compounds)
     assert len(results['scope']) == scope
     assert set(results['produced_seeds']) == set(seeds_produced)
+    assert set(results['non_produced_seeds']) == set(seeds_non_produced)
+    assert set(results['absent_seeds']) == set(missing_seeds)
     os.remove('test.json')