mirror of
https://github.com/zebrajr/pytorch.git
synced 2025-12-06 12:20:52 +01:00
[BE] Do not add . after troubleshooting_url (#157753)
As it gets included into auto-hrefed URLs in say github logs to point to non existing location For example from https://github.com/pytorch/pytorch/actions/runs/16130448756/job/45517004735?pr=157749#step:18:27 > W0708 00:23:20.150000 67082 torch/_dynamo/convert_frame.py:1047] [0/8] To diagnose recompilation issues, see [https://pytorch.org/docs/main/torch.compiler_troubleshooting.html.](https://pytorch.org/docs/main/torch.compiler_troubleshooting.html.) Pull Request resolved: https://github.com/pytorch/pytorch/pull/157753 Approved by: https://github.com/zou3519, https://github.com/jansel
This commit is contained in:
parent
98bb0c0e78
commit
f88d7a7a34
|
|
@ -1050,12 +1050,14 @@ def _compile(
|
|||
def format_func_info(code: CodeType) -> str:
|
||||
return f"'{code.co_name}' ({code.co_filename}:{code.co_firstlineno})"
|
||||
|
||||
# NS: Don't add period at the end of string, as it'll be added to URL
|
||||
# renderring it incorrect
|
||||
log.warning(
|
||||
"torch._dynamo hit config.%s (%s)\n"
|
||||
" function: %s\n"
|
||||
" last reason: %s\n"
|
||||
'To log all recompilation reasons, use TORCH_LOGS="recompiles".\n'
|
||||
"To diagnose recompilation issues, see %s.",
|
||||
"To diagnose recompilation issues, see %s",
|
||||
limit_type,
|
||||
getattr(config, limit_type),
|
||||
format_func_info(code),
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user