Releases: EVEprosper/ProsperCommon
PyPI Release
Unleashing ProsperCommon on the world. Support us on PyPI at https://pypi.python.org/pypi/ProsperCommon
Features:
- Fixes #10
- Travis-CI integration
- Automatic release to PyPI thanks to Travis PyPI integration
- Fixes to README for a more beautiful front-page
ProsperConfig
now takes environment variables into account (#10)
Notes:
- Removed CREST stuff from project (to be reimplemented elsewhere)
test/
path moved to/tests
to be more in line with project standards- No longer pushing to GemFury
Prettier webhook messaging
Added ability to split out message/traceback when pushing to webhook. Now Slack/Discord handlers should appropriately use triple-backtick notation for messaging.
Example:
[ERROR:logging_test.py--test_discord_logger:311]
validate exc_info
Traceback (most recent call last):
File "~/source/ProsperCommon/test/logging_test.py", line 309, in test_discord_logger
test_dict['butts']
NameError: name 'test_dict' is not defined
The formatting behavior is not as granular with Slack. Reduced messaging complexity, but hardcoded attachments
formatting
Fixes #11
Other Notes:
- Removed
prosper/crest
to be implemented in another library later - Removed
prosper/common/prosper_graphing.py
because untested and unsupported - Cleaned up
setup.py
to reduce noisy features - Updated
README.md
to make a more beautiful landing page - Added starting hooks for travis-ci
adding __iter__ to ProsperLogger
Adds __iter__
magic-method to ProsperLogger. Used as Flask helper to load handlers into app.logger.handler()
calls in Flask
Adding Slack Webhook Logging Handler
Similar to existing Discord logger, we have added support for Slack webhook alerts too.
Please see docs for specifics
- added
slack_webhook
to[LOGGING]
config section - added custom
HackySlackHandler
logging handler with slack-specific formatting/behavior - added tests for new Slack framework
Note: Slack handlers are not designed to generate notifications or @users. To get direct alerts, consider adding multiple instances of configure_slack_logger()
to your log builder with direct messaging enabled at the webhook level
Pytest Coverage improvements
TYVM @JornVernee for helping close #6
- Added
_configure_common
for easier coverage of generic handle-making functions - Improved
DiscordWebhook
setup class with more robust regex parsing - Improved pytest coverage for
prosper_logging
to 95%
Updating test infrastructure
- Adding
mkdirs()
call beforetest_cleanup_log_directory()
to avoid virgin run issues - reducing pendency on library requirements
requests
2.12.xpytest
3.0.xpytest_cov
2.4.x
- Setting dependencies as minimums, not strict
- adding
__project_name__
to setup.py to make profile more generic for code recycling
Changing logformat enumeration
Changing ReportingFormats to a proper Enum
class.
TODO: add enum->str translation on format overrides
Also added pytest_cov
to report test coverage
Fixing imports/globals
- Fixed hanging key in tracked config
- added back
DEFAULT_LOGGER
into prosper_logger (so all scripts can pull same logger
Adding get() method to ProsperConfig
Adding config.get()
to replicate ConfigParser
behavior.
Added MANIFEST.in file for gemfury
Gemfury issue with data_files
Removing data_files
from setup.py
. Using pip.conf
override for --extra-index-url
causes issues on Windows when installing to virtualenv.