-
Notifications
You must be signed in to change notification settings - Fork 7
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
Migrate to netstandard2.0 #17
Conversation
Update Cake to 0.28.0 version for build
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking on my phone at the moment and mostly looks good but will do a proper look soon. Couple of things for the meantime. Theres one of the cake generated scripts been added could that be removed - 645a1e2b-a9f4-459e-8d5e-a517e430b274.cake
There's a couple of async methods which could have the async and awaits removed. If the result of an awaited method is being immediately returned then the task itself can be returned - ParseAndCacheRazorTemplateAsync for example. Hope that makes sense. Oh amd just an fyi if you're writing library code like this then 99% of the time you should add .ConfigureAwait(false) when you do need to await. I'll see if I can look out a link which explains why but it's basically to allow the method to resume in a different thread context which is more efficient.
Thanks again for looking at this
Thank for fast response. |
Oh yeah. Spot on. Still mostly working in framework so forget about things like that.
…________________________________
From: Vadim Hatsura <notifications@github.com>
Sent: Wednesday, September 26, 2018 9:42:44 PM
To: cake-contrib/Cake.Graph
Cc: Warren; Comment
Subject: Re: [cake-contrib/Cake.Graph] Migrate to netstandard2.0 (#17)
So, regarding ConfigureAwait. , it make sense only for .Net Framework. In Asp .Net Core SynchronizationContext was removed (http://blog.stephencleary.com/2017/03/aspnetcore-synchronization-context.html)
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub<#17 (comment)>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AF5xC6RLBgORwnJwJ3IHui-c-0oh9UyIks5ue-bEgaJpZM4W4bJe>.
|
Cool. Looks good. Thanks for your contribution |
* Migrate to netstandard2.0 (#17) * Migrate to netstandard2.0 * Add non-async methods to backward compatibility Update Cake to 0.28.0 version for build * Update Cake.FileHelpers to 3.1.0 * Fix nuget package generation * Delete temporary file * Remove redundant code * Build with Cake 0.30.0 (#19) * Add RazorLight dependency #21 (#22) * Add Example usage (#23)
For #16
Some tricky cases:
GetAwaiter().GetResult()
. Such methods can be marked as Obsolete