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

versioninfo: refactor and use the same code for serialization #2994

Merged
merged 2 commits into from
Nov 5, 2023

Conversation

benlorenz
Copy link
Member

@benlorenz benlorenz commented Nov 5, 2023

I changed the versioninfo internals to return a dict with branchname, (full) commit, and date. This is now used for the serialization version as well.
A few small fixes/improvements including:

  • improved is_dev detection since the dependency keys have type UUID
  • support git worktree where .git is not a folder
  • adjust whitespace to editorconfig

I changed the oscar_serialization_version to a ref that is assigned on first use via get_oscar_serialization_version(), this way we don't need to run extra subprocesses during precompilation.

There should be plenty of fail-safes in there to make sure it doesn't break anything.

fixes #2991

@thofma
Copy link
Collaborator

thofma commented Nov 5, 2023

Looks good, thanks. Out of curiosity: Could we do the same with some LibGit2 magic?

@benlorenz
Copy link
Member Author

benlorenz commented Nov 5, 2023

Looks good, thanks. Out of curiosity: Could we do the same with some LibGit2 magic?

Yes we (probably) could but I would rather not (see also JuliaLang/Pkg.jl#2679).

There is one segfault during K3.jl I haven't seen so far for julia 1.10:

GC: pause 56.89ms. collected 364.319885MB. incr 

GC: pause 55.17ms. collected 364.076935MB. incr 

GC: pause 59.27ms. collected 363.873032MB. incr 

GC: pause 53.31ms. collected 363.090843MB. incr 

GC: pause 62.44ms. collected 360.652840MB. incr 

GC: pause 60.83ms. collected 378.091202MB. incr 

[3729] signal (11.1): Segmentation fault
in expression starting at /home/runner/work/Oscar.jl/Oscar.jl/test/AlgebraicGeometry/Schemes/K3.jl:1
jl_is_concrete_type at /cache/build/builder-amdci4-5/julialang/julia-release-1-dot-10/src/julia.h:1536 [inlined]
ijl_isa at /cache/build/builder-amdci4-5/julialang/julia-release-1-dot-10/src/subtype.c:2340
unknown function (ip: 0x7f28d0ffbaff)
Allocations: 572821182 (Pool: 572489744; Big: 331438); GC: 140
ERROR: LoadError: Package Oscar errored during testing (received signal: 11)

I would guess this disappears when retrying once the other tests are done.

@thofma thofma merged commit 6fd21c5 into master Nov 5, 2023
16 of 20 checks passed
@thofma thofma deleted the bl/refactorversion branch November 5, 2023 18:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Failed to precompile using Julia 1.10-rc1
3 participants