Ejemplo n.º 1
0
def hook(hook_api):
    packages = ['astor']
    for package in packages:
        datas, binaries, hiddenimports = collect_all(package)
        hook_api.add_datas(datas)
        hook_api.add_binaries(binaries)
        hook_api.add_imports(*hiddenimports)
Ejemplo n.º 2
0
def hook(hook_api):
    packages = ['flask', 'flask_compress', 'flask_caching']
    for package in packages:
        datas, binaries, hiddenimports = collect_all(package)
        hook_api.add_datas(datas)
        hook_api.add_binaries(binaries)
        hook_api.add_imports(*hiddenimports)
def hook(hook_api):
    packages = ['tensorflow', 'tensorflow_core', 'astor', 'hyperlpr']
    for package in packages:
        datas, binaries, hiddenimports = collect_all(package)
        hook_api.add_datas(datas)
        hook_api.add_binaries(binaries)
        hook_api.add_imports(*hiddenimports)
Ejemplo n.º 4
0
def hook(hook_api):
    packages = [
        'tensorflow',
        'astor',
        'sklearn',
        'sklearn.utils._cython_blas',
        'spleeter'
    ]
    for package in packages:
        datas, binaries, hiddenimports = collect_all(package)
        hook_api.add_datas(datas)
        hook_api.add_binaries(binaries)
        hook_api.add_imports(*hiddenimports)
Ejemplo n.º 5
0
# -*- coding: utf-8 -*-
# This software is a part of the A.O.D apprepo project
# Copyright 2020 Alex Woroschilow ([email protected])
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# 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 General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
import sys
import glob
import os
from PyInstaller import log as logging
from PyInstaller.utils.hooks import (collect_all, collect_submodules,
                                     collect_data_files,
                                     get_module_file_attribute,
                                     get_module_attribute)

logger = logging.getLogger(__name__)

datas, binaries, hiddenimports = collect_all('adminplus')
Ejemplo n.º 6
0
# HOOK FILE FOR SPACY
from PyInstaller.utils.hooks import collect_all
import spacy

# ----------------------------- SPACY -----------------------------
data = collect_all('spacy')

datas = data[0]
datas.append((spacy.util.get_data_path(), 'spacy/data'))

binaries = data[1]
hiddenimports = data[2]

# ----------------------------- THINC -----------------------------
data = collect_all('thinc')

datas += data[0]
binaries += data[1]
hiddenimports += data[2]

# ----------------------------- CYMEM -----------------------------
data = collect_all('cymem')

datas += data[0]
binaries += data[1]
hiddenimports += data[2]

# ----------------------------- PRESHED -----------------------------
data = collect_all('preshed')

datas += data[0]
from PyInstaller.utils.hooks import collect_all

# ----------------------------- ja_ginza -----------------------------
data = collect_all('ja_ginza')

datas = data[0]
binaries = data[1]
hiddenimports = data[2]
Ejemplo n.º 8
0
from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('missionbio.mosaic')
Ejemplo n.º 9
0
# from PyInstaller.utils.hooks import copy_metadata

# datas = copy_metadata('torchaudio')
from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('torchaudio')
Ejemplo n.º 10
0
from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('pynndescent')
from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('dash_core_components')
Ejemplo n.º 12
0
from PyInstaller.utils.hooks import collect_submodules, collect_data_files, exec_statement, collect_all


datas, binaries, hiddenimports = collect_all('scipy', include_py_files=True)

print("\n\nDATAS (scipy): ")
print(len(datas))


print("\n\nBINARIES (scipy): ")
print(len(binaries))

print("\n\nHIDDENIMPORTS (scipy): ")
print(len(hiddenimports))

print("\n\n")

# https://stackoverflow.com/questions/49085970/no-such-file-or-directory-error-using-pyinstaller-and-scrapy/49092020#49092020
# hooks/hook-dash_core_components.py

from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('dash_bootstrap_components')
Ejemplo n.º 14
0
from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('plotly')
Ejemplo n.º 15
0
from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('tzlocal')
Ejemplo n.º 16
0
#-----------------------------------------------------------------------------
# Copyright (c) 2015-2018, PyInstaller Development Team.
#
# Distributed under the terms of the GNU General Public License with exception
# for distributing bootloader.
#
# The full license is in the file COPYING.txt, distributed with this software.
#-----------------------------------------------------------------------------

from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('gevent')
Ejemplo n.º 17
0
from PyInstaller.utils.hooks import collect_all

# ----------------------------- ginza -----------------------------
data = collect_all('ginza')

datas = data[0]
binaries = data[1]
hiddenimports = data[2]
Ejemplo n.º 18
0
def hook(hook_api):
    for pkg in ['pip', 'setuptools', 'distutils', 'pkg_resources']:
        datas, binaries, hiddenimports = collect_all(pkg)
        hook_api.add_datas(datas)
        hook_api.add_binaries(binaries)
        hook_api.add_imports(*hiddenimports)
Ejemplo n.º 19
0
# -----------------------------------------------------------------------------
# Copyright (c) 2015-2019, PyInstaller Development Team.
#
# Distributed under the terms of the GNU General Public License with exception
# for distributing bootloader.
#
# The full license is in the file COPYING.txt, distributed with this software.
# -----------------------------------------------------------------------------

# Hook for textdistance: https://pypi.org/project/textdistance/4.1.3/

from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('textdistance')
Ejemplo n.º 20
0
from PyInstaller.utils.hooks import collect_all

# ----------------------------- mlask -----------------------------
data = collect_all('mlask')

datas = data[0]
binaries = data[1]
hiddenimports = data[2]
Ejemplo n.º 21
0
#-----------------------------------------------------------------------------
# Copyright (c) 2015-2019, PyInstaller Development Team.
#
# Distributed under the terms of the GNU General Public License with exception
# for distributing bootloader.
#
# The full license is in the file COPYING.txt, distributed with this software.
#-----------------------------------------------------------------------------

from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('gevent')
Ejemplo n.º 22
0
from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all("xgboost")
Ejemplo n.º 23
0
#-----------------------------------------------------------------------------
# Copyright (c) 2015-2021, PyInstaller Development Team.
#
# Distributed under the terms of the GNU General Public License (version 2
# or later) with exception for distributing the bootloader.
#
# The full license is in the file COPYING.txt, distributed with this software.
#
# SPDX-License-Identifier: (GPL-2.0-or-later WITH Bootloader-exception)
#-----------------------------------------------------------------------------

from PyInstaller.utils.hooks import collect_all, copy_metadata

excludedimports = ["gevent.testing", "gevent.tests"]

datas, binaries, hiddenimports = collect_all(
    'gevent',
    filter_submodules=lambda name:
    ("gevent.testing" not in name or "gevent.tests" not in name),
    include_py_files=False,
    exclude_datas=["**/tests"])

# Gevent uses ``pkg_resources.require("...")`` which means that all its
# dependencies must also have their metadata.
datas += copy_metadata('gevent', recursive=True)
Ejemplo n.º 24
0
from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('sacremoses')
# from PyInstaller.utils.hooks import copy_metadata

# datas = copy_metadata('sacremoses')
Ejemplo n.º 25
0
# Tested with django 1.8.


import sys
import glob
import os
from PyInstaller import log as logging
from PyInstaller.utils.hooks import (
    django_find_root_dir, django_dottedstring_imports, collect_all,
    collect_submodules, collect_data_files, get_module_file_attribute,
    get_module_attribute)


logger = logging.getLogger(__name__)

datas, binaries, hiddenimports = collect_all('django')


root_dir = django_find_root_dir()
if root_dir:
    logger.info('Django root directory %s', root_dir)
    # Include imports from the mysite.settings.py module.
    settings_py_imports = django_dottedstring_imports(root_dir)
    # Include all submodules of all imports detected in mysite.settings.py.
    for submod in settings_py_imports:
        hiddenimports.append(submod)
        hiddenimports += collect_submodules(submod)
    # Include main django modules - settings.py, urls.py, wsgi.py.
    # Without them the django server won't run.
    package_name = os.path.basename(root_dir)
    hiddenimports += [
Ejemplo n.º 26
0
# Tested with django 1.8.


import sys
import glob
import os
from PyInstaller import log as logging
from PyInstaller.utils.hooks import (
    django_find_root_dir, django_dottedstring_imports, collect_all,
    collect_submodules, collect_data_files, get_module_file_attribute,
    get_module_attribute)


logger = logging.getLogger(__name__)

datas, binaries, hiddenimports = collect_all('django')


root_dir = django_find_root_dir()
if root_dir:
    logger.info('Django root directory %s', root_dir)
    # Include imports from the mysite.settings.py module.
    settings_py_imports = django_dottedstring_imports(root_dir)
    # Include all submodules of all imports detected in mysite.settings.py.
    for submod in settings_py_imports:
        hiddenimports.append(submod)
        hiddenimports += collect_submodules(submod)
    # Include main django modules - settings.py, urls.py, wsgi.py.
    # Without them the django server won't run.
    package_name = os.path.basename(root_dir)
    hiddenimports += [
Ejemplo n.º 27
0
from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('regex')
# from PyInstaller.utils.hooks import copy_metadata

# datas = copy_metadata('regex')
Ejemplo n.º 28
0
# Copyright 2020 Alex Woroschilow ([email protected])
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# 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 General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
import sys
import glob
import os
from PyInstaller import log as logging
from PyInstaller.utils.hooks import (collect_all, collect_submodules,
                                     collect_data_files,
                                     get_module_file_attribute,
                                     get_module_attribute)

logger = logging.getLogger(__name__)

datas, binaries, hiddenimports = collect_all('chunked_upload')
# logger.info('Django root directory %s', root_dir)
# for test in hiddenimports:
#     print(test)
Ejemplo n.º 29
0
from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('pycountry')
Ejemplo n.º 30
0
from PyInstaller.utils.hooks import collect_all

datas, binaries, hiddenimports = collect_all('altair')
Ejemplo n.º 31
0
from PyInstaller.utils.hooks import collect_data_files, collect_all

datas, binaries, hiddenimports = collect_all('ScoutSuite')
datas.extend(collect_data_files('policyuniverse'))
hiddenimports.append('configparser')
# Copyright 2020 Alex Woroschilow ([email protected])
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# 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 General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
import sys
import glob
import os
from PyInstaller import log as logging
from PyInstaller.utils.hooks import (collect_all, collect_submodules,
                                     collect_data_files,
                                     get_module_file_attribute,
                                     get_module_attribute)

logger = logging.getLogger(__name__)

datas, binaries, hiddenimports = collect_all('rest_framework')
# logger.info('Django root directory %s', root_dir)
# for test in hiddenimports:
#     print(test)