Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@IanButterworth
Copy link
Contributor

@IanButterworth IanButterworth commented Oct 4, 2025

Fixes

% ./julia -E 'using Revise; Revise.track(Base); Base.Threads.foo()' 
ERROR: UndefVarError: `foo` not defined in `Base.Threads`

PR

% ./julia -E 'using Revise; Revise.track(Base); Base.Threads.foo()'
1

@IanButterworth
Copy link
Contributor Author

@timholy I realised in the examples above it's better for the revision to throw if there are issues, so I added a kwarg.

@IanButterworth
Copy link
Contributor Author

Maybe the default for that kwarg should be !isinteractive()...

@KristofferC
Copy link
Collaborator

I didn't get why you would not want to revise after tracking?

@IanButterworth
Copy link
Contributor Author

Sorry I don't follow.

@KristofferC
Copy link
Collaborator

KristofferC commented Oct 6, 2025

Sorry, nevermind, I was confused about what the kwarg actually did.

@IanButterworth
Copy link
Contributor Author

I'd be open to removing the kwarg and just making it revise(throw=!isinteractive())

@timholy
Copy link
Owner

timholy commented Oct 8, 2025

Can you expand on what's triggering the throwing? Bad code? Something else? In the OP I'm assuming the error stems from the command (Base.Threads.foo()) but that the keyword is targeted at something else?

@IanButterworth
Copy link
Contributor Author

IanButterworth commented Oct 8, 2025

Yeah, bad code.

Previously

  • Edit code badly i.e. syntax errors.
  • Run Revise.track(Base); include("test.jl")
  • revise will soft fail, logging the parsing error and then continue to run test.jl with the un-revised Base, which you then have to interrupt

It's better for revise to throw.

@timholy timholy merged commit 2923734 into timholy:master Oct 8, 2025
11 of 13 checks passed
@timholy
Copy link
Owner

timholy commented Oct 8, 2025

@IanButterworth IanButterworth deleted the ib/track_revise branch October 8, 2025 17:26
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.

3 participants