Skip to content

Commit 1ab8473

Browse files
authored
Merge branch 'main' into spacy
2 parents 5a8bee4 + a265da0 commit 1ab8473

64 files changed

Lines changed: 1137 additions & 884 deletions

Some content is hidden

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

.github/workflows/docs.yml

Lines changed: 63 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,36 +13,93 @@ jobs:
1313
name: "Docs"
1414
runs-on: ubuntu-latest
1515
steps:
16-
- uses: actions/checkout@v2
17-
- uses: actions/setup-python@v2
16+
- uses: actions/checkout@v3
17+
with:
18+
fetch-depth: 0
19+
- uses: actions/setup-python@v4
1820
with:
1921
python-version: 3.8
2022
- name: Install dependencies
2123
run: |
2224
python -m pip install --upgrade pip
23-
python -m pip install -e .[dev]
25+
python -m pip install -e .[docs]
26+
- name: Set up Quarto
27+
uses: quarto-dev/quarto-actions/setup@v2
2428
- name: build docs
2529
run: |
2630
make docs
2731
- name: save docs
2832
uses: actions/upload-artifact@v3
2933
with:
3034
name: docs-html
31-
path: docs/_build/html/
35+
path: docs/_site
36+
# push to netlify -------------------------------------------------------
37+
38+
# set release name ----
39+
40+
- name: Configure pull release name
41+
if: ${{github.event_name == 'pull_request'}}
42+
run: |
43+
echo "RELEASE_NAME=pr-${PR_NUMBER}" >> $GITHUB_ENV
44+
env:
45+
PR_NUMBER: ${{ github.event.number }}
46+
- name: Configure branch release name
47+
if: ${{github.event_name != 'pull_request'}}
48+
run: |
49+
# use branch name, but replace slashes. E.g. feat/a -> feat-a
50+
echo "RELEASE_NAME=${GITHUB_REF_NAME/\//-}" >> $GITHUB_ENV
51+
# deploy ----
52+
53+
- name: Create Github Deployment
54+
uses: bobheadxi/deployments@v0.4.3
55+
id: deployment
56+
with:
57+
step: start
58+
token: ${{ secrets.GITHUB_TOKEN }}
59+
env: ${{ env.RELEASE_NAME }}
60+
ref: ${{ github.head_ref }}
61+
transient: true
62+
logs: 'https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}'
63+
64+
- name: Netlify docs preview
65+
run: |
66+
npm install -g netlify-cli
67+
# push main branch to production, others to preview --
68+
if [ "${ALIAS}" == "main" ]; then
69+
netlify deploy --dir=docs/_site --alias="main"
70+
else
71+
netlify deploy --dir=docs/_site --alias="${ALIAS}"
72+
fi
73+
env:
74+
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
75+
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
76+
ALIAS: ${{ steps.deployment.outputs.env }}
77+
78+
- name: Update Github Deployment
79+
uses: bobheadxi/deployments@v0.4.3
80+
if: ${{ always() }}
81+
with:
82+
step: finish
83+
token: ${{ secrets.GITHUB_TOKEN }}
84+
status: ${{ job.status }}
85+
deployment_id: ${{ steps.deployment.outputs.deployment_id }}
86+
env_url: 'https://${{ steps.deployment.outputs.env }}--relaxed-mooncake-704252.netlify.app'
87+
logs: 'https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}'
88+
3289
- name: publish dev docs
3390
if: github.ref_name == 'main' && github.ref_type == 'branch'
3491
uses: peaceiris/actions-gh-pages@v3
3592
with:
3693
github_token: ${{ secrets.GITHUB_TOKEN }}
37-
publish_dir: docs/_build/*
94+
publish_dir: docs/_site
3895
publish_branch: gh-pages
3996
destination_dir: main
4097
- name: publish stable docs
4198
if: github.ref_type == 'tag' && startswith(github.ref, 'refs/tags/v')
4299
uses: peaceiris/actions-gh-pages@v3
43100
with:
44101
github_token: ${{ secrets.GITHUB_TOKEN }}
45-
publish_dir: docs/_build/*
102+
publish_dir: docs/_site
46103
publish_branch: gh-pages
47104
destination_dir: ${{ github.ref_name }}
48105
- name: create symlink stable to new version

.github/workflows/precommit.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ jobs:
1313
name: "Run pre-commit"
1414
runs-on: ubuntu-latest
1515
steps:
16-
- uses: actions/checkout@v2
17-
- uses: actions/setup-python@v2
16+
- uses: actions/checkout@v3
17+
- uses: actions/setup-python@v4
1818
- uses: pre-commit/action@v2.0.3

.github/workflows/tests.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ jobs:
2525
python-version: '3.10'
2626

2727
steps:
28-
- uses: actions/checkout@v2
29-
- uses: actions/setup-python@v2
28+
- uses: actions/checkout@v3
29+
- uses: actions/setup-python@v4
3030
with:
3131
python-version: ${{ matrix.python-version }}
3232
- name: Install dependencies
@@ -44,8 +44,8 @@ jobs:
4444
runs-on: ubuntu-latest
4545
if: ${{ !github.event.pull_request.head.repo.fork }}
4646
steps:
47-
- uses: actions/checkout@v2
48-
- uses: actions/setup-python@v2
47+
- uses: actions/checkout@v3
48+
- uses: actions/setup-python@v4
4949
with:
5050
python-version: 3.8
5151
- name: Install dependencies
@@ -54,7 +54,7 @@ jobs:
5454
python -m pip install ".[dev]"
5555
python -m pip install --upgrade git+https://github.com/rstudio/vetiver-python@${{ github.sha }}
5656
echo {{ github.sha }}
57-
- name: run RStudio Connect
57+
- name: run Connect
5858
run: |
5959
docker-compose up --build -d
6060
pip freeze > requirements.txt
@@ -72,8 +72,8 @@ jobs:
7272
name: "Test Docker"
7373
runs-on: ubuntu-latest
7474
steps:
75-
- uses: actions/checkout@v2
76-
- uses: actions/setup-python@v2
75+
- uses: actions/checkout@v3
76+
- uses: actions/setup-python@v4
7777
with:
7878
python-version: 3.8
7979
- name: Install dependencies
@@ -97,8 +97,8 @@ jobs:
9797
name: "Test no exra ml frameworks"
9898
runs-on: ubuntu-latest
9999
steps:
100-
- uses: actions/checkout@v2
101-
- uses: actions/setup-python@v2
100+
- uses: actions/checkout@v3
101+
- uses: actions/setup-python@v4
102102
with:
103103
python-version: 3.8
104104
- name: Install dependencies

.github/workflows/weekly.yml

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ name: Weekly Tests
99
on:
1010
schedule:
1111
- cron: "03 14 * * MON"
12+
push:
13+
branches: ['update-weekly']
1214

1315
jobs:
1416
vetiver_main_pins_main:
@@ -23,9 +25,9 @@ jobs:
2325

2426

2527
steps:
26-
- uses: actions/checkout@v2
28+
- uses: actions/checkout@v3
2729

28-
- uses: actions/setup-python@v2
30+
- uses: actions/setup-python@v4
2931
with:
3032
python-version: ${{ matrix.python-version }}
3133

@@ -35,7 +37,7 @@ jobs:
3537
python -m pip install '.[all]'
3638
python -m pip install --upgrade git+https://github.com/rstudio/pins-python
3739
38-
- name: run RStudio Connect
40+
- name: run Connect
3941
run: |
4042
docker-compose up --build -d
4143
make dev
@@ -72,7 +74,7 @@ jobs:
7274
with:
7375
ref: ${{ steps.latestrelease.outputs.releasetag }}
7476

75-
- uses: actions/setup-python@v2
77+
- uses: actions/setup-python@v4
7678
with:
7779
python-version: ${{ matrix.python-version }}
7880

@@ -82,7 +84,7 @@ jobs:
8284
python -m pip install .[dev]
8385
python -m pip install --upgrade git+https://github.com/rstudio/pins-python
8486
85-
- name: run RStudio Connect
87+
- name: run Connect
8688
run: |
8789
docker-compose up --build -d
8890
make dev
@@ -101,7 +103,7 @@ jobs:
101103
strategy:
102104
matrix:
103105
# Minimum and Maximum supported versions
104-
python-version: ['3.10']
106+
python-version: ['3.9']
105107

106108
steps:
107109
- name: Get latest release with tag from GitHub API
@@ -118,7 +120,7 @@ jobs:
118120
with:
119121
ref: ${{ steps.latestrelease.outputs.releasetag }}
120122

121-
- uses: actions/setup-python@v2
123+
- uses: actions/setup-python@v4
122124
with:
123125
python-version: ${{ matrix.python-version }}
124126

@@ -129,7 +131,7 @@ jobs:
129131
python -m pip install --upgrade git+https://github.com/rstudio/rsconnect-python
130132
pip freeze > requirements.txt
131133
132-
- name: run RStudio Connect
134+
- name: run Connect
133135
run: |
134136
docker-compose up --build -d
135137
make dev
@@ -148,12 +150,12 @@ jobs:
148150
strategy:
149151
matrix:
150152
# Minimum and Maximum supported versions
151-
python-version: ['3.10']
153+
python-version: ['3.9']
152154

153155
steps:
154-
- uses: actions/checkout@v2
156+
- uses: actions/checkout@v3
155157

156-
- uses: actions/setup-python@v2
158+
- uses: actions/setup-python@v4
157159
with:
158160
python-version: ${{ matrix.python-version }}
159161

@@ -164,7 +166,7 @@ jobs:
164166
python -m pip install --upgrade git+https://github.com/rstudio/rsconnect-python
165167
pip freeze > requirements.txt
166168
167-
- name: run RStudio Connect
169+
- name: run Connect
168170
run: |
169171
docker-compose up --build -d
170172
make dev

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,3 +142,5 @@ NOTES.md
142142
## RStudio
143143
*.Rproj
144144
.Rproj.user
145+
146+
/.quarto/

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11

22

3-
exclude: "(.*\\.csv)|(^examples/)|(^vetiver/tests/snapshots/)"
3+
exclude: "(.*\\.csv)|(^examples/)|(^vetiver/tests/snapshots/)|(^docs/_extensions/)"
44
repos:
55
- repo: https://github.com/pre-commit/pre-commit-hooks
66
rev: v2.4.0

CODE_OF_CONDUCT.md

Lines changed: 24 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ We as members, contributors, and leaders pledge to make participation in our
66
community a harassment-free experience for everyone, regardless of age, body
77
size, visible or invisible disability, ethnicity, sex characteristics, gender
88
identity and expression, level of experience, education, socio-economic status,
9-
nationality, personal appearance, race, religion, or sexual identity and
10-
orientation.
9+
nationality, personal appearance, race, caste, color, religion, or sexual
10+
identity and orientation.
1111

1212
We pledge to act and interact in ways that contribute to an open, welcoming,
1313
diverse, inclusive, and healthy community.
@@ -21,25 +21,25 @@ community include:
2121
* Being respectful of differing opinions, viewpoints, and experiences
2222
* Giving and gracefully accepting constructive feedback
2323
* Accepting responsibility and apologizing to those affected by our mistakes,
24-
and learning from the experience
24+
and learning from the experience
2525
* Focusing on what is best not just for us as individuals, but for the overall
26-
community
26+
community
2727

2828
Examples of unacceptable behavior include:
2929

30-
* The use of sexualized language or imagery, and sexual attention or
31-
advances of any kind
30+
* The use of sexualized language or imagery, and sexual attention or advances of
31+
any kind
3232
* Trolling, insulting or derogatory comments, and personal or political attacks
3333
* Public or private harassment
34-
* Publishing others' private information, such as a physical or email
35-
address, without their explicit permission
34+
* Publishing others' private information, such as a physical or email address,
35+
without their explicit permission
3636
* Other conduct which could reasonably be considered inappropriate in a
37-
professional setting
37+
professional setting
3838

3939
## Enforcement Responsibilities
4040

41-
Community leaders are responsible for clarifying and enforcing our standards
42-
of acceptable behavior and will take appropriate and fair corrective action in
41+
Community leaders are responsible for clarifying and enforcing our standards of
42+
acceptable behavior and will take appropriate and fair corrective action in
4343
response to any behavior that they deem inappropriate, threatening, offensive,
4444
or harmful.
4545

@@ -50,17 +50,17 @@ decisions when appropriate.
5050

5151
## Scope
5252

53-
This Code of Conduct applies within all community spaces, and also applies
54-
when an individual is officially representing the community in public spaces.
55-
Examples of representing our community include using an official e-mail
56-
address, posting via an official social media account, or acting as an appointed
53+
This Code of Conduct applies within all community spaces, and also applies when
54+
an individual is officially representing the community in public spaces.
55+
Examples of representing our community include using an official e-mail address,
56+
posting via an official social media account, or acting as an appointed
5757
representative at an online or offline event.
5858

5959
## Enforcement
6060

6161
Instances of abusive, harassing, or otherwise unacceptable behavior may be
62-
reported to the community leaders responsible for enforcement at [INSERT CONTACT
63-
METHOD]. All complaints will be reviewed and investigated promptly and fairly.
62+
reported to the community leaders responsible for enforcement at codeofconduct@posit.co.
63+
All complaints will be reviewed and investigated promptly and fairly.
6464

6565
All community leaders are obligated to respect the privacy and security of the
6666
reporter of any incident.
@@ -114,15 +114,13 @@ community.
114114
## Attribution
115115

116116
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
117-
version 2.0,
118-
available at https://www.contributor-covenant.org/version/2/0/
119-
code_of_conduct.html.
117+
version 2.1, available at
118+
<https://www.contributor-covenant.org/version/2/1/code_of_conduct.html>.
120119

121-
Community Impact Guidelines were inspired by [Mozilla's code of conduct
122-
enforcement ladder](https://github.com/mozilla/diversity).
123-
124-
[homepage]: https://www.contributor-covenant.org
120+
Community Impact Guidelines were inspired by
121+
[Mozilla's code of conduct enforcement ladder][https://github.com/mozilla/inclusion].
125122

126123
For answers to common questions about this code of conduct, see the FAQ at
127-
https://www.contributor-covenant.org/faq. Translations are available at https://
128-
www.contributor-covenant.org/translations.
124+
<https://www.contributor-covenant.org/faq>. Translations are available at <https://www.contributor-covenant.org/translations>.
125+
126+
[homepage]: https://www.contributor-covenant.org

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2021 Isabel Zimmerman
3+
Copyright (c) 2021 vetiver authors
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

MAINTAINERS.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Who maintains Vetiver
2+
3+
The vetiver package was created by and is currently maintained by Isabel Zimmerman <isabel.zimmerman@posit.co>. [Posit Software, PBC](https://posit.co/products/open-source/) is a copyright holder and funder of the vetiver package.
4+
5+
Several individuals in the community have taken an active role in helping to maintain vetiver and submit fixes. Those individuals are shown in the git changelog.

0 commit comments

Comments
 (0)