Codebase list drms / 3263e97
Update upstream source from tag 'upstream/0.6.1' Update to upstream version '0.6.1' with Debian dir 776a5abd32aedbd6e7316f286b5460bf34ef7172 Ole Streicher 3 years ago
17 changed file(s) with 52 addition(s) and 29 deletion(s). Raw diff Collapse all Expand all
0 Drms v0.6.1 (2021-01-23)
1 ========================
2
3 Bug Fixes
4 ---------
5
6 - Fixed issue with downloads not having the primekeys substituted with their correct values in downloaded filenames. (`#52 <https://github.com/sunpy/drms/pull/52>`__)
7
8
09 drms v0.6.0 (2020-11-01)
110 ========================
211
00 Metadata-Version: 2.1
11 Name: drms
2 Version: 0.6.0
2 Version: 0.6.1
33 Summary: "Access HMI, AIA and MDI data with Python"
44 Home-page: https://sunpy.org
55 Author: The SunPy Community
77
88 # -- Project information -----------------------------------------------------
99
10 import os
1011 from drms import __version__
1112
1213 project = 'drms'
8990 except ImportError:
9091 html_theme = 'default'
9192
93 # JSOC email os env
94 os.environ["JSOC_EMAIL"] = "jsoc@cadair.com"
9295
9396 # Add any paths that contain custom static files (such as style sheets) here,
9497 # relative to this directory. They are copied after the builtin static files,
00 # coding: utf-8
11 # file generated by setuptools_scm
22 # don't change, don't track in version control
3 version = '0.6.0'
3 version = '0.6.1'
4 version_tuple = (0, 6, 1)
681681 if si.keywords.loc[k].is_time:
682682 pkfmt_list.append(f'{{{k}:A}}')
683683 else:
684 pkfmt_list.append(f'{k}')
684 pkfmt_list.append(f'{{{k}}}')
685685
686686 if pkfmt_list:
687687 return '{}.{}.{{segment}}'.format(si.name, '.'.join(pkfmt_list))
367367 method = 'url'
368368
369369 if protocol in img_protocol_list:
370 d = {'ct': 'grey.sao', 'scaling': 'MINMAX', 'size': 1}
370 extra_keys = {'ct': 'grey.sao', 'scaling': 'MINMAX', 'size': 1}
371371 if protocol_args is not None:
372372 for k, v in protocol_args.items():
373373 if k.lower() == 'ct':
374 d['ct'] = v
374 extra_keys['ct'] = v
375375 elif k == 'scaling':
376 d[k] = v
376 extra_keys[k] = v
377377 elif k == 'size':
378 d[k] = int(v)
378 extra_keys[k] = int(v)
379379 elif k in ['min', 'max']:
380 d[k] = float(v)
380 extra_keys[k] = float(v)
381381 else:
382382 raise ValueError(f'Unknown protocol argument: {k}')
383 protocol += ',CT={ct},scaling={scaling},size={size}'.format(**d)
384 if 'min' in d:
385 protocol += f',min={d["min"]:g}'
386 if 'max' in d:
387 protocol += f',max={d["max"]:g}'
383 protocol += ',CT={ct},scaling={scaling},size={size}'.format(**extra_keys)
384 if 'min' in extra_keys:
385 protocol += f',min={extra_keys["min"]:g}'
386 if 'max' in extra_keys:
387 protocol += f',max={extra_keys["max"]:g}'
388388 else:
389389 if protocol_args is not None:
390390 raise ValueError(f'protocol_args not supported for protocol {protocol}')
6767 if force or s.str.endswith('_TAI').any():
6868 s = s.str.replace('_TAI', "")
6969 s = s.str.replace('_', ' ')
70 s = s.str.replace('.', '-', n=2)
70 s = s.str.replace('.', '-', regex=True, n=2)
7171 res = _pd_to_datetime_coerce(s)
7272 res = res.dt.tz_localize(None)
7373 return res.iloc[0] if (len(res) == 1) and np.isscalar(tstr) else res
00 Metadata-Version: 2.1
11 Name: drms
2 Version: 0.6.0
2 Version: 0.6.1
33 Summary: "Access HMI, AIA and MDI data with Python"
44 Home-page: https://sunpy.org
55 Author: The SunPy Community
1616
1717 # This example requires a registered export email address. You can register
1818 # JSOC exports at: http://jsoc.stanford.edu/ajax/register_email.html
19 email = 'nabil.freij@gmail.com'
19 # You must supply your own email.
20 email = os.environ["JSOC_EMAIL"]
2021
2122 # Download directory
2223 out_dir = os.path.join('downloads')
2627 os.makedirs(out_dir)
2728
2829 ###############################################################################
29 # Construct the DRMS query string: "Series[harpnum][timespan]{data segments}"
30 # Construct the DRMS query string: "Series[timespan][wavelength]{data segments}"
3031
3132 qstr = 'aia.lev1_euv_12s[2015-10-17T04:33:30.000/1m@12s][171]{image}'
3233 print(f'Data export query:\n {qstr}\n')
2121
2222 # This example requires a registered export email address. You can register
2323 # JSOC exports at: http://jsoc.stanford.edu/ajax/register_email.html
24 email = 'nabil.freij@gmail.com'
24 # You must supply your own email.
25 email = os.environ["JSOC_EMAIL"]
2526
2627 # Download directory
2728 out_dir = os.path.join('downloads')
2121
2222 # This example requires a registered export email address. You can register
2323 # JSOC exports at: http://jsoc.stanford.edu/ajax/register_email.html
24 email = 'nabil.freij@gmail.com'
24 # You must supply your own email.
25 email = os.environ["JSOC_EMAIL"]
2526
2627 # Use 'as-is' instead of 'fits', if record keywords are not needed in the
2728 # FITS header. This greatly reduces the server load!
2222
2323 # This example requires a registered export email address. You can register
2424 # JSOC exports at: http://jsoc.stanford.edu/ajax/register_email.html
25 email = 'nabil.freij@gmail.com'
25 # You must supply your own email.
26 email = os.environ["JSOC_EMAIL"]
2627
2728 # Arguments for 'jpg' protocol
2829 jpg_args = {
2222
2323 # This example requires a registered export email address. You can register
2424 # JSOC exports at: http://jsoc.stanford.edu/ajax/register_email.html
25 email = 'nabil.freij@gmail.com'
25 # You must supply your own email.
26 email = os.environ["JSOC_EMAIL"]
2627
2728 # Download directory
2829 out_dir = 'downloads'
77
88 Note that there is no "Request URL" for method 'url_quick'.
99 """
10 import os
1011
1112 import drms
1213
1718
1819 # This example requires a registered export email address. You can register
1920 # JSOC exports at: http://jsoc.stanford.edu/ajax/register_email.html
20 email = 'nabil.freij@gmail.com'
21 # You must supply your own email.
22 email = os.environ["JSOC_EMAIL"]
2123
2224 ###############################################################################
2325 # Construct the DRMS query string: "Series[timespan][wavelength]"
2424
2525 # This example requires a registered export email address. You can register
2626 # JSOC exports at: http://jsoc.stanford.edu/ajax/register_email.html
27 email = 'nabil.freij@gmail.com'
27 # You must supply your own email.
28 email = os.environ["JSOC_EMAIL"]
2829
2930 # Download directory
3031 out_dir = 'downloads'
7272 junit_family = xunit2
7373
7474 [pycodestyle]
75 max_line_length = 100
75 max_line_length = 110
7676
7777 [flake8]
78 max-line-length = 100
78 max-line-length = 110
7979 exclude =
8080 .git,
8181 __pycache__,
00 [tox]
11 envlist =
2 py{37,38}{,-online,-sunpy}
2 py{37,38,39}{,-online,-sunpy}
33 build_docs
44 codestyle
55 isolated_build = true
2828 MPLBACKEND = agg
2929 COLUMNS = 180
3030 PYTEST_COMMAND = pytest -vvv -s -ra --pyargs drms --cov-report=xml --cov=drms --cov-config={toxinidir}/setup.cfg {toxinidir}/docs
31 devdeps,build_docs,online: HOME = {envtmpdir}
31 build_docs,online: HOME = {envtmpdir}
3232 passenv =
3333 HTTP_PROXY
3434 HTTPS_PROXY
4040 online: pytest-timeout
4141 # We want to run the sunpy jsoc tests
4242 sunpy: sunpy[all]
43 # All our tests run in parallel which this plugin allows us to.
44 pytest-xdist
4345 # The following indicates which extras_require from setup.cfg will be installed
4446 # dev is special in that it installs everything
4547 extras =
4648 dev
4749 commands =
48 sunpy: pytest -vvv -s -ra --pyargs sunpy.net.jsoc --remote-data=any -m "remote_data" {posargs}
50 sunpy: pytest -vvv -s -ra --pyargs sunpy.net.jsoc --remote-data=any {posargs}
4951 !online: {env:PYTEST_COMMAND} {posargs}
50 online: {env:PYTEST_COMMAND} --reruns 2 --timeout=180 --remote-data=any -m "remote_data" --email nabil.freij@gmail.com {posargs}
52 online: {env:PYTEST_COMMAND} --reruns 2 --reruns-delay 60 --timeout=300 --remote-data=any --email jsoc@cadair.com {posargs}
5153
5254 [testenv:build_docs]
5355 changedir = docs