-
Notifications
You must be signed in to change notification settings - Fork 525
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
Paket.PowerShell support for Package Manager Console #875
Conversation
restore the lock for the console trace to allow multiple threads
let id = Threading.Thread.CurrentThread.ManagedThreadId | ||
Logging.subscribe (fun trace -> | ||
if id = Threading.Thread.CurrentThread.ManagedThreadId then |
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.
This thread ID check appears it will work. Messages in async
will not print, but also will not error out the program now.
I asked around at work about how to get all the messages on the same thread. I was told to look at |
I spent hours on this, this evening, without any luck. I opened up a stackover question: |
I believe this is ready to go. Logging now works correctly in PowerShell and in Package Manager Console. It displays output as it goes. I created type |
The feature is |
Paket.PowerShell support for Package Manager Console
cool. thanks |
maybe it even fixes the logging issues in paket.vs - you never know ;-) |
Did this by any chance changed the exit code behavior? It seems we always get exit code 1 - even on success. |
:/ I'll have a look. |
I mean it's probably something different, but I have no idea at the moment
|
Looking at the changes I made to |
@forki Just to be clear, the exit code wasn't broken. What was broken was the exception not being logged. |
Paket.Logging.event is public. event.Publish can be subscibed to.
|
@forki Can you change |
fsprojects/Paket.VisualStudio@8bb932a does this look OK? |
This is for #874 and is
notreadyyetto be merged.It is in progress and ready for review. I could use some help solving the async / trace dilemma.PowerShell requires that the tracing be on the same thread and itappearsasync puts it on another.