GraceDB Client issueshttps://git.ligo.org/computing/gracedb/client/-/issues2019-06-06T14:38:12Zhttps://git.ligo.org/computing/gracedb/client/-/issues/21`gracedb get file` fails with UnicodeDecodeError2019-06-06T14:38:12ZLeo P. Singer`gracedb get file` fails with UnicodeDecodeError```
$ gracedb -s https://gracedb-playground.ligo.org/api/ get file G85106 psd.xml.gz
Traceback (most recent call last):
File "/usr/bin/gracedb", line 10, in <module>
sys.exit(main())
File "/usr/lib/python3.6/site-packages/ligo/gr...```
$ gracedb -s https://gracedb-playground.ligo.org/api/ get file G85106 psd.xml.gz
Traceback (most recent call last):
File "/usr/bin/gracedb", line 10, in <module>
sys.exit(main())
File "/usr/lib/python3.6/site-packages/ligo/gracedb/cli/client.py", line 184, in main
print(response.decode())
UnicodeDecodeError: 'utf-8' codec can't decode byte 0x8b in position 1: invalid start byte
```
System details
--------------
```
$ uname -v
Darwin Kernel Version 18.6.0: Thu Apr 25 23:16:27 PDT 2019; root:xnu-4903.261.4~2/RELEASE_X86_64
$ python --version
Python 3.6.8
$ pip freeze
amqp==2.4.2
appnope==0.1.0
asn1crypto==0.24.0
astroplan==0.4
astropy==3.1.2
astropy-healpix==0.4
atomicwrites==1.3.0
attrs==19.1.0
Automat==0.7.0
Babel==2.7.0
backcall==0.1.0
billiard==3.6.0.0
blinker==1.4
celery==4.3.0
celery-eternal==0.1.1
celery-singleton==0.1.3
certifi==2019.3.9
cffi==1.12.3
Click==7.0
Comet==3.1.0
constantly==15.1.0
corner==2.0.1
cryptography==2.6.1
cycler==0.10.0
decorator==4.4.0
dnspython==1.16.0
dqsegdb2==1.0.1
Flask==1.0.3
Flask-Caching==1.7.1
flower==1.0.0
future==0.17.1
-e git+git@git.ligo.org:leo-singer/gwcelery.git@3f9c7e330796fcbab7e925e690acdbd8aa917fbf#egg=gwcelery
gwdatafind==1.0.4
gwosc==0.4.3
gwpy==0.15.0
h5py==2.9.0
healpy==1.12.9
humanize==0.5.1
hyperlink==19.0.0
idna==2.8
importlib-metadata==0.15
incremental==17.5.0
ipython==7.5.0
ipython-genutils==0.2.0
itsdangerous==1.1.0
jedi==0.13.3
Jinja2==2.10.1
kiwisolver==1.1.0
kombu==4.5.0
lalsuite==6.54
ligo-followup-advocate==0.0.28
ligo-gracedb==2.2.2
ligo-raven==1.11
ligo-segments==1.2.0
ligo.skymap==0.1.6
ligotimegps==2.0.1
lscsoft-glue==2.0.0
lxml==4.3.3
MarkupSafe==1.1.1
matplotlib==3.1.0
meld3==1.0.2
more-itertools==7.0.0
networkx==2.3
numpy==1.16.3
p-astro==0.7
pandas==0.24.2
parso==0.4.0
pexpect==4.7.0
pickleshare==0.7.5
Pillow==6.0.0
pluggy==0.12.0
prompt-toolkit==2.0.9
ptemcee==1.0.0
ptyprocess==0.6.0
py==1.8.0
pyasn1==0.3.7
pyasn1-modules==0.1.5
pycparser==2.19
pygcn==0.1.19
Pygments==2.4.2
PyHamcrest==1.9.0
pyOpenSSL==19.0.0
pyparsing==2.4.0
pytest==4.5.0
python-dateutil==2.8.0
python-ligo-lw==1.5.3
pytz==2019.1
pyxdg==0.26
PyYAML==5.1
redis==3.2.1
reproject==0.4
safe-netrc==0.0.1
scikit-learn==0.19.2
scipy==1.3.0
seaborn==0.9.0
sentry-sdk==0.8.0
service-identity==18.1.0
six==1.12.0
sleek-lvalert==0.0.5
sleekxmpp==1.3.3
supervisor==4.0.0.dev0
tornado==5.1.1
tqdm==4.32.1
traitlets==4.3.2
Twisted==19.2.0
urllib3==1.25.3
vine==1.3.0
VOEventLib==1.2
wcwidth==0.1.7
Werkzeug==0.15.4
zipp==0.5.1
zope.interface==4.6.0
```https://git.ligo.org/computing/gracedb/client/-/issues/36client support for adding multiple events to superevents in one go2023-02-08T21:36:53ZAlexander Paceclient support for adding multiple events to superevents in one goClient support of this issue: https://git.ligo.org/computing/gracedb/server/-/issues/250Client support of this issue: https://git.ligo.org/computing/gracedb/server/-/issues/250Critical Path O4 DevelopmentDuncan MeacherDuncan Meacherhttps://git.ligo.org/computing/gracedb/client/-/issues/44Fix broken code examples2023-12-04T22:26:05ZDaniel WysockiFix broken code examplesThere are still leftover code examples from the Python 2 days. A search for "`print `" on the API page pulls up 6 examples, while "`print(`" only pulls up 2. There may be other less obvious breakages, possibly separate from Python 2/3 ...There are still leftover code examples from the Python 2 days. A search for "`print `" on the API page pulls up 6 examples, while "`print(`" only pulls up 2. There may be other less obvious breakages, possibly separate from Python 2/3 incompatibilities.
To fix this, we should identify an exhaustive list of code examples in the docs, and test them all. A better long-term solution would be incorporating `doctest` into our unit tests, automatically ensuring all code examples actually work, though I think this is best saved for a later issue.Daniel WysockiDaniel Wysockihttps://git.ligo.org/computing/gracedb/client/-/issues/45Move away from pytest-runner2023-11-21T00:06:46ZDaniel WysockiMove away from pytest-runnerFrom `pytest-runner`'s README:
> `pytest-runner` depends on deprecated features of setuptools and relies on features that break security mechanisms in pip. For example ‘`setup_requires`’ and ‘`tests_require`’ bypass `pip --require-hashe...From `pytest-runner`'s README:
> `pytest-runner` depends on deprecated features of setuptools and relies on features that break security mechanisms in pip. For example ‘`setup_requires`’ and ‘`tests_require`’ bypass `pip --require-hashes`. See also [pypa/setuptools#1684](https://github.com/pypa/setuptools/issues/1684).
>
> It is recommended that you:
>
> * Remove '`pytest-runner`' from your `setup_requires`, preferably removing the `setup_requires` option.
> * Remove '`pytest`' and any other testing requirements from `tests_require`, preferably removing the `tests_requires` option.
> * Select a tool to bootstrap and then run tests such as `tox`.Daniel WysockiDaniel Wysockihttps://git.ligo.org/computing/gracedb/client/-/issues/23Remove `skymap_type` from `createVOEvent`2019-09-18T17:51:29ZTanner PrestegardRemove `skymap_type` from `createVOEvent`The `python3` branch for GraceDB server includes a few minor changes to the VOEvent file format, including the fact that there won't be any need for the `skymap_type` any longer. We should deprecate it in one release (i.e., make it non-...The `python3` branch for GraceDB server includes a few minor changes to the VOEvent file format, including the fact that there won't be any need for the `skymap_type` any longer. We should deprecate it in one release (i.e., make it non-required and print a warning if it's included in the kwargs to `createVOEvent`), and then remove it in the next release.https://git.ligo.org/computing/gracedb/client/-/issues/30test_logger fails on linux/python3.9 as part of IGWN Conda integration tests2021-07-14T19:51:56ZDuncan Macleodduncan.macleod@ligo.orgtest_logger fails on linux/python3.9 as part of IGWN Conda integration testsThe `test/test_logging.py::test_logger` test function is failing repeatedly on Linux only on python3.9 when run as part of the IGWN Conda Distribution [[ref]](https://git.ligo.org/computing/conda/-/jobs/1447099):
```python
# Che...The `test/test_logging.py::test_logger` test function is failing repeatedly on Linux only on python3.9 when run as part of the IGWN Conda Distribution [[ref]](https://git.ligo.org/computing/conda/-/jobs/1447099):
```python
# Check results - there must be something weird with threading going on
# since if we don't sleep here, mock_write_log.call_args returns as None
time.sleep(0.01)
> call_args, call_kwargs = mock_write_log.call_args
E TypeError: cannot unpack non-iterable NoneType object
../../../envs/igwn-py39-testing/lib/python3.9/site-packages/ligo/gracedb/test/test_logging.py:37: TypeError
```
It looks like the `time.sleep` just isn't long enough, or for some other reason the log isn't actually being emitted. I can't reproduce this outside of that environment.https://git.ligo.org/computing/gracedb/client/-/issues/9Use urllib.error.HTTPError instead of custom HTTPError2018-07-31T15:32:21ZTanner PrestegardUse urllib.error.HTTPError instead of custom HTTPErrorAn HTTPError is available in `six.moves.urllib.error`, which removes the need for the custom `HTTPError` which is in `ligo.gracedb.exceptions`. We should explore moving to the urllib exception.An HTTPError is available in `six.moves.urllib.error`, which removes the need for the custom `HTTPError` which is in `ligo.gracedb.exceptions`. We should explore moving to the urllib exception.