Skip to content

Commit 054b7f1

Browse files
committed
Merge tag '5.12.0' into rel
2 parents 7318c68 + 3c9dafe commit 054b7f1

File tree

80 files changed

+1637
-11186
lines changed

Some content is hidden

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

80 files changed

+1637
-11186
lines changed

CHANGELOG.rst

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,41 @@
1+
Version 5.12.0
2+
--------------
3+
4+
:Date: March 08, 2021
5+
6+
* `@pyup-bot <https://github.com/pyup-bot>`__: pyup: Scheduled weekly dependency update for week 10 (`#7995 <https://github.com/readthedocs/readthedocs.org/pull/7995>`__)
7+
* `@saadmk11 <https://github.com/saadmk11>`__: Remove json field from RemoteRepositoryRelation and RemoteOrganizationRelation model (`#7993 <https://github.com/readthedocs/readthedocs.org/pull/7993>`__)
8+
* `@humitos <https://github.com/humitos>`__: Use independent Docker image to build assets (`#7992 <https://github.com/readthedocs/readthedocs.org/pull/7992>`__)
9+
* `@Pradhvan <https://github.com/Pradhvan>`__: Fixes typo in getting-started-with-sphinx: (`#7991 <https://github.com/readthedocs/readthedocs.org/pull/7991>`__)
10+
* `@stsewd <https://github.com/stsewd>`__: Search: use doctype from indexed pages instead of the db (`#7984 <https://github.com/readthedocs/readthedocs.org/pull/7984>`__)
11+
* `@humitos <https://github.com/humitos>`__: Allow `donate` app to use Stripe Checkout for one-time donations (`#7983 <https://github.com/readthedocs/readthedocs.org/pull/7983>`__)
12+
* `@humitos <https://github.com/humitos>`__: Update development/standards guide (`#7981 <https://github.com/readthedocs/readthedocs.org/pull/7981>`__)
13+
* `@stsewd <https://github.com/stsewd>`__: Docs: update expand_tabs to work with the latest version of sphinx-tabs (`#7979 <https://github.com/readthedocs/readthedocs.org/pull/7979>`__)
14+
* `@ericholscher <https://github.com/ericholscher>`__: Fix build routing (`#7978 <https://github.com/readthedocs/readthedocs.org/pull/7978>`__)
15+
* `@stsewd <https://github.com/stsewd>`__: Builds: register tasks to delete inactive external versions (`#7975 <https://github.com/readthedocs/readthedocs.org/pull/7975>`__)
16+
* `@stsewd <https://github.com/stsewd>`__: Embed: fix join (`#7974 <https://github.com/readthedocs/readthedocs.org/pull/7974>`__)
17+
* `@stsewd <https://github.com/stsewd>`__: Embed: change proxied urls (`#7973 <https://github.com/readthedocs/readthedocs.org/pull/7973>`__)
18+
* `@ericholscher <https://github.com/ericholscher>`__: refactor footer, add jobs & status page (`#7970 <https://github.com/readthedocs/readthedocs.org/pull/7970>`__)
19+
* `@stsewd <https://github.com/stsewd>`__: Sphinx domain: remove API (`#7969 <https://github.com/readthedocs/readthedocs.org/pull/7969>`__)
20+
* `@humitos <https://github.com/humitos>`__: Upgrade `postgres-client` to v12 in Docker image (`#7967 <https://github.com/readthedocs/readthedocs.org/pull/7967>`__)
21+
* `@saadmk11 <https://github.com/saadmk11>`__: Add management command to Load Project and RemoteRepository Relationship from JSON file (`#7966 <https://github.com/readthedocs/readthedocs.org/pull/7966>`__)
22+
* `@astrojuanlu <https://github.com/astrojuanlu>`__: Update guide on conda support (`#7965 <https://github.com/readthedocs/readthedocs.org/pull/7965>`__)
23+
* `@stsewd <https://github.com/stsewd>`__: Embed: add more tests (`#7962 <https://github.com/readthedocs/readthedocs.org/pull/7962>`__)
24+
* `@humitos <https://github.com/humitos>`__: Lower rank of development/install.html (`#7960 <https://github.com/readthedocs/readthedocs.org/pull/7960>`__)
25+
* `@stsewd <https://github.com/stsewd>`__: Embed: refactor view (`#7955 <https://github.com/readthedocs/readthedocs.org/pull/7955>`__)
26+
* `@stsewd <https://github.com/stsewd>`__: Search: make --queue required for management command (`#7952 <https://github.com/readthedocs/readthedocs.org/pull/7952>`__)
27+
* `@ericholscher <https://github.com/ericholscher>`__: Add proxito healthcheck (`#7948 <https://github.com/readthedocs/readthedocs.org/pull/7948>`__)
28+
* `@Pradhvan <https://github.com/Pradhvan>`__: Docs: Adds Myst to the getting started with sphinx (`#7938 <https://github.com/readthedocs/readthedocs.org/pull/7938>`__)
29+
* `@ericholscher <https://github.com/ericholscher>`__: Add a support form to the website (`#7929 <https://github.com/readthedocs/readthedocs.org/pull/7929>`__)
30+
* `@humitos <https://github.com/humitos>`__: Use Stripe Checkout for Gold Users (`#7889 <https://github.com/readthedocs/readthedocs.org/pull/7889>`__)
31+
* `@stsewd <https://github.com/stsewd>`__: Docs: guide about reproducible builds (`#7888 <https://github.com/readthedocs/readthedocs.org/pull/7888>`__)
32+
* `@stsewd <https://github.com/stsewd>`__: Docs: update links from build images (`#7886 <https://github.com/readthedocs/readthedocs.org/pull/7886>`__)
33+
* `@stsewd <https://github.com/stsewd>`__: Install latest mkdocs by default as we do with sphinx (`#7869 <https://github.com/readthedocs/readthedocs.org/pull/7869>`__)
34+
* `@stsewd <https://github.com/stsewd>`__: Docs: document analytics (`#7857 <https://github.com/readthedocs/readthedocs.org/pull/7857>`__)
35+
* `@stsewd <https://github.com/stsewd>`__: Remove some feature flags (`#7846 <https://github.com/readthedocs/readthedocs.org/pull/7846>`__)
36+
* `@stsewd <https://github.com/stsewd>`__: Update requirements/deploy.txt (`#7843 <https://github.com/readthedocs/readthedocs.org/pull/7843>`__)
37+
* `@humitos <https://github.com/humitos>`__: Implementation of APIv3 (`#4863 <https://github.com/readthedocs/readthedocs.org/pull/4863>`__)
38+
139
Version 5.11.0
240
--------------
341

common

dockerfiles/Dockerfile

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,23 @@ RUN apt-get -y install \
2020
build-essential \
2121
python3-pip \
2222
python3-dev \
23-
postgresql-client \
2423
libmysqlclient-dev \
2524
libfreetype6 \
2625
libjpeg-dev \
2726
sqlite \
2827
netcat \
2928
telnet
3029

30+
# https://www.postgresql.org/download/linux/ubuntu/
31+
# Use PostgreSQL client 12 from official PostgreSQL Ubuntu's repository to avoid this WARNING
32+
# WARNING: psql major version 10, server major version 12.
33+
# Some psql features might not work.
34+
# TODO: remove this when upgrading to Ubuntu 20.04 LTS
35+
RUN sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
36+
RUN curl -s https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add -
37+
RUN apt-get -y update
38+
RUN apt-get -y install postgresql-client-12
39+
3140
# Uncomment en_US.UTF-8 locale and generate it
3241
RUN sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen && \
3342
locale-gen

dockerfiles/docker-compose-assets.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
version: '3'
2+
3+
services:
4+
assets:
5+
image: node:8.16
6+
volumes:
7+
- ${PWD}:/usr/src/app/readthedocs.org
8+
working_dir: /usr/src/app/readthedocs.org

docs/Makefile

Lines changed: 3 additions & 3 deletions
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
5+
SPHINXOPTS =
66
SPHINXBUILD = sphinx-build
77
PAPER =
88
BUILDDIR = _build
@@ -53,7 +53,7 @@ clean:
5353
rm -rf $(BUILDDIR)/*
5454

5555
auto:
56-
sphinx-autobuild -p 8888 $(ALLSPHINXOPTS) $(BUILDDIR)/html
56+
sphinx-autobuild --port 8888 $(ALLSPHINXOPTS) $(BUILDDIR)/html
5757
@echo
5858
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
5959

@@ -63,7 +63,7 @@ html:
6363
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
6464

6565
livehtml:
66-
sphinx-autobuild -p 4444 -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
66+
sphinx-autobuild --port 4444 -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
6767

6868

6969
dirhtml:
234 KB
Loading

docs/_static/js/expand_tabs.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ $( document ).ready(function() {
99
const urlParams = new URLSearchParams(window.location.search);
1010
const tabName = urlParams.get('tab');
1111
if (tabName !== null) {
12-
const tab = $('a.item > div:contains("' + tabName + '")');
12+
const tab = $('button.sphinx-tabs-tab:contains("' + tabName + '")');
1313
if (tab.length > 0) {
1414
tab.click();
1515
}

docs/analytics.rst

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
Analytics
2+
---------
3+
4+
Analytics lets you see *which* documents your users are reading.
5+
This allows you to understand how your documentation is being used,
6+
so you can focus on expanding and updating parts people are reading most.
7+
8+
To see a list of the top pages from the last month,
9+
go to the :guilabel:`Admin` tab of your project,
10+
and then click on :guilabel:`Traffic Analytics`.
11+
12+
.. figure:: /_static/images/traffic-analytics-demo.png
13+
:width: 50%
14+
:align: center
15+
:alt: Traffic analytics demo
16+
17+
Traffic analytics demo
18+
19+
You can also access to analytics data from :ref:`search results <server-side-search:analytics>`.
20+
21+
.. note::
22+
23+
If you require more information about page views,
24+
you can use a solution like :doc:`Google Analytics </guides/google-analytics>`.

docs/builds.rst

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,9 +67,7 @@ An example in code:
6767
.. note::
6868

6969
Regardless of whether you build your docs with Sphinx or MkDocs,
70-
we recommend you pin the version of Sphinx or Mkdocs you want us to use.
71-
You can do this the same way other
72-
:doc:`dependencies are specified <guides/specifying-dependencies>`.
70+
we recommend you :ref:`pinning the version <guides/reproducible-builds:pinning dependencies>` of Sphinx or Mkdocs you want us to use.
7371
Some examples of pinning versions might be ``sphinx<2.0`` or ``mkdocs>=1.0``.
7472

7573
Build environment

docs/commercial/analytics.rst

Lines changed: 0 additions & 22 deletions
This file was deleted.

docs/commercial/index.rst

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,4 +36,3 @@ Advertising-free
3636
single-sign-on
3737
sharing
3838
privacy-level
39-
analytics

docs/config-file/v2.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -319,8 +319,8 @@ The Docker image used for building the docs.
319319
Each image support different Python versions and has different packages installed,
320320
as defined here:
321321

322-
* `stable <https://github.com/readthedocs/readthedocs-docker-images/tree/releases/4.x>`_: :buildpyversions:`stable`
323-
* `latest <https://github.com/readthedocs/readthedocs-docker-images/tree/releases/5.x>`_: :buildpyversions:`latest`
322+
* `stable <https://github.com/readthedocs/readthedocs-docker-images/tree/releases/5.x>`_: :buildpyversions:`stable`
323+
* `latest <https://github.com/readthedocs/readthedocs-docker-images/tree/releases/6.x>`_: :buildpyversions:`latest`
324324

325325
sphinx
326326
~~~~~~

docs/development/front-end.rst

Lines changed: 6 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -55,43 +55,22 @@ in.
5555
Getting Started
5656
---------------
5757

58-
You will need a working version of Node (tested with ``v10.17.0``) and NPM to get started.
59-
We won't cover that here, as it varies from platform to platform.
60-
61-
To install these tools and dependencies::
62-
63-
npm install
64-
65-
Next, install front end dependencies::
66-
67-
bower install
58+
You will need to follow our :doc:`guide to install a development Read the Docs instance </development/standards>` first.
6859

6960
The sources for our bundles are found in the per-application path
7061
``static-src``, which has the same directory structure as ``static``. Files in
7162
``static-src`` are compiled to ``static`` for static file collection in Django.
7263
Don't edit files in ``static`` directly, unless you are sure there isn't a
7364
source file that will compile over your changes.
7465

75-
To test changes while developing, which will watch source files for changes and
76-
compile as necessary, you can run `Gulp`_ with our development target::
77-
78-
npm run dev
66+
To compile your changes and make them available in the application you need to run::
7967

80-
Once you are satisfied with your changes, finalize the bundles (this will
81-
minify library sources)::
68+
inv docker.buildassets
8269

83-
npm run build
84-
85-
If you updated any of our vendor libraries, compile those::
86-
87-
npm run vendor
88-
89-
Make sure to check in both files under ``static`` and ``static-src``.
90-
91-
.. note::
70+
Once you are happy with your changes,
71+
make sure to check in both files under ``static`` and ``static-src``,
72+
and commit those.
9273

93-
We run Gulp through an ``npm`` script in order to ensure
94-
that the correct version from ``package.json`` is used.
9574

9675
Making Changes
9776
--------------

docs/development/standards.rst

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,6 @@ Core team members expect to have a development environment that closely
1313
approximates our production environment, in order to spot bugs and logical
1414
inconsistencies before they make their way to production.
1515

16-
Currently, core team members are migrating to a Docker Compose based
17-
solution that is not yet recommended for contributing to development.
18-
1916
This solution gives us many features that allows us to have an
2017
environment closer to production:
2118

@@ -73,6 +70,12 @@ After cloning ``readthedocs.org`` repository, you need to
7370

7471
#. install `Docker <https://www.docker.com/>`_ following `their installation guide <https://docs.docker.com/install/>`_.
7572

73+
#. clone the ``readthedocs.org`` repository:
74+
75+
.. prompt:: bash
76+
77+
git clone --recurse-submodules https://github.com/readthedocs/readthedocs.org/
78+
7679
#. install the requirements from ``common`` submodule:
7780

7881
.. prompt:: bash
@@ -158,6 +161,10 @@ save some work while typing docker compose commands. This section explains these
158161
you can run ``inv docker.attach web`` and jump into a pdb session
159162
(it also works with ipdb and pdb++)
160163

164+
.. tip::
165+
166+
You can hit CTRL-p CTRL-p to detach it without stopping the running process.
167+
161168
``inv docker.test``
162169
Runs all the test suites inside the container.
163170

@@ -168,10 +175,13 @@ save some work while typing docker compose commands. This section explains these
168175

169176
* ``--only-latest`` does not pull ``stable`` and ``testing`` images.
170177

178+
``inv docker.buildassets``
179+
Build all the assets and "deploy" them to the storage.
180+
171181
Adding a new Python dependency
172182
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
173183

174-
The Docker image for the servers is built with the requirements defined in the ``master`` branch.
184+
The Docker image for the servers is built with the requirements defined in the current checked out branch.
175185
In case you need to add a new Python dependency while developing,
176186
you can use the ``common/dockerfiles/entrypoints/common.sh`` script as shortcut.
177187

@@ -184,7 +194,7 @@ To do this, add the ``pip`` command required for your dependency in ``common.sh`
184194
# common.sh
185195
pip install my-dependency==1.2.3
186196
187-
Once the PR that adds this dependency was merged into ``master``, you can rebuild the image
197+
Once the PR that adds this dependency was merged, you can rebuild the image
188198
so the dependency is added to the Docker image itself and it's not needed to be installed
189199
each time the container spins up.
190200

docs/faq.rst

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ My documentation requires additional dependencies
3333
-------------------------------------------------
3434

3535
For most Python dependencies, you can can specify a requirements file
36-
which details your dependencies. See our guide on :doc:`/guides/specifying-dependencies`.
36+
which details your dependencies. See our guide on :ref:`guides/reproducible-builds:using a configuration file`.
3737
You can also set your project documentation to install your project itself
3838
as a dependency.
3939

@@ -216,8 +216,7 @@ and as a result, it tends to look a bit better with the default theme.
216216
.. note::
217217

218218
To use these extensions you need to specify the dependencies on your project
219-
by following this :doc:`guide <guides/specifying-dependencies>`.
220-
219+
by following this :ref:`guide <guides/reproducible-builds:using a configuration file>`.
221220

222221
Can I document a python package that is not at the root of my repository?
223222
-------------------------------------------------------------------------

0 commit comments

Comments
 (0)