Repository navigation
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
Jupyter is exposed on all host interfaces with the publicly known token foo, allowing anyone who can reach it to execute code and modify the read-write mounted checkout.
6 open issues
Require a caller-provided notebook authentication token · New Include the data directory in the published site · New Replace shell commands unsupported by JupyterLite · New Use the correct relative path for the SQL fixture · New Convert the explanatory code cell to Markdown · New Group averages by the correct entity · New
What changed in this PR
This upstream sync expands the notebook collection with SQLite examples and adds tooling for local execution, automated checks, and browser-based publishing.
Changes:
- Add SQL lessons, sample student data, and a notebook execution helper.
- Introduce Docker and JupyterLite environments with updated dependencies.
- Add notebook CI, pre-commit checks, and GitHub Pages deployment.
| File | Description |
|---|---|
run-notebook.sh |
Executes notebooks and prints stream output. |
requirements.txt |
Updates notebook dependencies. |
notebooks/students.ipynb |
Adds SQL querying, joins, and aggregation lessons. |
notebooks/sqlite-data-analasis.ipynb |
Demonstrates SQLite queries with pandas. |
notebooks/matplotlib.ipynb |
Updates kernel and notebook-format metadata. |
environment.yml |
Defines the browser-based xeus-python environment. |
Dockerfile |
Adds a Jupyter image with SQLite and Python dependencies. |
data/sample.sql |
Provides student and grade sample data. |
compose.yml |
Configures the local Jupyter service and repository mount. |
ci-requirements.txt |
Adds notebook execution dependencies for CI. |
.python-version |
Selects Python 3.12. |
.pre-commit-config.yaml |
Configures whitespace and merge-conflict checks. |
.nojekyll |
Adds a marker to bypass Jekyll processing. |
.gitignore |
Expands Python artifact and environment exclusions. |
.github/workflows/static-site.yml |
Builds JupyterLite and deploys to GitHub Pages. |
.github/workflows/pre-commit.yml |
Runs repository hygiene checks. |
.github/workflows/ci.yml |
Executes the SQLite/pandas notebook in CI. |
.github/build-environment.yml |
Defines JupyterLite build dependencies. |
.dockerignore |
Excludes selected files from Docker build context. |
Review effort: Balanced (adaptive)
| - $PWD:/home/jovyan/work:rw | ||
| environment: | ||
| - JUPYTER_ENABLE_LAB=yes | ||
| - JUPYTER_TOKEN=foo |
| - name: Build the JupyterLite site | ||
| shell: bash -l {0} | ||
| run: | | ||
| jupyter lite build --contents notebooks --output-dir dist |
| }, | ||
| "outputs": [], | ||
| "source": [ | ||
| "%%sh\n", |
| "%%sh\n", | ||
| "# Open the sqlite3 CLI and create the database from the SQL file\n", | ||
| "rm -rf sample.db\n", | ||
| "sqlite3 sample.db < ./data/sample.sql" |
Comment on lines
+349
to
+356
| "cell_type": "code", | ||
| "execution_count": null, | ||
| "metadata": { | ||
| "vscode": { | ||
| "languageId": "shellscript" | ||
| } | ||
| }, | ||
| "outputs": [], |
Comment on lines
+518
to
+520
| " SELECT student_id, class_id, AVG(final_grade ) AS avg_final_grade\n", | ||
| " FROM student_grades\n", | ||
| " GROUP BY class_id\n", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


No description provided.