Releases: lsst-sqre/times-square
0.9.0
Backwards-incompatible changes
- New treatment for templating in notebooks. Times Square no longer treats all cells as Jinja templates. Instead, the first cell is considered to be under the control of Times Square for setting variables. When a parameters are rendered into a notebook, the first code cell is replaced with new source that sets the parameter variables to their values. This means that notebook authors can now use that first cell to set and experiment with parameter values for interactive debugging, knowing that Times Square will replace that cell with new values when the notebook is rendered.
Bug fixes
- Parameter names are now validated against Python keyword names using
keyword.iskeyword()
. This prevents parameter names from shadowing Python keywords.
What's Changed
- DM-40188: Replace first code cells with parameters by @jonathansick in #54
Full Changelog: 0.8.0...0.9.0
0.8.0
New features
- Add a new
TS_GITHUB_ORGS
environment variable. This can be set to a comma-separated list of GitHub organizations that can install the Times Square GitHub App and sync notebooks into the Times Square service. This is a an important security feature if the Times Square GitHub App is set to public so that multiple GitHub organizations can sync repositories with Times Square. GitHub webhook handlers filter out events from non-accepted organizations. TheGitHubRepoService
also checks the ownership on initialization.
Other changes
-
Adopt scriv for managing the changelog.
-
Adopt ruff for linting, and update the codebase accordingly.
-
Adopt the new neophile workflow for managing dependencies.
-
Adopt the new
lsst-sqre/build-and-push-to-ghcr
GitHub Action for building and pushing Docker images. -
Adopt the new FastAPI lifespan function for handling start-up and shutdown.
-
Create a Sphinx documentation site at
times-square.lsst.io
. -
Add documentation for configuring the Times Square GitHub App, including a sample URL with the app settings built-in.
What's Changed
- Bump docker/build-push-action from 3 to 4 by @dependabot in #48
- DM-40142: Infrastructure upgrades by @jonathansick in #52
- DM-40187: Add an "accept list" of GitHub organizations by @jonathansick in #53
Full Changelog: 0.7.0...0.8.0
0.7.0
- Adopt
safir.redis.pydantic
for Redis-backed storage. - Adopt
safir.github
creating the GitHub App client and modelling of GitHub resources with Pydantic. - Fix handling of disabled pages so that they aren't executed in a GitHub check, and are dropped if they previously existed in the database.
- Update to Python 3.11
What's Changed
- Bump python from 3.10.6-slim-bullseye to 3.10.7-slim-bullseye by @dependabot in #44
- DM-38650: Adopt safir.redis and safir.github modules by @jonathansick in #50
Full Changelog: 0.6.0...0.7.0
0.6.0
Times Square now exposes information about pages created during GitHub PR check runs:
GET /times-square/api/v1/github-pr/:org/:repo/:sha
provides metadata for a repository's check run in general, such as the contents in the check run and the GitHub pull request or check run.GET /times-square/api/v1/github-pr/:org/:repo/:sha/:path
provides metadata about a specific notebook.
Times Square check runs also link to the pull request preview pages published through Times Square's interface in Squareone.
What's Changed
- Bump python from 3.10.5-slim-bullseye to 3.10.6-slim-bullseye by @dependabot in #43
- DM-35816: Support for viewing GitHub PR previews in Squareone by @jonathansick in #42
Full Changelog: 0.5.0...0.6.0
0.5.0
Times Square now implements two GitHub check runs for pull requests on notebook repositories:
- The "YAML config" check validates the structure of YAML configuration files, specifically the
times-square.yaml
repository settings as well as the YAML sidecar files that describe each notebook. - The "Notebook execution" check actually runs notebooks (given their default parameters) with Noteburst, and ensures that they return without error.
Together, these features will help contributors to Times Square notebook repositories ensure that their contributions work before they merge pull requests.
What's Changed
- DM-35149: Integrate GitHub Checks API for validating YAML configs in repositories by @jonathansick in #40
- DM-35150: Implement GitHub Checks for notebook execution by @jonathansick in #41
Full Changelog: 0.4.0...0.5.0
0.5.0b1
This pre-release provides initial integration with the GitHub Checks API to validate YAML configuration files in notebook repositories.
What's Changed
- DM-35149: Integrate GitHub Checks API for validating YAML configs in repositories by @jonathansick in #40
Full Changelog: 0.4.0...0.5.0b1
0.4.0
Times Square now supports sourcing Jupyter Notebooks from GitHub repositories, in addition to its original mode of API-sourced notebooks. To do this, Times Square acts as a GitHub App integration, and receives webhook events from GitHub. When the Times Square app is installed in a GitHub repository, or a push to the default branch is accomplished, Times Square syncs Jupyter Notebooks from that repository into its page store.
Times Square-enabled GitHub repositories feature a times-square.yaml
file that provides settings for the repository as a whole (such as switching the repository on or off) and setting the root path for notebooks. Each notebook (ipynb
file) also has a corresponding YAML sidecar file that provides metadata for individual notebooks, including the title, description, tags, authors, and the parameter schemas.
To efficiently process webhook events, Times Square now operates an arq (Redis-backed) distributed queue.
New API endpoints:
GET /github/webhook
receives webhook events from GitHub (this should not require Gafaelfawr auth since webhooks are internally authenticated)GET /v1/github
provides a hierarchical tree of GitHub-backed pages within their GitHub organization, repository, and directory contexts. This endpoint powers Squareone's navigational view.GET /v1/github/:path
provides the same data as/v1/pages/:page
, but uses the GitHub display path as the path argument. An example of a display islsst-sqre/times-square-demo/matplotlib/gaussian2d
.
The GET /v1/github
and GET /v1/pages/:page
endpoints both include a new github
field with metadata specific to GitHub-backed pages.
What's Changed
- DM-34458: Add GitHub app functionality to ingest notebooks from repositories by @jonathansick in #30
- DM-34741: Refresh docker actions by @jonathansick in #31
- DM-34823: Implement endpoints for Squareone navigation of GitHub-backed pages by @jonathansick in #32
- DM-35057: Hide code cells through new HTML display settings by @jonathansick in #33
- DM-35146: Improve /html error message by @jonathansick in #35
- Bump python from 3.10.4-slim-bullseye to 3.10.5-slim-bullseye by @dependabot in #36
- Bump actions/setup-python from 3 to 4 by @dependabot in #37
- Bump pre-commit/action from 2.0.3 to 3.0.0 by @dependabot in #38
- DM-34474: Update for safir 3.2 release of safir.arq by @jonathansick in #39
Full Changelog: 0.3.0...0.4.0
0.4.0b2
What's Changed
- DM-34741: Refresh docker actions by @jonathansick in #31
- DM-34823: Implement endpoints for Squareone navigation of GitHub-backed pages by @jonathansick in #32
Full Changelog: 0.4.0b1...0.4.0b2
0.4.0b1
What's Changed
- DM-34458: Add GitHub app functionality to ingest notebooks from repositories by @jonathansick in #30
Full Changelog: 0.3.0...0.4.0b1
0.3.0
This release adds a new /v1/pages/:page/htmlstatus
endpoint that provides information about the availability of HTML for a specific page instance (set of page parameters). The Times Square UI monitors this endpoint to determine if an HTML rendering is available and when to refresh the iframe element displaying the HTML rendering.
In addition, the htmlstatus
endpoint includes a SHA256 hash of the HTML, which is now stored alongside the HTML in the Redis cache. This hash can be used to invalidate expired HTML renderings for pages with a finite time-to-live setting.
As well, this release adds a new times-square reset-html
command to the command line interface for clearing the Redis cache of HTML renderings (primarily useful during development).
Change log
Features
- DM-34030: Add an htmlstatus endpoint by @jonathansick in #24
Dependency updates
- [neophile] Update dependencies by @sqrbot in #25
- Bump python from 3.10.2-slim-bullseye to 3.10.3-slim-bullseye by @dependabot in #27
- Bump actions/cache from 2 to 3 by @dependabot in #26
- Bump python from 3.10.3-slim-bullseye to 3.10.4-slim-bullseye by @dependabot in #29
Full Changelog: 0.2.0...0.3.0