Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Changelog

## Unreleased
* The first call from Python in a new JuliaCall session no longer compiles
`jl.<name>` lookup on a module or `jl.seval`, saving about a second.
* Bug fixes.

## 0.9.36 (2026-09-18)
Expand Down
2 changes: 2 additions & 0 deletions src/JlWrap/any.jl
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ function pyjlany_getattr(self, k_::Py)
Py(getproperty(self, k))
end
pyjl_handle_error_type(::typeof(pyjlany_getattr), self, exc) = pybuiltins.AttributeError
# `jl.<name>` on `juliacall.Main` is often the first call of a JuliaCall session.
precompile(pyjlany_getattr, (Module, Py))

function pyjlany_setattr(self, k_::Py, v_::Py)
k = Symbol(pyjl_attr_py2jl(pyconvert(String, k_)))
Expand Down
2 changes: 2 additions & 0 deletions src/JlWrap/module.jl
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ end
function pyjlmodule_seval(self::Module, expr::Py)
Py(Base.eval(self, Meta.parseall(strip(pyconvert(String, expr)))))
end
# `jl.seval(...)` is often the first call of a JuliaCall session.
precompile(pyjlmodule_seval, (Module, Py))

function init_module()
jl = pyjuliacallmodule
Expand Down
Loading