Skip to content

Commit

Permalink
Anti-Bloat: Added handling for some packages used by newer "torch"
Browse files Browse the repository at this point in the history
* This covers "npmath" and "sympy"
  • Loading branch information
kayhayen committed Apr 24, 2023
1 parent e35ca01 commit ae92468
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions nuitka/plugins/standard/standard.nuitka-package.config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1129,6 +1129,14 @@
patterns:
- '*.pem'

- module-name: 'mpmath'
anti-bloat:
- description: 'remove pytest reference'
change_function:
'doctests': 'un-callable'
'runtests': 'un-callable'
when: 'not use_pytest'

- module-name: 'nacl._sodium'
implicit-imports:
- depends:
Expand Down Expand Up @@ -1688,6 +1696,7 @@
change_function:
'test_pandas_friendly_reshape': 'un-callable'
'test_wide_dtype_for_and_widen': 'un-callable'
when: 'not use_pytest'

- module-name: 'pendulum'
data-files:
Expand Down Expand Up @@ -3299,6 +3308,26 @@
dirs:
- 'vendor'

- module-name: 'sympy.interactive.printing'
anti-bloat:
- description: 'remove IPython reference'
replacements_plain:
'import IPython': 'raise ImportError'
'from IPython import get_ipython': 'raise ImportError'
'from IPython.terminal.interactiveshell import TerminalInteractiveShell': 'raise ImportError'
'from IPython.frontend.terminal.interactiveshell import TerminalInteractiveShell': 'raise ImportError'
'from IPython.lib.latextools import latex_to_png': 'raise ImportError'
'from IPython.core.interactiveshell import InteractiveShell': 'raise ImportError'
when: 'not use_ipython'

- module-name: 'sympy.interactive.session'
anti-bloat:
- description: 'remove IPython reference'
replacements_plain:
'import IPython': 'raise ImportError'
'from IPython import get_ipython': 'raise ImportError'
when: 'not use_ipython'

- module-name: 'tables'
anti-bloat:
- description: 'remove tables.tests usage'
Expand Down

0 comments on commit ae92468

Please sign in to comment.