Skip to content

Commit ef82a39

Browse files
authored
documentation fixes (#632)
* fix broken api reference * http to https for ref links * add okexcept to forecasts.rst ndfd horribleness * clean up whatsnew * fix docstrings * add ipython_warning_is_error=False * issue with blank lines in docstring read by ipython_directive. probably ipython version specific * fix deprecated tmy call and wrong deprecation message * add item to whatsnew * remove redundant line
1 parent d979187 commit ef82a39

File tree

9 files changed

+26
-19
lines changed

9 files changed

+26
-19
lines changed

docs/sphinx/source/api.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ calculations.
9090
solarposition.equation_of_time_spencer71
9191
solarposition.equation_of_time_pvcdrom
9292
solarposition.hour_angle
93-
solarposition.sunrise_sunset_transit_geometric
93+
solarposition.sun_rise_set_transit_geometric
9494

9595

9696
Clear sky

docs/sphinx/source/conf.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -313,8 +313,10 @@ def setup(app):
313313
# Example configuration for intersphinx: refer to the Python standard library.
314314
intersphinx_mapping = {
315315
'python': ('https://docs.python.org/3.7/', None),
316-
'pandas': ('http://pandas.pydata.org/pandas-docs/stable/', None),
317-
'numpy': ('http://docs.scipy.org/doc/numpy/', None),
316+
'pandas': ('https://pandas.pydata.org/pandas-docs/stable/', None),
317+
'numpy': ('https://docs.scipy.org/doc/numpy/', None),
318318
}
319319

320320
nbsphinx_allow_errors = True
321+
322+
ipython_warning_is_error = False

docs/sphinx/source/forecasts.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -414,6 +414,7 @@ Use the NDFD, among others, for forecasts at all time horizons.
414414
The NDFD is available for the United States.
415415

416416
.. ipython:: python
417+
:okexcept:
417418
418419
model = NDFD()
419420
data = model.get_processed_data(latitude, longitude, start, end)

docs/sphinx/source/modelchain.rst

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -376,9 +376,7 @@ function if you wanted to.
376376
def pvusa(poa_global, wind_speed, temp_air, a, b, c, d):
377377
"""
378378
Calculates system power according to the PVUSA equation
379-
380379
P = I * (a + b*I + c*W + d*T)
381-
382380
where
383381
P is the output power,
384382
I is the plane of array irradiance,

docs/sphinx/source/timetimezones.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ Let's first examine how pvlib handles time when it imports a TMY3 file.
272272
# some gymnastics to find the example file
273273
pvlib_abspath = os.path.dirname(os.path.abspath(inspect.getfile(pvlib)))
274274
file_abspath = os.path.join(pvlib_abspath, 'data', '703165TY.csv')
275-
tmy3_data, tmy3_metadata = pvlib.tmy.readtmy3(file_abspath)
275+
tmy3_data, tmy3_metadata = pvlib.iotools.read_tmy3(file_abspath)
276276
277277
tmy3_metadata
278278

docs/sphinx/source/whatsnew/v0.6.1.rst

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.. _whatsnew_0601:
22

3-
v0.6.1 (EST November, 2018)
3+
v0.6.1 (EST December, 2018)
44
---------------------------
55

66
This is a minor release. We recommend all users of v0.6.0 upgrade to this
@@ -19,11 +19,14 @@ API Changes
1919
they will be removed in v0.7. Use the new :py:func:`pvlib.iotools.read_tmy2`
2020
and :py:func:`pvlib.iotools.read_tmy3` instead. (:issue:`261`)
2121
* Added keyword argument ``horizon`` to :func:`~pvlib.solarposition.pyephem`
22-
and :func:`~pvlib.solarposition.calc_time` with default value ``'+0:00'``
23-
* Changed key names for `components` returned from :py:func:`pvlib.clearsky.detect_clearsky`
24-
* Changed function name from :py:func:`pvlib.solarposition.get_rise_set_transit` (deprecated)
25-
to :py:func:`pvlib.solarposition.sun_rise_set_transit_spa. `sun_rise_set_transit_spa`
26-
requires time input to be localized to the specified latitude/longitude. (:issue:`316')
22+
and :func:`~pvlib.solarposition.calc_time` with default value ``'+0:00'``.
23+
(:issue:`588`)
24+
* Changed key names for `components` returned from
25+
:py:func:`pvlib.clearsky.detect_clearsky`. (:issue:`596`)
26+
* Changed function name from `pvlib.solarposition.get_rise_set_transit`
27+
(deprecated) to :py:func:`pvlib.solarposition.sun_rise_set_transit_spa.
28+
`sun_rise_set_transit_spa` requires time input to be localized to the
29+
specified latitude/longitude. (:issue:`316`)
2730

2831

2932
Enhancements
@@ -43,18 +46,20 @@ Enhancements
4346
isobaric values and modeled wind speed instead of inferring from gust.
4447
(:issue:`604`)
4548
* Change :py:func:`pvlib.pvsystem.sapm_spectral_loss` to avoid numpy warning.
46-
* Add warning message when :py:func:`pvlib.spa` is reloaded.
49+
* Add warning message when :py:func:`pvlib.spa` is reloaded. (:issue:`401`)
4750
* Add option for :py:func:`pvlib.irradiance.disc` to use relative airmass
4851
by supplying `pressure=None`. (:issue:`449`)
4952

5053

5154
Bug fixes
5255
~~~~~~~~~
5356
* Fix when building documentation using Matplotlib 3.0 or greater.
54-
* `~pvlib.spa.calculate_deltat`: Fix constant coefficient of the polynomial expression for years >= 1860
55-
and < 1900, fix year 2050 which was returning 0.
57+
* `~pvlib.spa.calculate_deltat`: Fix constant coefficient of the polynomial
58+
expression for years >= 1860 and < 1900, fix year 2050 which was
59+
returning 0. (:issue:`600`)
5660
* Fix and improve :func:`~pvlib.solarposition.hour_angle` (:issue:`598`)
5761
* Fix error in :func:`pvlib.clearsky.detect_clearsky` (:issue:`506`)
62+
* Fix documentation errors when using IPython >= 7.0.
5863
* Fix error in :func:`pvlib.modelchain.ModelChain.infer_spectral_model` (:issue:`619`)
5964

6065

pvlib/iotools/midc.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -185,8 +185,9 @@ def read_midc_raw_data_from_nrel(site, start, end):
185185
Notes
186186
-----
187187
Requests spanning an instrumentation change will yield an error. See the
188-
MIDC raw data api page here_ for more details and considerations.
189-
.. _here: https://midcdmz.nrel.gov/apps/data_api_doc.pl?_idtextlist
188+
MIDC raw data api page
189+
`here <https://midcdmz.nrel.gov/apps/data_api_doc.pl?_idtextlist>`_
190+
for more details and considerations.
190191
"""
191192
args = {'site': site,
192193
'begin': start.strftime('%Y%m%d'),

pvlib/solarposition.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -387,7 +387,7 @@ def sun_rise_set_transit_spa(times, latitude, longitude, how='numpy',
387387
using times.year and times.month from pandas.DatetimeIndex.
388388
For most simulations specifing delta_t is sufficient.
389389
Difference between terrestrial time and UT1.
390-
*Note: delta_t = None will break code using nrel_numba,
390+
delta_t = None will break code using nrel_numba,
391391
this will be fixed in a future version.
392392
By default, use USNO historical data and predictions
393393
how : str, optional, default 'numpy'

pvlib/tmy.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,5 @@
99
readtmy2 = deprecated('0.6.1', alternative='iotools.read_tmy2',
1010
name='readtmy2', removal='0.7')(read_tmy2)
1111

12-
readtmy3 = deprecated('0.6.1', alternative='iotools.read_tmy2',
12+
readtmy3 = deprecated('0.6.1', alternative='iotools.read_tmy3',
1313
name='readtmy3', removal='0.7')(read_tmy3)

0 commit comments

Comments
 (0)