-
Notifications
You must be signed in to change notification settings - Fork 55
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
Warning when running Figwheel without cleaning #132
Comments
One way to fix this would be to make an alias in lein to clean before running Figwheel: :aliases
{"figwheel"
["do"
["clean"]
["npm" "install"]
["figwheel"]]} |
Right, but it would seem that running |
I actually ended up doing that in my projects due to similar issues. I find that I don't tend to restart Fighweel all that often, and even for a large project the initial build only takes a few seconds. However, I do agree that ideally you shouldn't have to clean between restarts. Unfortunately, it's not really something that can be fixed in the template itself. |
Is it a bug in Figwheel then? I can open an issue there, if that's the case. |
It does look like there's something that trips up Figwheel in your case. As a note, I just tried this locally and I'm not seeing the problem in my setup:
Only other thing that I can think of to try would be to delete local Maven cache for Figwheel:
If that doesn't help, then opening an issue for Figwheel would probably be the way to go. |
I already tried wiping my entire Maven cache. I'll open an issue against Figwheel, but also—it looks like your Figwheel didn't connect to your browser. If you let it, does that change anything? |
Just tried, that seems to be working fine as well in my case:
|
Oh wait, you didn't try to evaluate a variable. That's when the warning happens.
|
Cross-posted to bhauman/lein-figwheel#511. |
Oh I see what's happening in your case. You end up in the |
alternatively, you could switch to the namespace by running |
You're right. Running I guess I'm surprised because the variable is clearly defined well enough for its value to be printed. What sort of intermediate state is the variable in where the compiler thinks it doesn't exist while it actually does? Such an intermediate state doesn't seem to exist in Clojure, only in ClojureScript. Also, I think it's a bad idea for Figwheel to behave differently depending on whether or not |
Yeah, I'm not sure why the namespace is loaded after running clean, and not after resuming with existing compiled sources. I agree that consistent behavior would be desirable here. |
In short, if I run
lein figwheel
twice, without cleaning in between, then in the second session I get a compiler warning any time I try to access a variable—even though the variable is defined, and its value is correctly printed.Here are the precise steps to reproduce, along with my version and OS information:
Additional info:
lein clean
before runninglein figwheel
the second time.~/.m2
repository before performing the same steps as above.localhost:3449
before starting Figwheel or after.localhost:3449
or0.0.0.0:3449
.The text was updated successfully, but these errors were encountered: