-
Notifications
You must be signed in to change notification settings - Fork 23
Build and dependency updates #73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
By prefixing the build command with PYTHONNOUSERSITE=1 we ignore user site packages, ensuring modules are properly installed into the relocatable framework.
The HTTP session was being initialized at module import time, which required all HTTP-related dependencies to be available before plotdevice could be imported. This caused build failures since the dependencies weren't yet installed during the build process. Changes: - Made HTTP session initialization lazy via get_http_session() - Only import HTTP dependencies when actually making requests - Added better error message if dependencies are missing - Updated read() function to use lazy initialization This allows plotdevice to be imported and built without having HTTP dependencies pre-installed, fixing the circular dependency issue during installation.
Added missing dependency that was causing build failures: - filelock: Required by cachecontrol for file caching
Updated the clean command to remove additional build artifacts: - Added .eggs directory - Added *.egg files - Added __pycache__ directories - Added .pyc files - Added local development virtualenv Also modified CleanCommand to: - Added --dist flag to CleanCommand for dist cleaning - Kept DistCleanCommand as separate command for backward compatibility
Added ability to bypass pip's cache when building the app bundle: - Added --no-cache flag to BuildAppCommand in setup.py - Modified Makefile to conditionally set PIP_NO_CACHE_DIR based on environment - Allows clean builds with fresh package downloads via `python setup.py app --no-cache`
- now uses `filelock` rather than the deprecated `lockfile`
- satisfies a deprecation warning from setuptools
samizdatco
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks so much for these new setup.py features & fixes! I made a couple tweaks to the dependency lists to a) keep Python.framework and plotdevice using the same (old) version of PyObjC, and b) clear up cachecontrol's lockfile/filelock support.
I also dropped the license string from the CLASSIFIERS list (since that's apparently been deprecated?) and fixed the CI tests by manually installing setuptools now that it's no longer present by default.
Would you mind doing a test build on your end to confirm that I didn't break any of your nice work in the process?
|
Confirming that the build works for me! Thanks for clearing up the dependencies. |
This PR makes some small changes to the build process and dependencies:
python setup.py appAdded filelock to package dependencies (needed for CacheControl FileCache)
Lazy initialisation for URL handling in readers.py
I've tested: