Skip to content

Commit

Permalink
Ditching __config__.py to see if it works out.
Browse files Browse the repository at this point in the history
This is an experiment to see if "source mode" or "dev mode" just
uses the "right" `bezier.dll` (i.e. assuming it has been
installed) and use of `machomachomangler` would be isolated to the
creation of wheels.
  • Loading branch information
dhermes committed Jan 23, 2020
1 parent 6d59fc7 commit 40ecf93
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 227 deletions.
4 changes: 3 additions & 1 deletion .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ environment:

# See: https://www.appveyor.com/docs/installed-software/#python

- NOX_SESSION: "win_wat"
- NOX_SESSION: "unit-3.6-32"
- NOX_SESSION: "win_wat"
- NOX_SESSION: "unit-3.6"
- NOX_SESSION: "unit-3.7-32"
- NOX_SESSION: "unit-3.7"
Expand Down Expand Up @@ -62,6 +62,8 @@ install:
}
$env:Path += ";$MINGW"
- ps: $env:BEZIER_DLL_PATH = "C:\projects\bezier\.nox\libbezier-debug\usr\bin"

# Packaging requirements
- python -m pip install --upgrade "pip !=20.0,!=20.0.1" setuptools
- python -m pip install --upgrade wheel
Expand Down
6 changes: 5 additions & 1 deletion noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,11 @@ def unit(session):
install_bezier(session, debug=True)
# Run pytest against the unit tests.
run_args = ["pytest"] + session.posargs + [get_path("tests", "unit")]
session.run(*run_args)
env = {}
bezier_dll_path = os.environ.get("BEZIER_DLL_PATH")
if bezier_dll_path is not None:
env["PATH"] = bezier_dll_path
session.run(*run_args, env=env)


@nox.session(py=DEFAULT_INTERPRETER)
Expand Down
95 changes: 0 additions & 95 deletions src/python/bezier/__config__.py

This file was deleted.

4 changes: 0 additions & 4 deletions src/python/bezier/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@
.. autoclass:: Surface
"""

# NOTE: ``__config__`` **must** be the first import because it (may)
# modify the search path used to locate shared libraries.
from bezier import __config__
from bezier._legacy import Surface
from bezier._py_helpers import UnsupportedDegree
from bezier.curve import Curve
Expand All @@ -41,7 +38,6 @@

_HAS_SPEEDUP = True
except ImportError as exc: # pragma: NO COVER
__config__.handle_import_error(exc, "_speedup")
_HAS_SPEEDUP = False
# NOTE: The ``__version__`` and ``__author__`` are hard-coded here, rather
# than using ``pkg_resources.get_distribution("bezier").version``
Expand Down
126 changes: 0 additions & 126 deletions tests/unit/test___config__.py

This file was deleted.

0 comments on commit 40ecf93

Please sign in to comment.