astropy / astropy/pyvo

SAMPHubServer should raise an exception if another hub is already running

Open
#737 4 comments 0 reactions 0 assignees View on GitHub
bug component: samp
Dominant language
Python
Stars
88
Forks
64
Avg merge
38m
Merged PRs (30d)
1

Description

Update: This issue was moved to pyvo following https://github.com/astropy/pyvo/pull/729

---

At the moment the current behavior could be considered a bug:

```python
In [8]: from astropy.samp import SAMPHubServer

In [9]: hub = SAMPHubServer()

In [10]: hub.start()
INFO: Hub set to run with Web Profile support enabled. [astropy.samp.hub]
/Users/tom/Dropbox/Code/Astropy/astropy/astropy/samp/lockfile_helpers.py:114: SAMPWarning: Another SAMP Hub is already running. Start-up process aborted.
"aborted.", SAMPWarning)
INFO: Hub started [astropy.samp.hub]

In [11]: hub.is_running
Out[11]: True
```

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at the SAMPHubServer entry point and its start() behavior, using the example in the issue to reproduce the case where another hub is already running. Done means startup raises an exception instead of only emitting SAMPWarning and leaving is_running true.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
networking
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.