Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch to Pythoncall #275

Merged
merged 5 commits into from
Oct 28, 2024
Merged

Switch to Pythoncall #275

merged 5 commits into from
Oct 28, 2024

Conversation

mloubout
Copy link
Member

PyCall is being rolled out in favor of PythonCall

Keno and others added 2 commits October 17, 2024 08:26
The `eval` and `include` generic functions are implicitly provided
by `module` for every new julia module. Currently it is possible
to extend these (somewhat by accident), but this might change in
JuliaLang/julia#55949.

To avoid that causing issues, this renames the `eval` method in
this package to `eval_lazy` to avoid accidentally extending the
builtin. If desireed, you could instead use a baremodule to avoid
creating the implicit functions (see e.g. phelipe/Fuzzy.jl#21).

While I'm here, also strength-reduce the (builtin) `eval` method
to `getproperty` instead as applicable. This is not required, but
simply a best practice to avoid requiring the full semantics of
`eval` (which include arbitrary code execution) when it is not needed.

I was unable to test this locally due to some python dependency
errors, so please take a careful look to make sure I got this right.
Copy link

codecov bot commented Oct 23, 2024

Codecov Report

Attention: Patch coverage is 91.73554% with 10 lines in your changes missing coverage. Please review.

Project coverage is 82.38%. Comparing base (edc3ad9) to head (d395ef0).
Report is 6 commits behind head on master.

Files with missing lines Patch % Lines
src/TimeModeling/Modeling/losses.jl 50.00% 3 Missing ⚠️
src/TimeModeling/Modeling/twri_objective.jl 83.33% 2 Missing ⚠️
src/TimeModeling/Utils/time_utilities.jl 0.00% 2 Missing ⚠️
src/TimeModeling/Modeling/time_modeling_serial.jl 92.30% 1 Missing ⚠️
...imeModeling/Preconditioners/DataPreconditioners.jl 80.00% 1 Missing ⚠️
src/utilities.jl 50.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #275      +/-   ##
==========================================
- Coverage   82.70%   82.38%   -0.33%     
==========================================
  Files          36       36              
  Lines        2735     2719      -16     
==========================================
- Hits         2262     2240      -22     
- Misses        473      479       +6     
Files with missing lines Coverage Δ
ext/JLD2JUDIExt.jl 80.00% <100.00%> (-3.34%) ⬇️
src/JUDI.jl 83.33% <100.00%> (ø)
src/TimeModeling/LinearOperators/lazy.jl 81.33% <100.00%> (ø)
src/TimeModeling/Modeling/misfit_fg.jl 94.87% <100.00%> (-0.13%) ⬇️
src/TimeModeling/Modeling/python_interface.jl 100.00% <100.00%> (+1.01%) ⬆️
src/TimeModeling/Preconditioners/base.jl 57.14% <100.00%> (+1.26%) ⬆️
src/TimeModeling/Types/GeometryStructure.jl 82.48% <100.00%> (-0.32%) ⬇️
src/TimeModeling/Types/ModelStructure.jl 83.17% <ø> (+0.38%) ⬆️
src/TimeModeling/Types/lazy_msv.jl 86.84% <100.00%> (ø)
src/TimeModeling/Utils/auxiliaryFunctions.jl 74.02% <100.00%> (+0.07%) ⬆️
... and 6 more

... and 1 file with indirect coverage changes

@mloubout mloubout force-pushed the pythoncall branch 23 times, most recently from b5240a1 to 590b2d2 Compare October 24, 2024 15:37
@mloubout mloubout force-pushed the pythoncall branch 2 times, most recently from 935b889 to 572258a Compare October 25, 2024 02:57
@mloubout mloubout force-pushed the pythoncall branch 6 times, most recently from f91943e to 72570aa Compare October 28, 2024 13:53
@mloubout mloubout merged commit 591f117 into master Oct 28, 2024
41 checks passed
@mloubout mloubout deleted the pythoncall branch October 28, 2024 19:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants