-
Notifications
You must be signed in to change notification settings - Fork 103
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
Moves msgs into pypit/__init__.py #310
Merged
Changes from 37 commits
Commits
Show all changes
39 commits
Select commit
Hold shift + click to select a range
65f1a9e
test commit
kbwestfall ea299d6
removed cython functions touched by pypit_test
kbwestfall 835fbb9
minor comments
kbwestfall 8a2d6c5
removing asserts and print statements for cython substitutions
kbwestfall 11c83a8
remove print statements in arextract.py
kbwestfall 2080274
remove print statements in arproc.py
kbwestfall 807c840
cleaned up filter.py
kbwestfall b0a121e
move msgs to __init__.py; some restructuring and doc changes
kbwestfall 9e1170a
Merge branch 'initmsgs' into kbwdev
kbwestfall 70efe2a
resolve conflicts with master
kbwestfall 6c59494
resolve conflict
kbwestfall 78d1862
lingering armsgs code
kbwestfall 4e0620b
minor debugging; remove ginga imports from ardebug.py
kbwestfall 959d115
try with version_check defined in setup.py
kbwestfall e9e686c
setup.py bug
kbwestfall af68663
bug in setup.py
kbwestfall 2224459
rewrite setup.py
kbwestfall 1263449
add requirements.txt and edited CHANGES.rst
kbwestfall 14c5477
remove import of unicode_literals in setup.py
kbwestfall c03dd79
add call to cythonize
kbwestfall e291b98
try without cythonize, but with cython as a setup requirement
kbwestfall bfb9b6c
attempting to fix imports
kbwestfall c44aa56
bug fix
kbwestfall f91a2a4
remove arqa import from init
kbwestfall 1d7e5c2
reorganize imports; move most qa plotting routines to relevant module…
kbwestfall 655dd2f
Merge branch 'impmess' into kbwdev
kbwestfall a7e4a92
add arclines install
profxj 60f749e
move requirements; add check
profxj 00c0e5d
test fix -- remove chk from setup.py
profxj 2824025
remove Ginga as requirement; arclines branch
profxj 9126794
remove Sphinx (docs only)
profxj b83a7a5
refactor to remove all of PYPIT
profxj 3550314
refactor with arclines
profxj 11f1d9d
remove html; turn on HTML from msgs; archeck fix
profxj 26d9916
linetools test..
profxj 547d392
still fussing..
profxj 4333401
remove from for arclines..
profxj 0f63cd6
final edits before push
kbwestfall ad9b2e1
only import set_trace from pdb; remove pyputils import from ginga
kbwestfall File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
""" | ||
pypit package initialization. | ||
|
||
The current main purpose of this is to provide package-level globals | ||
that can be imported by submodules. | ||
""" | ||
|
||
from __future__ import absolute_import | ||
from __future__ import division | ||
from __future__ import print_function | ||
from __future__ import unicode_literals | ||
|
||
# Imports for signal and log handling | ||
import sys | ||
import signal | ||
import warnings | ||
|
||
# Set version | ||
__version__ = '0.8.0.dev0' | ||
# TODO: Do we need this? A release should be tied to a date, and the | ||
# date information could be put in the CHANGES.rst | ||
__last_updated__ = '23Mar2018' | ||
|
||
# Import and instantiate the logger | ||
from pypit import armsgs | ||
msgs = armsgs.Messages() | ||
|
||
# Import the close_qa method so that it can be called when a hard stop | ||
# is requested by the user | ||
# TODO: Is this necessary? As far as I can tell, close_qa() doesn't | ||
# actually close any already opened qa files | ||
|
||
# TODO: Causes circular imports | ||
# from pypit.arqa import close_qa | ||
|
||
# Send all signals to messages to be dealt with (i.e. someone hits ctrl+c) | ||
def signal_handler(signalnum, handler): | ||
""" | ||
Handle signals sent by the keyboard during code execution | ||
""" | ||
if signalnum == 2: | ||
msgs.info('Ctrl+C was pressed. Ending processes...') | ||
# close_qa(msgs.pypit_file) | ||
msgs.close() | ||
sys.exit() | ||
|
||
signal.signal(signal.SIGINT, signal_handler) | ||
|
||
# Ignore all warnings given by python | ||
warnings.resetwarnings() | ||
warnings.simplefilter('ignore') | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Add:
-- Updates archeck
-- Loads NIST arclines from arclines instead of PYPIT