Repository navigation
scons launcher and scons dist don't rebuild #13372
Description
Activity
In the end I found a workaround to this issue (thanks @josephsl for suggesting this in #10833):
- Commit changes to a local commit.
- Run:
scons --clean git reset --hard scons launcherStill it would be great if scons could work without manually cleaning the whole repository.
cc: @lukaszgo1In fact it is unnecessary to clean the whole repository - you just need to delete the
distandoutputdirectories.- Nope, scons launcher fails after that.…On 2/21/2022 10:34 AM, Łukasz Golonka wrote: In fact it is unnecessary to clean the whole repository - you just need to delete the |dist| and |output| directories. — Reply to this email directly, view it on GitHub <#13372 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AIJRDHGXWZNWQL2C5XNQAJ3U4KAT3ANCNFSM5O7JZ3EA>. Triage notifications on the go with GitHub Mobile for iOS <https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675> or Android <https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>. You are receiving this because you authored the thread.Message ID: ***@***.***>
Nope, scons launcher fails after that.
It does not fail for me. What error you get?
@lukaszgo1, Actually you're right, it appears to work. I was sure I tried that before though but must be in combination with scons --clean that apparently broke the build. So that is a valid work around. I would keep this issue open though, since I would expect a build system to track file changes and not require manual cleanup.
- addedtriagedHas been triaged, issue is waiting for implementation.Has been triaged, issue is waiting for implementation.
on Feb 28, 2022 - addedaudience/nvda-devPR or issue is relevant to NVDA / Add-on developersPR or issue is relevant to NVDA / Add-on developers
on Feb 28, 2022 I spent a whole day investigating this issue. I'm sorry, but I actually have very little knowledge about building systems, so I could only look through some official documentation to find possible solutions.
Below are some of my survey results:
In SCons, using the
--treeparameter allows you to observe the reference to the dependencycore.py.But in the result of the
--debug=prepareparameter, it is missing again.I don't understand why SCons doesn't check for changes in these files, the scripts in this repo are too complex for me.
Finally, I submitted a PR #15877, using the
AlwaysBuildfunction to force thedistto be rebuilt every time the build is executed to solve this issue.But there are still some flaws, I don't know how to make py2exe only replace the modified parts during construction
@LeonarddeR What is your opinion?- added a commit that references this issue
on Dec 7, 2023
TL;DR
scons launcherorscons distcommands don't seem to be able to pick up code changes after first execution. In other words, they can build successfully for the first time, but they cannot rebuild as they don't appear to see that code has changed.As to why this can be useful, in my example, I have NVDA build environment on my personal laptop, but I am trying to debug an issue with MS WOrd, which is only installed on my work laptop. I cannot build NVDA on work laptop, nor can I install MS Word on my personal laptop. As a result I need to frequently repeat the cycle of making code change, rebuild and test on work laptop.
Steps to reproduce:
The following steps use
scons launchercommand but all the same applies toscons distas well.app.MainLoop():Actual behavior:
scons launcherdoesn't see code changes and does not rebuild after code change. After my attempt to rebuild, no beep is heard when launching launcher.Expected behavior:
scons launchershould be able to see code changes and rebuild launcher with code changes. Beep should be heard when launching launcher.System configuration
NVDA installed/portable/running from source:
Running from source
NVDA version:
Commit 6310b86
Windows version:
Windows 11
Name and version of other software in use when reproducing the issue:
N/A
Other information about your system:
N/A
Other questions
Does the issue still occur after restarting your computer?
Yes
Have you tried any other versions of NVDA? If so, please report their behaviors.
No
If NVDA add-ons are disabled, is your problem still occurring?
Yes
Does the issue still occur after you run the COM Registration Fixing Tool in NVDA's tools menu?
N/A