Skip to content

Commit

Permalink
prep for release
Browse files Browse the repository at this point in the history
  • Loading branch information
oscarlevin committed Oct 18, 2024
1 parent aada395 commit 0225818
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 18 deletions.
28 changes: 14 additions & 14 deletions .github/workflows/deploy-stable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,20 +76,6 @@ jobs:
- name: Update version for next dev release
run: poetry version patch

- name: Create Release
id: create_release
if: ${{ inputs.level != 'patch' }}
uses: actions/create-release@latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: "v${{ env.VERSION }}"
release_name: "v${{ env.VERSION }}"
body: |
See the [changelog](CHANGELOG.md) for details.
draft: false
prerelease: false

- name: setup git config
run: |
# setup the username and email.
Expand All @@ -115,6 +101,20 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Create Release
id: create_release
if: ${{ inputs.level != 'patch' }}
uses: actions/create-release@latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: "v${{ env.VERSION }}"
release_name: "v${{ env.VERSION }}"
body: |
See the [changelog](CHANGELOG.md) for details.
draft: false
prerelease: false

- name: Repository Dispatch
uses: peter-evans/repository-dispatch@v2
with:
Expand Down
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,16 @@ Instructions: Add a subsection under `[UNRELEASED]` for additions, fixes, change

## [UNRELEASED]

### Added

- From core: publication option to control latex style file.
- From core: default programming language can be set in `<docinfo>`

### Changed

- From core: `<bibinfo>` container for bibliographic information previous held in `<titlepage>` and `<colophon>`.
- Improved publication file template.

## [2.7.1] - 2024-10-03

### Fixed
Expand Down
2 changes: 1 addition & 1 deletion pretext/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

VERSION = get_version("pretext", Path(__file__).parent.parent)

CORE_COMMIT = "db2a2fdf9da233779537661d24245fc32124f15a"
CORE_COMMIT = "844cd230b94e5626e3f2d40024884bdbc1a85dff"


def activate() -> None:
Expand Down
6 changes: 3 additions & 3 deletions pretext/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -691,7 +691,7 @@ def active_server_port() -> t.Optional[int]:
"""
# We look at all currently running processes and check if any are a pretext process that is a child of a pretext process. This would only happen if we have run a `pretext view` command to start the server, so we can assume that this is the server we are looking for.
for proc in psutil.process_iter():
if proc.name() == "pretext" and proc.parent().name() == "pretext":
if proc.name() == "pretext" and proc.parent().name() == "pretext": # type: ignore
log.debug(f"Found pretext server running with pid {proc.pid}")
# Sometimes the process stops but doesn't get removed from the process list. We check if the process is still running by checking its status.
if proc.status() not in [psutil.STATUS_RUNNING, psutil.STATUS_SLEEPING]:
Expand Down Expand Up @@ -719,7 +719,7 @@ def stop_server(port: t.Optional[int] = None) -> None:
if len(proc.connections()) > 0:
if (
proc.name() == "pretext"
and proc.parent().name() == "pretext"
and proc.parent().name() == "pretext" # type: ignore
and proc.connections()[0].laddr.port == port
):
log.debug(
Expand All @@ -729,7 +729,7 @@ def stop_server(port: t.Optional[int] = None) -> None:
else:
# As before, we look for a pretext process that is a child of a pretext process. This time we terminate that process.
for proc in psutil.process_iter():
if proc.name() == "pretext" and proc.parent().name() == "pretext":
if proc.name() == "pretext" and proc.parent().name() == "pretext": # type: ignore
log.debug(f"Terminating process with PID {proc.pid}")
proc.terminate()

Expand Down
1 change: 1 addition & 0 deletions tests/test_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@ def test_custom_xsl(tmp_path: Path, script_runner: ScriptRunner) -> None:
assert (custom_path / "output" / "test2").exists()


@pytest.mark.skip(reason="secondary webwork server not currently available")
def test_custom_webwork_server(tmp_path: Path, script_runner: ScriptRunner) -> None:
custom_path = tmp_path / "custom"
shutil.copytree(EXAMPLES_DIR / "projects" / "custom-wwserver", custom_path)
Expand Down

0 comments on commit 0225818

Please sign in to comment.