From 9ed21f783dd046a61c7bb95d9f7a97415ebf0fbc Mon Sep 17 00:00:00 2001 From: Alex Date: Tue, 5 Aug 2025 05:14:13 +0200 Subject: [PATCH 1/2] Create django.yml --- .github/workflows/django.yml | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 .github/workflows/django.yml diff --git a/.github/workflows/django.yml b/.github/workflows/django.yml new file mode 100644 index 000000000000..53ece2d8412c --- /dev/null +++ b/.github/workflows/django.yml @@ -0,0 +1,30 @@ +name: Django CI + +on: + push: + branches: [ "master" ] + pull_request: + branches: [ "master" ] + +jobs: + build: + + runs-on: ubuntu-latest + strategy: + max-parallel: 4 + matrix: + python-version: [3.7, 3.8, 3.9] + + steps: + - uses: actions/checkout@v4 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v3 + with: + python-version: ${{ matrix.python-version }} + - name: Install Dependencies + run: | + python -m pip install --upgrade pip + pip install -r requirements.txt + - name: Run Tests + run: | + python manage.py test From c9606a8add05cbc4d6f422fa65bcf9a47750be6f Mon Sep 17 00:00:00 2001 From: Alex Date: Tue, 12 Aug 2025 14:25:30 +0200 Subject: [PATCH 2/2] Update profile.pyi --- mypy/typeshed/stdlib/profile.pyi | 50 +++++++++++++++----------------- 1 file changed, 23 insertions(+), 27 deletions(-) diff --git a/mypy/typeshed/stdlib/profile.pyi b/mypy/typeshed/stdlib/profile.pyi index 696193d9dc16..d89ea5a6e83a 100644 --- a/mypy/typeshed/stdlib/profile.pyi +++ b/mypy/typeshed/stdlib/profile.pyi @@ -1,31 +1,27 @@ -from _typeshed import StrOrBytesPath -from collections.abc import Callable, Mapping -from typing import Any, TypeVar -from typing_extensions import ParamSpec, Self, TypeAlias +# ~/.profile: executed by the command interpreter for login shells. +# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login +# exists. +# see /usr/share/doc/bash/examples/startup-files for examples. +# the files are located in the bash-doc package. -__all__ = ["run", "runctx", "Profile"] +# the default umask is set in /etc/profile; for setting the umask +# for ssh logins, install and configure the libpam-umask package. +#umask 022 -def run(statement: str, filename: str | None = None, sort: str | int = -1) -> None: ... -def runctx( - statement: str, globals: dict[str, Any], locals: Mapping[str, Any], filename: str | None = None, sort: str | int = -1 -) -> None: ... +# if running bash +if [ -n "$BASH_VERSION" ]; then + # include .bashrc if it exists + if [ -f "$HOME/.bashrc" ]; then + . "$HOME/.bashrc" + fi +fi -_T = TypeVar("_T") -_P = ParamSpec("_P") -_Label: TypeAlias = tuple[str, int, str] +# set PATH so it includes user's private bin if it exists +if [ -d "$HOME/bin" ] ; then + PATH="$HOME/bin:$PATH" +fi -class Profile: - bias: int - stats: dict[_Label, tuple[int, int, int, int, dict[_Label, tuple[int, int, int, int]]]] # undocumented - def __init__(self, timer: Callable[[], float] | None = None, bias: int | None = None) -> None: ... - def set_cmd(self, cmd: str) -> None: ... - def simulate_call(self, name: str) -> None: ... - def simulate_cmd_complete(self) -> None: ... - def print_stats(self, sort: str | int = -1) -> None: ... - def dump_stats(self, file: StrOrBytesPath) -> None: ... - def create_stats(self) -> None: ... - def snapshot_stats(self) -> None: ... - def run(self, cmd: str) -> Self: ... - def runctx(self, cmd: str, globals: dict[str, Any], locals: Mapping[str, Any]) -> Self: ... - def runcall(self, func: Callable[_P, _T], /, *args: _P.args, **kw: _P.kwargs) -> _T: ... - def calibrate(self, m: int, verbose: int = 0) -> float: ... +# set PATH so it includes user's private bin if it exists +if [ -d "$HOME/.local/bin" ] ; then + PATH="$HOME/.local/bin:$PATH" +fi