Skip to content
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

Log to syslog on Linux #1286

Closed
ahoppen opened this issue May 13, 2024 · 0 comments · Fixed by #1411
Closed

Log to syslog on Linux #1286

ahoppen opened this issue May 13, 2024 · 0 comments · Fixed by #1411

Comments

@ahoppen
Copy link
Collaborator

ahoppen commented May 13, 2024

On Linux, we can log to syslog like we log to os_log on Darwin. That should allow us to also recapture logs in sourcekit-lsp diagnose.

rdar://127138318

ahoppen added a commit to ahoppen/sourcekit-lsp that referenced this issue Jun 3, 2024
Instead of logging to `stderr`, write log messages to files in `/var/log/sourcekit-lsp/sourcekit-lsp-<pid>.log`.

This allows us to retrieve the log messages from `sourcekit-lsp diagnose`.

We should be able to expand this to also write to log files on Windows but I still need to figure out what an appropriate log directory might be. That will be a follow-up PR.

Fixes apple#1286
rdar://127138318
ahoppen added a commit to ahoppen/sourcekit-lsp that referenced this issue Jun 3, 2024
Instead of logging to `stderr`, write log messages to files in `/var/log/sourcekit-lsp/sourcekit-lsp-<pid>.log`.

This allows us to retrieve the log messages from `sourcekit-lsp diagnose`.

We should be able to expand this to also write to log files on Windows but I still need to figure out what an appropriate log directory might be. That will be a follow-up PR.

Fixes apple#1286
rdar://127138318
ahoppen added a commit to ahoppen/sourcekit-lsp that referenced this issue Jun 4, 2024
Instead of logging to `stderr`, write log messages to files in `/var/log/sourcekit-lsp/sourcekit-lsp-<pid>.log`.

This allows us to retrieve the log messages from `sourcekit-lsp diagnose`.

We should be able to expand this to also write to log files on Windows but I still need to figure out what an appropriate log directory might be. That will be a follow-up PR.

Fixes apple#1286
rdar://127138318
ahoppen added a commit to ahoppen/sourcekit-lsp that referenced this issue Jun 4, 2024
Instead of logging to `stderr`, write log messages to files in `.sourcekit-lsp/logs/sourcekit-lsp-<pid>.<log index>.log`.

This allows us to retrieve the log messages from `sourcekit-lsp diagnose`.

We should be able to expand this to also write to log files on Windows but I still need to figure out what an appropriate log directory might be. That will be a follow-up PR.

Fixes apple#1286
rdar://127138318
ahoppen added a commit to ahoppen/sourcekit-lsp that referenced this issue Jun 5, 2024
Instead of logging to `stderr`, write log messages to files in `.sourcekit-lsp/logs/sourcekit-lsp-<pid>.<log index>.log`.

This allows us to retrieve the log messages from `sourcekit-lsp diagnose`.

We should be able to expand this to also write to log files on Windows but I still need to figure out what an appropriate log directory might be. That will be a follow-up PR.

Fixes apple#1286
rdar://127138318
ahoppen added a commit to ahoppen/sourcekit-lsp that referenced this issue Jun 5, 2024
Instead of logging to `stderr`, write log messages to files in `.sourcekit-lsp/logs/sourcekit-lsp-<pid>.<log index>.log`.

This allows us to retrieve the log messages from `sourcekit-lsp diagnose`.

Fixes apple#1286
rdar://127138318
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant