Skip to content

Commit 4c05ce5

Browse files
committed
DM-8007 repackage firefly_client to make pip-installable
1 parent cacbc9e commit 4c05ce5

File tree

8 files changed

+76
-0
lines changed

8 files changed

+76
-0
lines changed

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,3 +45,7 @@ node_modules/
4545
.classpath
4646
.project
4747
.settings/
48+
49+
# ignore build and dist directories made by pip
50+
src/firefly/python/display/dist
51+
src/firefly/python/display/firefly_client.egg-info
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
Copyright © <2014>, California Institute of Technology, developed for the
2+
Spitzer Science Center and the NASA/IPAC Infrared Science Archive (IRSA) with
3+
support from NASA, and for Large Synoptic Survey Telescope (LSST) with
4+
support from NSF.
5+
6+
All rights reserved.
7+
Redistribution and use in source and binary forms, with or without
8+
modification, are permitted provided that the following conditions are met:
9+
10+
* Redistributions of source code must retain the above copyright notice,
11+
this list of conditions and the following disclaimer.
12+
* Redistributions in binary form must reproduce the above copyright notice,
13+
this list of conditions and the following disclaimer in the documentation
14+
and/or other materials provided with the distribution.
15+
* Neither the name of the California Institute of Technology (Caltech) nor
16+
the names of its contributors may be used to endorse or promote products
17+
derived from this software without specific prior written permission.
18+
19+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20+
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21+
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
23+
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24+
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
25+
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
26+
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
27+
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

src/firefly/python/display/README.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# firefly_client
2+
3+
Python API for Firefly, IPAC's Advanced Astronomy Web UI Framework
4+
5+
## Usage
6+
7+
The client must be connected to a Firefly server.
8+
9+
```
10+
from firefly_client import FireflyClient
11+
fc = FireflyClient('localhost:8080', 'mychannel')
12+
```
13+
14+
A FITS image may be uploaded and displayed.
15+
16+
```
17+
fval = fc.upload_file('image.fits')
18+
fc.show_fits(fval, 'myimage')
19+
20+

src/firefly/python/display/__init__.py

Whitespace-only changes.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
from .firefly_client import FireflyClient

src/firefly/python/display/setup.cfg

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[bdist_wheel]
2+
universal=1

src/firefly/python/display/setup.py

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Licensed under a 3-clause BSD style license - see License.txt
2+
3+
from setuptools import setup
4+
5+
setup(
6+
name='firefly_client',
7+
version='1.0.0.b2',
8+
description='Python API for Firefly',
9+
author='IPAC LSST SUIT',
10+
license='BSD',
11+
url='http://github.com/Caltech-IPAC/firefly',
12+
packages = ['firefly_client'],
13+
install_requires=['ws4py', 'future'],
14+
classifiers=[
15+
'Programming Language :: Python :: 2',
16+
'Programming Language :: Python :: 2.7',
17+
'Programming Language :: Python :: 3',
18+
'Programming Language :: Python :: 3.5',
19+
]
20+
)
21+

0 commit comments

Comments
 (0)