Skip to content

Commit 557f17d

Browse files
committed
Temporarily removes pathway organizer related entities for the merge into main
1 parent 8b90639 commit 557f17d

12 files changed

Lines changed: 3 additions & 468 deletions

dev/test_main.py

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
import kegg_pull.rest_cli as r_cli
1010
import kegg_pull.pull_cli as p_cli
1111
import kegg_pull.map_cli as map_cli
12-
import kegg_pull.pathway_organizer_cli as po_cli
1312
import dev.utils as u
1413

1514

@@ -20,7 +19,7 @@ def test_help(mocker):
2019
delimiter: str = '-'*80
2120
expected_print_call_args = [
2221
(m.__doc__,), (delimiter,), (p_cli.__doc__,), (delimiter,), (ei_cli.__doc__,), (delimiter,), (map_cli.__doc__,),
23-
(delimiter,), (po_cli.__doc__,), (delimiter,), (r_cli.__doc__,)]
22+
(delimiter,), (r_cli.__doc__,)]
2423
u.assert_call_args(function_mock=print_mock, expected_call_args_list=expected_print_call_args, do_kwargs=False)
2524
for help_arg in (['--help'], ['-h'], []):
2625
help_args = ['kegg_pull']
@@ -199,10 +198,3 @@ def test_map(mocker, print_output: bool, args: list, stdin_mock_str: str, expect
199198
json_output=True)
200199
if stdin_mock:
201200
stdin_mock.assert_called_once_with()
202-
203-
204-
def test_pathway_organizer(mocker, print_output: bool):
205-
args = ['kegg_pull', 'pathway-organizer', '--tln=Metabolism', '--fn=Global and overview maps']
206-
_test_output(
207-
mocker=mocker, args=args, expected_output='dev/test_data/pathway-organizer/metabolic-pathways.json',
208-
print_output=print_output, json_output=True)

dev/test_pathway_organizer.py

Lines changed: 0 additions & 100 deletions
This file was deleted.

dev/test_pathway_organizer_cli.py

Lines changed: 0 additions & 58 deletions
This file was deleted.

dev/test_utils.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
import dev.utils as u
66
import kegg_pull.pull as p
77
import kegg_pull.rest as r
8-
import kegg_pull.pathway_organizer as po
98

109

1110
@pt.mark.parametrize('comma_separated_list', [',,', ',', ''])
@@ -34,7 +33,7 @@ def test_get_range_values_exception():
3433

3534

3635
@pt.mark.parametrize(
37-
'NonInstantiable,kwargs', [(p.PullResult, {}), (r.KEGGresponse, {'status': None, 'kegg_url': None}), (po.PathwayOrganizer, {})])
36+
'NonInstantiable,kwargs', [(p.PullResult, {}), (r.KEGGresponse, {'status': None, 'kegg_url': None})])
3837
def test_non_instantiable(NonInstantiable: type, kwargs: dict):
3938
expected_error_message = f'The class "{NonInstantiable.__name__}" cannot be instantiated outside of its module.'
4039
with pt.raises(RuntimeError) as error:

docs/api.rst

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,6 @@ API
1616
:members:
1717
:undoc-members:
1818

19-
.. automodule:: kegg_pull.pathway_organizer
20-
:members:
21-
:undoc-members:
22-
2319
.. automodule:: kegg_pull.rest
2420
:members:
2521
:undoc-members:

docs/cli.rst

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -76,15 +76,6 @@ If the ``--unsuccessful-threshold`` option is set and surpassed, an ``aborted-pu
7676
:end-before: """
7777
:language: none
7878

79-
.. include:: ../src/kegg_pull/pathway_organizer.py
80-
:start-after: """
81-
:end-before: """
82-
83-
.. literalinclude:: ../src/kegg_pull/pathway_organizer_cli.py
84-
:start-at: Usage:
85-
:end-before: """
86-
:language: none
87-
8879
.. include:: ../src/kegg_pull/rest.py
8980
:start-after: """
9081
:end-before: """

docs/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def setup(app):
4343

4444
templates_path = ['_templates']
4545
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store']
46-
46+
latex_elements = {'preamble': r'\usepackage{pmboxdraw}'}
4747

4848
# -- Options for HTML output -------------------------------------------------
4949
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output

docs/tutorial.rst

Lines changed: 0 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -320,24 +320,6 @@ operation or “conv” operation into dictionaries usable in python code.
320320
{'cpd:C00001': {'pubchem:3303'}, 'cpd:C00002': {'pubchem:3304'}}
321321
322322
323-
Pathway Organizer
324-
~~~~~~~~~~~~~~~~~
325-
326-
The ``pathway_organizer`` module flattens a brite hierarchy into a
327-
mapping of the IDs of its nodes to information about those nodes.
328-
329-
.. code:: python3
330-
331-
import kegg_pull.pathway_organizer as po
332-
pathway_org = po.PathwayOrganizer.load_from_kegg()
333-
print(pathway_org.hierarchy_nodes['Metabolism'])
334-
335-
336-
.. parsed-literal::
337-
338-
{'name': 'Metabolism', 'level': 1, 'parent': None, 'children': ['Amino acid metabolism', 'Biosynthesis of other secondary metabolites', 'Carbohydrate metabolism', 'Chemical structure transformation maps', 'Energy metabolism', 'Global and overview maps', 'Glycan biosynthesis and metabolism', 'Lipid metabolism', 'Metabolism of cofactors and vitamins', 'Metabolism of other amino acids', 'Metabolism of terpenoids and polyketides', 'Nucleotide metabolism', 'Xenobiotics biodegradation and metabolism'], 'entry_id': None}
339-
340-
341323
Rest API
342324
~~~~~~~~
343325

@@ -703,29 +685,6 @@ map
703685
"cpd:C00084",
704686
705687
706-
pathway-organizer
707-
~~~~~~~~~~~~~~~~~
708-
709-
.. code:: none
710-
711-
% kegg_pull pathway-organizer --tln=Metabolism --fn="Global and overview maps,Carbohydrate metabolism" --output=hierarchy-nodes.json
712-
% head hierarchy-nodes.json
713-
714-
715-
.. parsed-literal::
716-
717-
{
718-
"path:map00190": {
719-
"name": "00190 Oxidative phosphorylation",
720-
"level": 3,
721-
"parent": "Energy metabolism",
722-
"children": null,
723-
"entry_id": "path:map00190"
724-
},
725-
"path:map00195": {
726-
"name": "00195 Photosynthesis",
727-
728-
729688
rest
730689
~~~~
731690

src/kegg_pull/__init__.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@
77
88
``map``
99
10-
``pathway_organizer``
11-
1210
``rest``
1311
1412
``kegg_url``

src/kegg_pull/__main__.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,13 @@
66
kegg_pull pull ... Pull, separate, and store an arbitrary number of KEGG entries to the local file system.
77
kegg_pull entry-ids ... Obtain a list of KEGG entry IDs.
88
kegg_pull map ... Obtain a mapping of entry IDs (KEGG or outside databases) to the IDs of related entries.
9-
kegg_pull pathway-organizer ... Creates a flattened version of a pathways Brite hierarchy.
109
kegg_pull rest ... Executes one of the KEGG REST API operations.
1110
"""
1211
import sys
1312
from . import __version__
1413
from . import pull_cli as p_cli
1514
from . import entry_ids_cli as ei_cli
1615
from . import map_cli as map_cli
17-
from . import pathway_organizer_cli as po_cli
1816
from . import rest_cli as r_cli
1917

2018

@@ -26,8 +24,6 @@ def main() -> None:
2624
ei_cli.main()
2725
elif first_arg == 'map':
2826
map_cli.main()
29-
elif first_arg == 'pathway-organizer':
30-
po_cli.main()
3127
elif first_arg == 'rest':
3228
r_cli.main()
3329
elif first_arg == '--full-help':
@@ -40,8 +36,6 @@ def main() -> None:
4036
print(separator)
4137
print(map_cli.__doc__)
4238
print(separator)
43-
print(po_cli.__doc__)
44-
print(separator)
4539
print(r_cli.__doc__)
4640
elif first_arg == '--version' or first_arg == '-v':
4741
print(__version__)

0 commit comments

Comments
 (0)