Skip to content

Commit

Permalink
Fixed the stuff to use setuptools better. Low-value stuff like insert…
Browse files Browse the repository at this point in the history
…ing versions into README.md and adding a file with metainfo has been removed. If one needs a version info or content of README, he should use pkg_resources. Releases are the versions

built from git tags. Development releases have git tags with "-dev" :) Also added some goodies, like .editorconfig and ignores.
  • Loading branch information
KOLANICH committed Dec 28, 2020
1 parent 615eee9 commit 3d22013
Show file tree
Hide file tree
Showing 9 changed files with 68 additions and 333 deletions.
8 changes: 8 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
root = true

[*.py]
charset = utf-8
indent_style = space
indent_size = 4
insert_final_newline = true
end_of_line = lf
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,5 @@
.cache/
*.egg-info/
*.pyc
/dist
/build
12 changes: 0 additions & 12 deletions dill/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,9 @@
# - https://github.com/uqfoundation/dill/blob/master/LICENSE

# get version numbers, license, and long description
try:
from .info import this_version as __version__
from .info import readme as __doc__, license as __license__
except ImportError:
msg = """First run 'python setup.py build' to build dill."""
raise ImportError(msg)

__author__ = 'Mike McKerns'

__doc__ = """
""" + __doc__

__license__ = """
""" + __license__

from ._dill import dump, dumps, load, loads, dump_session, load_session, \
Pickler, Unpickler, register, copy, pickle, pickles, check, \
HIGHEST_PROTOCOL, DEFAULT_PROTOCOL, PicklingError, UnpicklingError, \
Expand Down
Empty file added dill/tools/__init__.py
Empty file.
2 changes: 1 addition & 1 deletion scripts/get_objgraph → dill/tools/get_objgraph.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
load_types(pickleable=True,unpickleable=True)
from dill import objects

if __name__ == "__main__":
def get_objgraph():
import sys
if len(sys.argv) != 2:
print ("Please provide exactly one file or type name (e.g. 'IntType')")
Expand Down
2 changes: 1 addition & 1 deletion scripts/undill → dill/tools/undill.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
['hello', 'world']
"""

if __name__ == '__main__':
def undill():
import sys
import dill
for file in sys.argv[1:]:
Expand Down
5 changes: 5 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[build-system]
requires = ["setuptools>=44", "wheel", "setuptools_scm[toml]>=3.4.3"]
build-backend = "setuptools.build_meta"

[tool.setuptools_scm]
52 changes: 48 additions & 4 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -1,4 +1,48 @@
[egg_info]
tag_build = .dev0
#tag_svn_revision = yes
#tag_date = yes
[metadata]
name = dill
author = Mike McKerns
maintainer = Mike McKerns
license = BSD-3-Clause
license_file = LICENSE
description = serialize all of python
long_description = file: README.md
long_description_content_type = text/markdown
url = https://pypi.org/project/dill
homepage = https://github.com/uqfoundation/dill
download_url = https://github.com/uqfoundation/dill
classifiers =
Development Status :: 5 - Production/Stable
Intended Audience :: Developers
Intended Audience :: Science/Research
License :: OSI Approved :: BSD License
Programming Language :: Python :: 2
Programming Language :: Python :: 2.5
Programming Language :: Python :: 2.6
Programming Language :: Python :: 2.7
Programming Language :: Python :: 3
Programming Language :: Python :: 3.1
Programming Language :: Python :: 3.2
Programming Language :: Python :: 3.3
Programming Language :: Python :: 3.4
Programming Language :: Python :: 3.5
Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Topic :: Scientific/Engineering
Topic :: Software Development
platforms = Linux, Windows, Mac

[options]
packages = dill, dill.tools
zip_safe = False
python_requires = >=2.5, !=3.0.*
setup_requires = setuptools>=44; wheel; setuptools_scm[toml]>=3.4.3

[options.extras_require]
readline = pyreadline>=1.7.1
graph = objgraph>=1.7.2

[options.entry_points]
console_scripts =
undill = dill.tools.undill:undill
get_objgraph = dill.tools.get_objgraph:get_objgraph
Loading

0 comments on commit 3d22013

Please sign in to comment.