Skip to content

Commit d039260

Browse files
committed
Merge tag '3.8.0' into rel
2 parents 5884acf + 0a6f5b4 commit d039260

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+3378
-975
lines changed

CHANGELOG.rst

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,44 @@
1+
Version 3.8.0
2+
-------------
3+
4+
:Date: October 09, 2019
5+
6+
* `@stsewd <http://github.com/stsewd>`__: Update doccs version detail (api v3) (`#6259 <https://github.com/readthedocs/readthedocs.org/pull/6259>`__)
7+
* `@stsewd <http://github.com/stsewd>`__: Merge #6176 to master (`#6258 <https://github.com/readthedocs/readthedocs.org/pull/6258>`__)
8+
* `@humitos <http://github.com/humitos>`__: Remove privacy_level field from APIv3 (`#6257 <https://github.com/readthedocs/readthedocs.org/pull/6257>`__)
9+
* `@saadmk11 <http://github.com/saadmk11>`__: Redirect /projects/ URL to /dashboard/ (`#6255 <https://github.com/readthedocs/readthedocs.org/pull/6255>`__)
10+
* `@davidfischer <http://github.com/davidfischer>`__: Allow project badges for private version (`#6252 <https://github.com/readthedocs/readthedocs.org/pull/6252>`__)
11+
* `@pyup-bot <http://github.com/pyup-bot>`__: pyup: Scheduled weekly dependency update for week 40 (`#6251 <https://github.com/readthedocs/readthedocs.org/pull/6251>`__)
12+
* `@saadmk11 <http://github.com/saadmk11>`__: Add note about specifying dependencies (`#6248 <https://github.com/readthedocs/readthedocs.org/pull/6248>`__)
13+
* `@stsewd <http://github.com/stsewd>`__: Add pub_date to project admin (`#6244 <https://github.com/readthedocs/readthedocs.org/pull/6244>`__)
14+
* `@humitos <http://github.com/humitos>`__: Do not use --cache-dir for pip if CLEAN_AFTER_BUILD is enabled (`#6239 <https://github.com/readthedocs/readthedocs.org/pull/6239>`__)
15+
* `@stsewd <http://github.com/stsewd>`__: Update pytest (`#6233 <https://github.com/readthedocs/readthedocs.org/pull/6233>`__)
16+
* `@iambenzo <http://github.com/iambenzo>`__: remove /projects/ (`#6228 <https://github.com/readthedocs/readthedocs.org/pull/6228>`__)
17+
* `@ericholscher <http://github.com/ericholscher>`__: Initial stub of proxito (`#6226 <https://github.com/readthedocs/readthedocs.org/pull/6226>`__)
18+
* `@davidfischer <http://github.com/davidfischer>`__: Improve the version listview (`#6224 <https://github.com/readthedocs/readthedocs.org/pull/6224>`__)
19+
* `@stsewd <http://github.com/stsewd>`__: Override production media artifacts on test (`#6220 <https://github.com/readthedocs/readthedocs.org/pull/6220>`__)
20+
* `@davidfischer <http://github.com/davidfischer>`__: Customize default build media storage for the FS (`#6215 <https://github.com/readthedocs/readthedocs.org/pull/6215>`__)
21+
* `@agjohnson <http://github.com/agjohnson>`__: Release 3.7.5 (`#6214 <https://github.com/readthedocs/readthedocs.org/pull/6214>`__)
22+
* `@stsewd <http://github.com/stsewd>`__: Remove dead code (`#6213 <https://github.com/readthedocs/readthedocs.org/pull/6213>`__)
23+
* `@stsewd <http://github.com/stsewd>`__: Only use the sphinx way to mock (`#6212 <https://github.com/readthedocs/readthedocs.org/pull/6212>`__)
24+
* `@saadmk11 <http://github.com/saadmk11>`__: Only Build Active Versions from Build List Page Form (`#6205 <https://github.com/readthedocs/readthedocs.org/pull/6205>`__)
25+
* `@saadmk11 <http://github.com/saadmk11>`__: Make raw_config private (`#6199 <https://github.com/readthedocs/readthedocs.org/pull/6199>`__)
26+
* `@Iamshankhadeep <http://github.com/Iamshankhadeep>`__: moved expandable_fields to meta class (`#6198 <https://github.com/readthedocs/readthedocs.org/pull/6198>`__)
27+
* `@stsewd <http://github.com/stsewd>`__: Put view under login (`#6193 <https://github.com/readthedocs/readthedocs.org/pull/6193>`__)
28+
* `@dojutsu-user <http://github.com/dojutsu-user>`__: Remove pie-chart from search analytics page (`#6192 <https://github.com/readthedocs/readthedocs.org/pull/6192>`__)
29+
* `@stsewd <http://github.com/stsewd>`__: Refactor SearchAnalytics view (`#6190 <https://github.com/readthedocs/readthedocs.org/pull/6190>`__)
30+
* `@stsewd <http://github.com/stsewd>`__: Refactor ProjectRedirects views (`#6187 <https://github.com/readthedocs/readthedocs.org/pull/6187>`__)
31+
* `@stsewd <http://github.com/stsewd>`__: Refactor ProjectTranslations views (`#6185 <https://github.com/readthedocs/readthedocs.org/pull/6185>`__)
32+
* `@stsewd <http://github.com/stsewd>`__: Refactor ProjectNotications views (`#6183 <https://github.com/readthedocs/readthedocs.org/pull/6183>`__)
33+
* `@stsewd <http://github.com/stsewd>`__: Refactor views ProjectUsers (`#6178 <https://github.com/readthedocs/readthedocs.org/pull/6178>`__)
34+
* `@humitos <http://github.com/humitos>`__: Create subproject relationship via APIv3 endpoint (`#6176 <https://github.com/readthedocs/readthedocs.org/pull/6176>`__)
35+
* `@stsewd <http://github.com/stsewd>`__: Refactor views ProjectVersion (`#6175 <https://github.com/readthedocs/readthedocs.org/pull/6175>`__)
36+
* `@davidfischer <http://github.com/davidfischer>`__: Add terms of service (`#6174 <https://github.com/readthedocs/readthedocs.org/pull/6174>`__)
37+
* `@davidfischer <http://github.com/davidfischer>`__: Document connected account permissions (`#6172 <https://github.com/readthedocs/readthedocs.org/pull/6172>`__)
38+
* `@stsewd <http://github.com/stsewd>`__: Refactor views projects (`#6171 <https://github.com/readthedocs/readthedocs.org/pull/6171>`__)
39+
* `@dojutsu-user <http://github.com/dojutsu-user>`__: Optimize json parsing (`#6160 <https://github.com/readthedocs/readthedocs.org/pull/6160>`__)
40+
* `@humitos <http://github.com/humitos>`__: APIv3 endpoint: allow to modify a Project once it's imported (`#5952 <https://github.com/readthedocs/readthedocs.org/pull/5952>`__)
41+
142
Version 3.7.5
243
-------------
344

docs/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#
33

44
# You can set these variables from the command line.
5-
SPHINXOPTS = -W --keep-going
5+
SPHINXOPTS = -W
66
SPHINXBUILD = sphinx-build
77
PAPER =
88
BUILDDIR = _build

docs/api/v3.rst

Lines changed: 120 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -227,6 +227,35 @@ Project create
227227
:statuscode 400: Some field is invalid
228228

229229

230+
Project update
231+
++++++++++++++
232+
233+
.. http:patch:: /api/v3/projects/(string:project_slug)/
234+
235+
Update an existing project.
236+
237+
**Example request**:
238+
239+
.. sourcecode:: bash
240+
241+
$ curl \
242+
-X PATCH \
243+
-H "Authorization: Token <token>" https://readthedocs.org/api/v3/projects/pip/ \
244+
-H "Content-Type: application/json" \
245+
-d @body.json
246+
247+
The content of ``body.json`` is like,
248+
249+
.. sourcecode:: json
250+
251+
{
252+
"name": "New name for the project",
253+
"default_version": "v0.27.0"
254+
}
255+
256+
:statuscode 204: Updated successfully
257+
258+
230259
Versions
231260
~~~~~~~~
232261

@@ -301,7 +330,6 @@ Version detail
301330
"ref": "19.0.2",
302331
"built": true,
303332
"active": true,
304-
"uploaded": true,
305333
"type": "tag",
306334
"last_build": "{BUILD}",
307335
"downloads": {
@@ -320,29 +348,21 @@ Version detail
320348
}
321349
}
322350

323-
:>json integer id: ID for this version on the database
324-
:>json string slug: The slug for this version
325-
:>json string verbose_name: The name of the version
326-
:>json string identifier: A version control identifier for this version (eg. the commit hash of the tag)
327-
:>json string ref: tag or branch pointed by this version (available only when version is ``stable`` or ``latest``)
328-
:>json string built: Whether this version has been built
329-
:>json string active: Whether this version is active
330-
:>json string type: The type of this version (typically "tag" or "branch")
331-
:>json string last_build: Build object representing the last build of this version
332-
:>json array downloads: URLs to downloads of this version's documentation
351+
:>json string ref: the version slug where the ``stable`` version points to.
352+
``null`` when it's not the stable version.
353+
:>json boolean built: the version has at least one successful build.
333354

334-
:requestheader Authorization: token to authenticate.
335-
336-
:statuscode 200: Success
337-
:statuscode 404: There is no ``Version`` with this slug for this project
355+
:query string expand: allows to add/expand some extra fields in the response.
356+
Allowed values are ``last_build`` and ``last_build.config``.
357+
Multiple fields can be passed separated by commas.
338358

339359

340360
Version update
341361
++++++++++++++
342362

343363
.. http:patch:: /api/v3/projects/(string:project_slug)/version/(string:version_slug)/
344364
345-
Edit a version.
365+
Update a version.
346366

347367
**Example request**:
348368

@@ -355,7 +375,7 @@ Version update
355375

356376
:requestheader Authorization: token to authenticate.
357377

358-
:statuscode 204: Edited successfully
378+
:statuscode 204: Updated successfully
359379
:statuscode 400: Some field is invalid
360380
:statuscode 401: Not valid permissions
361381
:statuscode 404: There is no ``Version`` with this slug for this project
@@ -532,6 +552,34 @@ This allows for documentation projects to share a search index and a namespace o
532552
but still be maintained independently.
533553
See :doc:`/subprojects` for more information.
534554

555+
556+
Subproject details
557+
++++++++++++++++++
558+
559+
560+
.. http:get:: /api/v3/projects/(str:project_slug)/subprojects/(str:alias_slug)/
561+
562+
Retrieve details of a subproject relationship.
563+
564+
**Example request**:
565+
566+
.. sourcecode:: bash
567+
568+
$ curl -H "Authorization: Token <token>" https://readthedocs.org/api/v3/projects/pip/subprojects/subproject-alias/
569+
570+
**Example response**:
571+
572+
.. sourcecode:: json
573+
574+
{
575+
"alias": "subproject-alias",
576+
"child": ["PROJECT"],
577+
"_links": {
578+
"parent": "/api/v3/projects/pip/"
579+
}
580+
}
581+
582+
535583
Subprojects listing
536584
+++++++++++++++++++
537585

@@ -554,15 +602,64 @@ Subprojects listing
554602
"count": 25,
555603
"next": "/api/v3/projects/pip/subprojects/?limit=10&offset=10",
556604
"previous": null,
557-
"results": ["PROJECT"]
605+
"results": ["SUBPROJECT RELATIONSHIP"]
558606
}
559607

560-
:>json integer count: total number of projects.
561-
:>json string next: URI for next set of projects.
562-
:>json string previous: URI for previous set of projects.
563-
:>json array results: array of ``project`` objects.
564608

565-
:requestheader Authorization: token to authenticate.
609+
Subproject create
610+
+++++++++++++++++
611+
612+
613+
.. http:post:: /api/v3/projects/(str:project_slug)/subprojects/
614+
615+
Create a subproject relationship between two projects.
616+
617+
**Example request**:
618+
619+
.. sourcecode:: bash
620+
621+
$ curl \
622+
-X POST \
623+
-H "Authorization: Token <token>" https://readthedocs.org/api/v3/projects/pip/subprojects/ \
624+
-H "Content-Type: application/json" \
625+
-d @body.json
626+
627+
The content of ``body.json`` is like,
628+
629+
.. sourcecode:: json
630+
631+
{
632+
"child": "subproject-child-slug",
633+
"alias": "subproject-alias"
634+
}
635+
636+
**Example response**:
637+
638+
`See Subproject details <#subproject-details>`_
639+
640+
:>json string child: slug of the child project in the relationship.
641+
:>json string alias: optional slug alias to be used in the URL (e.g ``/projects/<alias>/en/latest/``).
642+
If not provided, child project's slug is used as alias.
643+
644+
:statuscode 201: Subproject created sucessfully
645+
646+
647+
Subproject delete
648+
+++++++++++++++++
649+
650+
.. http:delete:: /api/v3/projects/(str:project_slug)/subprojects/(str:alias_slug)/
651+
652+
Delete a subproject relationship.
653+
654+
**Example request**:
655+
656+
.. sourcecode:: bash
657+
658+
$ curl \
659+
-X DELETE \
660+
-H "Authorization: Token <token>" https://readthedocs.org/api/v3/projects/pip/subprojects/subproject-alias/
661+
662+
:statuscode 204: Subproject deleted successfully
566663

567664

568665
Translations

docs/faq.rst

Lines changed: 10 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -81,30 +81,14 @@ I get import errors on libraries that depend on C modules
8181
---------------------------------------------------------
8282

8383
.. note::
84-
Another use case for this is when you have a module with a C extension.
8584

86-
This happens because our build system doesn't have the dependencies for building your project. This happens with things like ``libevent``, ``mysql``, and other python packages that depend on C libraries. We can't support installing random C binaries on our system, so there is another way to fix these imports.
85+
Another use case for this is when you have a module with a C extension.
8786

88-
With Sphinx you can use the built-in `autodoc_mock_imports`_ for mocking. Alternatively you can use the mock library by putting the following snippet in your ``conf.py``::
89-
90-
import sys
91-
from unittest.mock import MagicMock
92-
93-
class Mock(MagicMock):
94-
@classmethod
95-
def __getattr__(cls, name):
96-
return MagicMock()
97-
98-
MOCK_MODULES = ['pygtk', 'gtk', 'gobject', 'argparse', 'numpy', 'pandas']
99-
sys.modules.update((mod_name, Mock()) for mod_name in MOCK_MODULES)
100-
101-
You need to replace ``MOCK_MODULES`` with the modules that you want to mock out.
102-
103-
.. Tip:: The library ``unittest.mock`` was introduced on python 3.3. On earlier versions install the ``mock`` library
104-
from PyPI with (ie ``pip install mock``) and replace the above import::
105-
106-
from mock import Mock as MagicMock
87+
This happens because our build system doesn't have the dependencies for building your project.
88+
This happens with things like ``libevent``, ``mysql``, and other python packages that depend on C libraries.
89+
We can't support installing random C binaries on our system, so there is another way to fix these imports.
10790

91+
With Sphinx you can use the built-in `autodoc_mock_imports`_ for mocking.
10892
If such libraries are installed via ``setup.py``, you also will need to remove all the C-dependent libraries from your ``install_requires`` in the RTD environment.
10993

11094
.. _autodoc_mock_imports: http://www.sphinx-doc.org/en/master/usage/extensions/autodoc.html#confval-autodoc_mock_imports
@@ -207,6 +191,11 @@ are `numpydoc <https://github.com/numpy/numpydoc>`_ and
207191
output more closely matches the format of standard Sphinx annotations,
208192
and as a result, it tends to look a bit better with the default theme.
209193

194+
.. note::
195+
196+
To use these extensions you need to specify the dependencies on your project
197+
by following this :doc:`guide <guides/specifying-dependencies>`.
198+
210199
Can I document a python package that is not at the root of my repository?
211200
-------------------------------------------------------------------------
212201

docs/index.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,7 @@ of Read the Docs and the larger software documentation ecosystem.
163163
* **Policies & Process**:
164164
:doc:`security` |
165165
:doc:`Privacy policy <privacy-policy>` |
166+
:doc:`Terms of service <terms-of-service>` |
166167
:doc:`DMCA takedown policy <dmca/index>` |
167168
:doc:`Policy for abandoned projects <abandoned-projects>` |
168169
:doc:`Release notes & changelog <changelog>`
@@ -195,6 +196,7 @@ of Read the Docs and the larger software documentation ecosystem.
195196

196197
security
197198
privacy-policy
199+
terms-of-service
198200
dmca/index
199201
abandoned-projects
200202
changelog

docs/privacy-policy.rst

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
Privacy Policy
55
==============
66

7-
Effective date: **August 1, 2019**
7+
Effective date: **September 30, 2019**
88

99
Welcome to Read the Docs.
1010
At Read the Docs, we believe in protecting the privacy of our
@@ -30,22 +30,24 @@ Our services
3030
Read the Docs is made up of:
3131

3232
readthedocs.org ("Read the Docs Community")
33-
This is a website aimed at documentation authors writing and building
34-
software documentation. This Privacy Policy applies to this site
35-
in full without reservation.
33+
This is a website aimed at documentation authors and project maintainers
34+
writing and distributing technical documentation.
35+
This Privacy Policy applies to this site in full without reservation.
3636

3737
readthedocs.com ("Read the Docs for Business")
3838
This website is a commercial hosted offering for hosting private
3939
documentation for corporate clients.
40-
It is governed by this privacy policy but also separate
41-
`terms <https://readthedocs.com/terms/>`_.
40+
This Privacy Policy applies to this site in full without reservation.
4241

4342
readthedocs.io, readthedocs-hosted.com, and other domains ("Documentation Sites")
44-
These websites are where Read the Docs hosts documentation on
45-
behalf of documentation authors. A best effort is made to apply
43+
These websites are where Read the Docs hosts documentation (":ref:`User-Generated Content <terms-of-service:User-Generated Content>`")
44+
on behalf of documentation authors.
45+
A best effort is made to apply
4646
this Privacy Policy to these sites but the documentation
4747
may contain content and files created by documentation authors.
4848

49+
All use of Read the Docs is subject to this Privacy Policy, together with our :doc:`Terms of service <terms-of-service>`.
50+
4951

5052
What information Read the Docs collects and why
5153
-----------------------------------------------
@@ -115,6 +117,9 @@ anyone (including us) may view their contents.
115117
If you have included private or sensitive information in your Documentation Site,
116118
such as email addresses, that information may be indexed by search engines or used by third parties.
117119

120+
Read the Docs for Business may host :ref:`private projects <terms-of-service:Private projects>` which we treat as confidential
121+
and we only access them for support reasons, with your consent, or if required to for security reasons
122+
118123
If you're a **child under the age of 13**, you may not have an account on Read the Docs.
119124
Read the Docs does not knowingly collect information from or direct any of our content specifically to children under 13.
120125
If we learn or have reason to suspect that you are a user who is under the age of 13, we will unfortunately have to close your account.

0 commit comments

Comments
 (0)