-
Notifications
You must be signed in to change notification settings - Fork 190
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
version 10.3.1 file task run as normal task and rebuilding everytime #364
Comments
Thanks very much for reporting this. I found this same issue yesterday, and am working on a fix. |
Fixed in 00ee2a0 and pushed to NPM v10.3.2. |
Hi,
There is still and issue, the time it took is incorrect.
it prints this when using the file is already created:
Starting 'host_init'...
Finished './host_init_phony' after 1574582400104 ms
Colin
…On Sun, Nov 24, 2019 at 1:22 AM Matthew Eernisse ***@***.***> wrote:
Closed #364 <#364>.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#364?email_source=notifications&email_token=AMR2TIZEK7DA4BKFXLK6MY3QVG3LHA5CNFSM4JQBXDIKYY3PNVWWK3TUL52HS4DFWZEXG43VMVCXMZLOORHG65DJMZUWGYLUNFXW5KTDN5WW2ZLOORPWSZGOVBV5DFQ#event-2825638294>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AMR2TIZWMGFHGQ5B2YM2NCDQVG3LHANCNFSM4JQBXDIA>
.
|
I cannot reproduce what you're seeing. Is it possible you haven't updated Jake? What do you see when you run Here is what I get with your sample Jakefile, and current master HEAD ( $ ../jake/bin/cli.js host_init_phony
file phony loaded
Starting 'host_init_phony'...
file phony start
file phony end
Finished 'host_init_phony' after 2 ms
$ ../jake/bin/cli.js host_init_phony
file phony loaded As you can see, the second time around, the only thing printed to stdout is "file phony loaded," which you are printing at the global level of the Jakefile. |
Hi Matt,
I'm not sure why this happens, and I can't create a minimal test for it.
But the startTime is null at the end of a task.
To fix it, move the startTime to beginning.
I can see that it goes into the !this.isNeeded() if during the run.
run() {
this.startTime = (new Date()).getTime();
console.log('run 1');
let val;
let hasAction = typeof this.action == 'function';
if (!this.isNeeded()) {
this.emit('skip');
this.emit('_done');
console.log('run 1.1');
}
else {
console.log('run 1.2');
Colin
…On Sun, Nov 24, 2019 at 8:38 PM Matthew Eernisse ***@***.***> wrote:
I cannot reproduce what you're seeing. Is it possible you haven't updated
Jake? What do you see when you run jake -v?
Here is what I get with your sample Jakefile, and current master HEAD (
bin/cli.js is the jake binary):
$ ../jake/bin/cli.js host_init_phony
file phony loaded
Starting 'host_init_phony'...
file phony start
file phony end
Finished 'host_init_phony' after 2 ms
$ ../jake/bin/cli.js host_init_phony
file phony loaded
As you can see, the second time around, the only thing printed to stdout
is "file phony loaded," which you are printing at the global level of the
Jakefile.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#364?email_source=notifications&email_token=AMR2TI52D45V7FWSR4XSQILQVLC4BA5CNFSM4JQBXDIKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEFAR3NQ#issuecomment-557915574>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AMR2TIYIQF6SG77XIDH3CVTQVLC4BANCNFSM4JQBXDIA>
.
|
Hi Matt,
And here is the output with my console logs after moving the starttime to
beggining of the function:
*run 1*
*run 1.1*
*run 1*
*run 1.1*
*run 1*
*run 1.2*
*Starting '**xxx**'...*
*starttime 1576586867285*
*task xxx start*
*did task xxx*
*task xxx end*
*starttime **1576586867284*
*endtime **1576586867287*
*Finished '...**Jakefile.js**' after **3 ms*
*And here it is without the starttime (old code)*
*run 1run 1.1run 1run 1.1run 1run 1.2Starting 'xxx'...starttime
1576586921584task xxx startdid task xxxtask xxx endstarttime nullendtime
1576586921586Finished '...Jakefile.js' after 1576586921586 ms*
…On Tue, Dec 17, 2019 at 2:47 PM Colin Shribman ***@***.***> wrote:
Hi Matt,
I'm not sure why this happens, and I can't create a minimal test for it.
But the startTime is null at the end of a task.
To fix it, move the startTime to beginning.
I can see that it goes into the !this.isNeeded() if during the run.
run() {
this.startTime = (new Date()).getTime();
console.log('run 1');
let val;
let hasAction = typeof this.action == 'function';
if (!this.isNeeded()) {
this.emit('skip');
this.emit('_done');
console.log('run 1.1');
}
else {
console.log('run 1.2');
Colin
On Sun, Nov 24, 2019 at 8:38 PM Matthew Eernisse ***@***.***>
wrote:
> I cannot reproduce what you're seeing. Is it possible you haven't updated
> Jake? What do you see when you run jake -v?
>
> Here is what I get with your sample Jakefile, and current master HEAD (
> bin/cli.js is the jake binary):
>
> $ ../jake/bin/cli.js host_init_phony
> file phony loaded
> Starting 'host_init_phony'...
> file phony start
> file phony end
> Finished 'host_init_phony' after 2 ms
> $ ../jake/bin/cli.js host_init_phony
> file phony loaded
>
> As you can see, the second time around, the only thing printed to stdout
> is "file phony loaded," which you are printing at the global level of the
> Jakefile.
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub
> <#364?email_source=notifications&email_token=AMR2TI52D45V7FWSR4XSQILQVLC4BA5CNFSM4JQBXDIKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEFAR3NQ#issuecomment-557915574>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AMR2TIYIQF6SG77XIDH3CVTQVLC4BANCNFSM4JQBXDIA>
> .
>
|
Can you give me access to a repo of some code that exhibits this behavior? I can't fix without some sort of repro case. |
Hi,
I can let you connect remotely using chrome remote desktop to my laptop,
and show you the issue and you can use my terminal to run and test out a
fix.
Colin
…On Fri, 17 Jan 2020, 18:13 Matthew Eernisse, ***@***.***> wrote:
Can you give me access to a repo of some code that exhibits this behavior?
I can't fix without some sort of repro case.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#364?email_source=notifications&email_token=AMR2TIYKFBHONTUD4JT5I3DQ6HKL7A5CNFSM4JQBXDIKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJIFTVI#issuecomment-575691221>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AMR2TI5MZRT2HV6SHGPQMMTQ6HKL7ANCNFSM4JQBXDIA>
.
|
Hi Matt,
https://drive.google.com/file/d/15oKoh2of8ZboGg6E8ZhcT7g-zaX5qIiN/view?usp=sharing
I shared with you a zip of part of source code so you can check it out and
fix jakejs so I can move from version 8.1.1 -> 10.4.3 (hopefully 10.4.4)
The see the issue do the following:
- unzip into dir rb_ext
- cd rb_ext
- node Jakefile.js --jake_fix xxx
- node Jakefile.js --jake_fix xxx
You should now see the issue:
Finished '/Users/colin/rb_ext/package.json' after 1579699111469 ms
Also as you can see task xxx isn't called every time which it should be.
If you have any questions regarding the code talk to me.
Colin
…On Fri, Jan 17, 2020 at 10:57 PM Colin Shribman ***@***.***> wrote:
Hi,
I can let you connect remotely using chrome remote desktop to my laptop,
and show you the issue and you can use my terminal to run and test out a
fix.
Colin
On Fri, 17 Jan 2020, 18:13 Matthew Eernisse, ***@***.***>
wrote:
> Can you give me access to a repo of some code that exhibits this
> behavior? I can't fix without some sort of repro case.
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub
> <#364?email_source=notifications&email_token=AMR2TIYKFBHONTUD4JT5I3DQ6HKL7A5CNFSM4JQBXDIKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJIFTVI#issuecomment-575691221>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AMR2TI5MZRT2HV6SHGPQMMTQ6HKL7ANCNFSM4JQBXDIA>
> .
>
|
I thought this problem was fixed with PR #370. I've just pushed at release with this fix to NPM, v10.4.6. Can you install the latest and see if your problem is resolved? |
To see issue run using latest jake version installed with npm install -g jake:
jake -f ./jakefile.js host_init_phony
jake -f ./jakefile.js host_init_phony
example jakefile.js
The text was updated successfully, but these errors were encountered: