Skip to content

Commit

Permalink
Restore and update quickstart docs page (#296)
Browse files Browse the repository at this point in the history
* Revert "Temporarily remove quickstart docs (#292)"

This reverts commit 2dc0ae2.

* Load ArviZPythonPlots before running notebook

* Add ArviZPythonPlots as docs dep

* Load ArviZPythonPlots in notebook

* Document use of ArviZPythonPlots

* Refer to ArviZ instead of ArviZ.jl

* Increment patch number

* Instantiate docs environment before resolving

* Use Conda Python

* Install Python deps manually

* Fix step

* Add ArviZPythonPlots docs compat

* Add back docs deps compats

* Remove SampleChains as unused docs dep

* Remove docs Manifest.toml

* Make docs-specific `.gitignore`

* Remove unneeded loads

* Increase ArviZ version bound

* Fix broken links

* Allow linkcheck to fail

* Increment patch number

* Cache CondaPkg artifacts for docs build
  • Loading branch information
sethaxen authored Aug 9, 2023
1 parent c1ae419 commit 99e7360
Show file tree
Hide file tree
Showing 9 changed files with 498 additions and 18 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/CompatHelper.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,6 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COMPATHELPER_PRIV: ${{ secrets.DOCUMENTER_KEY }}
run: julia --color=yes -e 'using CompatHelper; CompatHelper.main()'
run: |
using CompatHelper
CompatHelper.main(; subdirs=["", "docs"])
23 changes: 23 additions & 0 deletions .github/workflows/documenter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ on:
schedule:
- cron: "0 0 * * *"

env:
CMDSTAN_VERSION: "2.25.0"
CMDSTAN_PATH: "${{ GITHUB.WORKSPACE }}/.cmdstan/"
JULIA_NUM_THREADS: 2

jobs:
docs:
name: Documentation
Expand All @@ -15,12 +20,30 @@ jobs:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
- uses: julia-actions/cache@v1
- name: Cache CondaPkg
id: cache-condaPkg
uses: actions/cache@v3
env:
cache-name: cache-condapkg
with:
path: docs/.CondaPkg
key: ${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('docs/CondaPkg.toml') }}
restore-keys: |
${{ runner.os }}-${{ env.cache-name }}-
- name: Download and build CmdStan
if: steps.cache-cmdstan.outputs.cache-hit != 'true'
run: |
wget -P ${{ env.CMDSTAN_PATH }} https://github.com/stan-dev/cmdstan/releases/download/v${{ env.CMDSTAN_VERSION }}/cmdstan-${{ env.CMDSTAN_VERSION }}.tar.gz
tar -xzpf ${{ env.CMDSTAN_PATH }}/cmdstan-${{ env.CMDSTAN_VERSION }}.tar.gz -C ${{ env.CMDSTAN_PATH }}
make -C ${{ env.CMDSTAN_PATH }}/cmdstan-${{ env.CMDSTAN_VERSION }}/ build
shell: bash
- uses: julia-actions/julia-buildpkg@v1
- name: Install dependencies
run: julia --color=yes --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=pwd())); Pkg.instantiate()'
- uses: julia-actions/julia-docdeploy@v1
with:
install-package: false
env:
JULIA_CMDSTAN_HOME: ${{ env.CMDSTAN_PATH }}/cmdstan-${{ env.CMDSTAN_VERSION }}/ # required by CmdStan.jl
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
10 changes: 1 addition & 9 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,14 +1,6 @@
*.jl.cov
*.jl.*.cov
*.jl.mem
/deps/deps.jl
/deps/build.log
/docs/src/quickstart.md
/docs/src/creating_custom_plots.md
/docs/src/*.log
/docs/src/assets/logo*.png
/docs/src/assets/favicon.ico
/docs/src/*.log
/docs/build
/test/*.log
.DS_Store
Manifest.toml
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "ArviZ"
uuid = "131c737c-5715-5e2e-ad31-c244f01c1dc7"
authors = ["Seth Axen <[email protected]>"]
version = "0.10.1"
version = "0.10.2"

[deps]
InferenceObjects = "b5cf5a8d-e756-4ee3-b014-01d49d192c00"
Expand Down
9 changes: 9 additions & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
Manifest.toml
.CondaPkg
src/quickstart.md
src/creating_custom_plots.md
src/*.log
src/assets/logo*.png
src/assets/favicon.ico
src/*.log
build
28 changes: 25 additions & 3 deletions docs/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
AlgebraOfGraphics = "cbdf2221-f076-402e-a563-3d30da359d67"
ArviZ = "131c737c-5715-5e2e-ad31-c244f01c1dc7"
ArviZExampleData = "2f96bb34-afd9-46ae-bcd0-9b2d4372fe3c"
ArviZPythonPlots = "4a6e88f0-2c8e-11ee-0601-e94153f0eada"
CairoMakie = "13f3f980-e62b-5c42-98c6-ff1f3baf88f0"
DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0"
DimensionalData = "0703355e-b756-11e9-17c0-8b28908087d0"
Expand All @@ -11,14 +12,35 @@ Downloads = "f43a241f-c20a-4ad4-852c-f6b1247861c6"
EvoTrees = "f6006082-12f8-11e9-0c9c-0d5d367ab1e5"
InferenceObjects = "b5cf5a8d-e756-4ee3-b014-01d49d192c00"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
MCMCChains = "c7f686f2-ff18-58e9-bc7b-31028e88f75d"
MCMCDiagnosticTools = "be115224-59cd-429b-ad48-344e309966f0"
MLJBase = "a7f614a8-145f-11e9-1d2a-a57a1082229d"
MLJIteration = "614be32b-d00c-4edb-bd02-1eb411ab5e55"
PSIS = "ce719bf2-d5d0-4fb9-925d-10a81b42ad04"
PlutoStaticHTML = "359b1769-a58e-495b-9770-312e911026ad"
PlutoUI = "7f904dfe-b85e-4ff6-b463-dae2292396a8"
PosteriorStats = "7f36be82-ad55-44ba-a5c0-b8b5480d7aa5"
SampleChains = "754583d1-7fc4-4dab-93b5-5eaca5c9622e"
Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2"
StanSample = "c1514b29-d3a0-5178-b312-660c88baa699"
StatsBase = "2913bbd2-ae8a-5f71-8c99-4fb6c76f3a91"
Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2"
Turing = "fce5fe82-541a-59a6-adf8-730c64b5f9a0"

[compat]
AlgebraOfGraphics = "0.6.9"
ArviZ = ">=0.10"
ArviZExampleData = "0.1.5"
ArviZPythonPlots = "0.1"
CairoMakie = "0.8.9, 0.9, 0.10"
DataFrames = "1"
DimensionalData = "0.23, 0.24"
Distributions = "0.25"
Documenter = "0.27"
EvoTrees = "0.14.8, 0.15"
MCMCDiagnosticTools = "0.3"
MLJBase = "0.21.6"
MLJIteration = "0.5.1"
PlutoStaticHTML = "4.0.5, 5, 6"
PlutoUI = "0.7"
PosteriorStats = "0.1.1"
StanSample = "7.0.1"
StatsBase = "0.32, 0.33, 0.34"
Turing = "0.24.1, 0.25, 0.26, 0.27, 0.28"
6 changes: 3 additions & 3 deletions docs/make.jl
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using Documenter, Downloads, ArviZ
using MCMCChains: MCMCChains # make `from_mcmcchains` available for API docs
using SampleChains: SampleChains # make `from_samplechains` available for API docs
using PlutoStaticHTML: PlutoStaticHTML

const DOCS_SRC_PATH = joinpath(@__DIR__, "src")
Expand Down Expand Up @@ -75,6 +73,7 @@ makedocs(;
pages=[
"Home" => "index.md",
"Getting Started" => [
"Quickstart" => "quickstart.md",
"Working with `InferenceData`" => "working_with_inference_data.md",
"Creating custom plots" => "creating_custom_plots.md",
],
Expand All @@ -99,7 +98,8 @@ makedocs(;
doctestfilters,
linkcheck=true,
analytics="G-W1G68W77YV",
strict=Documenter.except(:footnote, :missing_docs),
# allow linkcheck to fail so we can use pretty links to PlutoStaticHTML notebooks
strict=Documenter.except(:footnote, :linkcheck, :missing_docs),
)

deploydocs(; repo="github.com/arviz-devs/ArviZ.jl.git", devbranch="main", push_preview=true)
2 changes: 1 addition & 1 deletion docs/src/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ pkg> add ArviZ

## [Usage](@id usage)

See the [API Overview](@ref api) for description of functions.
See the [Quickstart](./quickstart) for example usage and the [API Overview](@ref api) for description of functions.

## [Extending ArviZ.jl](@id extendingarviz)

Expand Down
Loading

2 comments on commit 99e7360

@sethaxen
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/89344

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.10.2 -m "<description of version>" 99e736049014d817674012e1a53d021023f1fb9d
git push origin v0.10.2

Please sign in to comment.