Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
1a9131c
move SymPyPyCall -> SymPy; breaking change
jverzani Oct 21, 2023
74664cd
resolve conflicts
jverzani Nov 27, 2023
4b4db36
updates to master
jverzani Dec 12, 2023
97c13ca
Bool3, bump
jverzani May 24, 2024
44cde5b
Merge branch 'master' of https://github.com/JuliaPy/SymPy.jl
jverzani May 28, 2024
0b0164e
Merge branch 'master' of https://github.com/JuliaPy/SymPy.jl
jverzani Jun 15, 2024
b2da403
Merge branch 'master' of https://github.com/JuliaPy/SymPy.jl
jverzani Aug 3, 2024
502435c
Merge branch 'master' of https://github.com/JuliaPy/SymPy.jl
jverzani Aug 3, 2024
d12c66e
Merge branch 'master' of https://github.com/JuliaPy/SymPy.jl
jverzani Jan 29, 2025
6918d1c
Merge branch 'master' of https://github.com/JuliaPy/SymPy.jl
jverzani Jan 29, 2025
7decb2b
Merge branch 'master' of https://github.com/JuliaPy/SymPy.jl
jverzani Jan 29, 2025
bdf36c1
Merge branch 'master' of https://github.com/JuliaPy/SymPy.jl
jverzani Feb 11, 2025
7974c2e
Merge branch 'master' of https://github.com/JuliaPy/SymPy.jl
jverzani Feb 19, 2025
ad7399a
Merge branch 'master' of https://github.com/JuliaPy/SymPy.jl
jverzani Oct 26, 2026
18e2a0f
Ignore JetBrains IDE files
jverzani Oct 26, 2026
bfe55b6
Fix hash segfault with PyCall 1.97 GIL release
jverzani Oct 26, 2026
b011b85
Run hash test before shared suite; bump version to 2.3.4
jverzani Oct 26, 2026
07d0115
Update GitHub Actions; add dependabot config
jverzani Oct 26, 2026
13290a3
Replace deprecated set-output with GITHUB_OUTPUT
jverzani Oct 26, 2026
a413110
CI nightly: use runner's default arch (macOS runners are arm64)
jverzani Oct 26, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
# To group all GitHub Actions updates into a single PR, uncomment the following:
# groups:
# github-actions:
# patterns:
# - "*"
- package-ecosystem: "julia"
directories:
- "/"
- "/docs"
schedule:
interval: "weekly"
# To group all Julia dependency updates into a single PR, uncomment the following:
# groups:
# julia-dependencies:
# patterns:
# - "*"
14 changes: 7 additions & 7 deletions .github/workflows/benchmark_pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,16 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
- uses: actions/checkout@v7
- uses: julia-actions/setup-julia@v3
with:
version: "1"
- uses: julia-actions/cache@v1
- uses: julia-actions/cache@v3
- name: Extract Package Name from Project.toml
id: extract-package-name
run: |
PACKAGE_NAME=$(grep "^name" Project.toml | sed 's/^name = "\(.*\)"$/\1/')
echo "::set-output name=package_name::$PACKAGE_NAME"
echo "package_name=$PACKAGE_NAME" >> "$GITHUB_OUTPUT"
- name: Build SymPy
env:
JULIA_NUM_THREADS: 2
Expand All @@ -44,7 +44,7 @@ jobs:
mkdir -p plots
benchpkgplot ${{ steps.extract-package-name.outputs.package_name }} --rev="${{github.event.repository.default_branch}},${{github.event.pull_request.head.sha}}" --npart=10 --format=png --input-dir=results/ --output-dir=plots/
- name: Upload plot as artifact
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v7
with:
name: plots
path: plots
Expand All @@ -62,15 +62,15 @@ jobs:
echo 'Go to "Actions"->"Benchmark a pull request"->[the most recent run]->"Artifacts" (at the bottom).' >> body.md

- name: Find Comment
uses: peter-evans/find-comment@v2
uses: peter-evans/find-comment@v4
id: fcbenchmark
with:
issue-number: ${{ github.event.pull_request.number }}
comment-author: 'github-actions[bot]'
body-includes: Benchmark Results

- name: Comment on PR
uses: peter-evans/create-or-update-comment@v3
uses: peter-evans/create-or-update-comment@v5
with:
comment-id: ${{ steps.fcbenchmark.outputs.comment-id }}
issue-number: ${{ github.event.pull_request.number }}
Expand Down
17 changes: 4 additions & 13 deletions .github/workflows/ci-nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,22 +21,13 @@ jobs:
- macos-latest
- windows-latest
arch:
- x64
- default
steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
- uses: actions/checkout@v7
- uses: julia-actions/setup-julia@v3
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: actions/cache@v1
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- uses: julia-actions/cache@v3
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@ jobs:
arch:
- x64
steps:
- uses: actions/checkout@v3
- uses: julia-actions/setup-julia@v1
- uses: actions/checkout@v7
- uses: julia-actions/setup-julia@v3
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: julia-actions/cache@v1
- uses: julia-actions/cache@v3
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,6 @@ docs/site
Manifest.toml
appveyor.yml
.travis.yml
default.profraw
default.profraw
.idea/
*.iml
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name = "SymPy"
uuid = "24249f21-da20-56a4-8eb1-6a02cf4ae2e6"
version = "2.3.3"
version = "2.3.4"

[deps]
CommonEq = "3709ef60-1bee-4518-9f2f-acd86f176c50"
Expand All @@ -14,7 +14,7 @@ SymPyCore = "458b697b-88f0-4a86-b56b-78b75cfb3531"
CommonEq = "0.2.1"
CommonSolve = "0.2"
LinearAlgebra = "1.10"
PyCall = "1.96.2"
PyCall = "1.97"
SparseArrays = "1.1"
SpecialFunctions = "0.7, 0.8, 0.8, 0.10, 1, 2"
SymPyCore = "0.2.11,0.3"
Expand Down
8 changes: 2 additions & 6 deletions src/python_connection.jl
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,8 @@ _up_matrix(m) = map(↑, m.tolist())



# hash (work around pending PyCall release with its own hash)
function Base.hash(x::SymbolicObject{T}, h::UInt) where {T <: PyCall.PyObject}
o = ↓(x)
px = ccall((PyCall.@pysym :PyObject_Hash), PyCall.Py_hash_t, (PyCall.PyPtr,), o) # from PyCall.jl
reinterpret(UInt, Int(px)) - 3h # from PythonCall.jl
end
# hash: defer to PyCall (≥ 1.97), which acquires the GIL before calling PyObject_Hash
Base.hash(x::SymbolicObject{T}, h::UInt) where {T <: PyCall.PyObject} = hash(↓(x), h)


# should we also have different code path for a::String like PyCall?
Expand Down
9 changes: 9 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,15 @@ end


using SymPy
using Test

@testset "hash (issue with PyCall GIL release)" begin
@syms c() a b
d = Dict(c(0) => a)
@test d[c(0)] == a
@test hash(a + b) == hash(b + a)
@test length(Set([a, a, c(0), c(0)])) == 2
end

path = joinpath(pathof(SymPy.SymPyCore), "../../test")
include(joinpath(path, "runtests-sympycore.jl"))
Loading