Skip to content

Commit 5368cf4

Browse files
travis fixes
2 parents 261e13b + cb56df4 commit 5368cf4

File tree

113 files changed

+5204
-1404
lines changed

Some content is hidden

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

113 files changed

+5204
-1404
lines changed

CHANGELOG.rst

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,68 @@
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+
42+
Version 3.7.5
43+
-------------
44+
45+
:Date: September 26, 2019
46+
47+
* `@davidfischer <http://github.com/davidfischer>`__: Remove if storage blocks (`#6191 <https://github.com/readthedocs/readthedocs.org/pull/6191>`__)
48+
* `@davidfischer <http://github.com/davidfischer>`__: Update security docs (`#6179 <https://github.com/readthedocs/readthedocs.org/pull/6179>`__)
49+
* `@davidfischer <http://github.com/davidfischer>`__: Add the private spamfighting module to INSTALLED_APPS (`#6177 <https://github.com/readthedocs/readthedocs.org/pull/6177>`__)
50+
* `@davidfischer <http://github.com/davidfischer>`__: Document connected account permissions (`#6172 <https://github.com/readthedocs/readthedocs.org/pull/6172>`__)
51+
* `@stsewd <http://github.com/stsewd>`__: Require login for old redirect (`#6170 <https://github.com/readthedocs/readthedocs.org/pull/6170>`__)
52+
* `@humitos <http://github.com/humitos>`__: Remove old and unused code (`#6167 <https://github.com/readthedocs/readthedocs.org/pull/6167>`__)
53+
* `@stsewd <http://github.com/stsewd>`__: Clean up views (`#6166 <https://github.com/readthedocs/readthedocs.org/pull/6166>`__)
54+
* `@stsewd <http://github.com/stsewd>`__: Update docs for sharing (`#6164 <https://github.com/readthedocs/readthedocs.org/pull/6164>`__)
55+
* `@pyup-bot <http://github.com/pyup-bot>`__: pyup: Scheduled weekly dependency update for week 36 (`#6158 <https://github.com/readthedocs/readthedocs.org/pull/6158>`__)
56+
* `@saadmk11 <http://github.com/saadmk11>`__: Remove PR Builder Project Idea from RTD GSoC Docs (`#6147 <https://github.com/readthedocs/readthedocs.org/pull/6147>`__)
57+
* `@ericholscher <http://github.com/ericholscher>`__: Serialize time in search queries properly (`#6142 <https://github.com/readthedocs/readthedocs.org/pull/6142>`__)
58+
* `@humitos <http://github.com/humitos>`__: Allow to extend DomainCreate view (`#6139 <https://github.com/readthedocs/readthedocs.org/pull/6139>`__)
59+
* `@saadmk11 <http://github.com/saadmk11>`__: Integration Re-sync Bug Fix (`#6124 <https://github.com/readthedocs/readthedocs.org/pull/6124>`__)
60+
* `@stsewd <http://github.com/stsewd>`__: Don't log BuildEnvironmentWarning as error (`#6112 <https://github.com/readthedocs/readthedocs.org/pull/6112>`__)
61+
* `@dojutsu-user <http://github.com/dojutsu-user>`__: Add Search Guide (`#6101 <https://github.com/readthedocs/readthedocs.org/pull/6101>`__)
62+
* `@saadmk11 <http://github.com/saadmk11>`__: Add PR Builder guide to docs (`#6093 <https://github.com/readthedocs/readthedocs.org/pull/6093>`__)
63+
* `@dojutsu-user <http://github.com/dojutsu-user>`__: Record search queries smartly (`#6088 <https://github.com/readthedocs/readthedocs.org/pull/6088>`__)
64+
* `@dojutsu-user <http://github.com/dojutsu-user>`__: Remove 'highlight' URL param from search results (`#6087 <https://github.com/readthedocs/readthedocs.org/pull/6087>`__)
65+
166
Version 3.7.4
267
-------------
368

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
Loading
Loading

docs/_static/security/pgpkey.txt

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
-----BEGIN PGP PUBLIC KEY BLOCK-----
2+
Comment: GPGTools - http://gpgtools.org
3+
4+
mQINBFqNz1ABEADvgtp3LT1pV5wuTyBPaKrbWBFj10eKyQ15wfgyc2RR6Ix5QnBo
5+
6BcJ4fpgBhSwlngsrm0WU5kI/jH7ySwzbDpYCRiLvGJx+pEYLuBBOSm6r5M1N+FV
6+
xq3ShT4mHXhwPS1mKf9Xe+KlMdYa2e5TlBEr+TxGAmFFrOLjPxw6IDHgP3MVidr2
7+
iHA2PAATl6H9ZYvNzLkI2sP7h0V1/ADd43YpAK4yk6gdVjype5ez8lmoxDKNabMt
8+
dSfdOup8zy/fbC5KlxqrT9hHBkYfQWDLWXWcDW111q+ZvncujCrpONaY86bcQ3nn
9+
QgkeWCwj254vvqsrygEU93reC2onWaROUKoLlX1/1m2k2X3qze/hJRFZaljXVPKH
10+
jV/5q88EbjSUDgY5v9mdX8jhJAukx9HkOFdkMSh3RBgu1r+UPnCNd9K4T2nN0LBL
11+
c9NTG0HW7Di5ivEVq74SqDIeiVeOrfY/B6pRuUm/kNPcvZ+ZQPeNk6JUMqEemO9Q
12+
h0VHSkgkhCPWPO9c9wWJz7O6y6vXgsFG7BZg7mTVOiKbdgneGo/rKRvuBlQ7hCvP
13+
PklwyRn90SJSgv7NF6HMm4TA1R9mzp+90oXjrDXARXmGTsPtcDXFv7xqpK1+Mfcn
14+
ajEJYdIRNWVgx0E2RzHRipdG5MIQ5Plf4/GasVHl71nMGY06oIu1T+44MQARAQAB
15+
tFpSZWFkIHRoZSBEb2NzIFNlY3VyaXR5IFRlYW0gKGh0dHBzOi8vcmVhZHRoZWRv
16+
Y3Mub3JnL3NlY3VyaXR5LykgPHNlY3VyaXR5QHJlYWR0aGVkb2NzLm9yZz6JAk4E
17+
EwEIADgWIQRq+P453S2v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YzvsODN3LRQIGhet2
49+
NzjD41f5IrAlG/qFiC6s/YLj1DWanLw2nTzSi4x3v0Gc4DEXPebB3KvaNEmqoKGP
50+
5aXa9IPbvzEVCX82qjeqCPYAsYVOBQnFEAcnkrQ76363oJTeTHxK7kgewS2YCVyy
51+
7wVinR8eyrs+3AWrZ5Op817HgxGvAVDGOEK+1OX9g1wt+IdxX00s85/T+Zk9RF6H
52+
wtRaD9li
53+
=LjIC
54+
-----END PGP PUBLIC KEY BLOCK-----

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/commercial/sharing.rst

Lines changed: 29 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,30 +2,42 @@ Sharing
22
-------
33

44
.. note::
5-
This feature only exists on `Read the Docs for Business <https://readthedocs.com/>`_.
65

7-
You can share your project with users outside of your company.
8-
There are two ways to do this:
6+
This feature only exists on `Read the Docs for Business <https://readthedocs.com/>`__.
7+
8+
You can share your project with users outside of your company:
99

1010
* by sending them a *secret link*,
1111
* by giving them a *password*.
1212

1313
These methods will allow them to view a specific project inside your company.
1414

15+
Additionally, you can use a HTTP Authorization Header.
16+
This is useful to have access from a script.
17+
1518
Enabling
1619
~~~~~~~~
1720

1821
* Go into your *Project Admin* page and to the *Sharing* menu.
19-
* Under the *Share with someone new* heading, select the way you prefer (secret link or password), add an expiration date and a *Description* so you remember who you're sharing it with.
22+
* Under the *Share with someone new* heading, select the way you prefer (secret link, password, or HTTP header token),
23+
add an expiration date and a *Description* so you remember who you're sharing it with.
2024
* Click *Share!* to create.
2125
* Get the info needed to share your documentation with other users:
2226

2327
* If you have selected secret link, copy the link that is generated
2428
* In case of password, copy the link and password
29+
* For HTTP header token, you need to pass the ``Authorization`` header in your HTTP request.
2530

2631
* Give that information to the person who you want to give access.
2732

28-
.. note:: You can always revoke access in the same panel.
33+
.. note::
34+
35+
You can always revoke access in the same panel.
36+
37+
.. note::
38+
39+
Sharing using a password and a HTTP header token are currently in beta.
40+
If you want access to these features, email us to [email protected].
2941

3042
Effects
3143
~~~~~~~
@@ -40,6 +52,17 @@ Password
4052
********
4153

4254
Once the person you send the link to clicks on the link, they will see
43-
a *Authorization required* page asking them for the password you
55+
an *Authorization required* page asking them for the password you
4456
generated. When the user enters the password, they will have access to
4557
view your project.
58+
59+
HTTP Authorization Header
60+
*************************
61+
62+
You need to send the ``Authorization`` header with the token on each HTTP request.
63+
The header has the form ``Authorization: Token <ACCESS_TOKEN>``.
64+
For example:
65+
66+
.. prompt:: bash $
67+
68+
curl -H "Authorization: Token 19okmz5k0i6yk17jp70jlnv91v" https://docs.example.com/en/latest/example.html

0 commit comments

Comments
 (0)