flexcompute / tidy3d

Fast electromagnetic solver (FDTD) at scale.
https://docs.flexcompute.com/projects/tidy3d/en/latest/
GNU Lesser General Public License v2.1
180 stars 41 forks source link

Clickable link of simulation task not working in PyCharm when break into two lines #958

Open xin-flex opened 1 year ago

xin-flex commented 1 year ago

When the link breaks into two lines in the output, in PyCharm the link address is incorrect (partial):

image

while in Jupyter Lab the link address is correct (complete):

image

Is it possible to make the link in PyCharm also complete and work?

tylerflex commented 1 year ago

This is an issue with rich, I don't think there's anything I can do directly to fix it. What version of pycharm are you using? I can file a ticket with rich?

xin-flex commented 1 year ago

Indeed, here is the PyCharm version I used: 2022.2.2

tylerflex commented 1 year ago

@xin-flex can you try a simple test in your pycharm? and then make an issue in [rich](https://github.com/Textualize/rich)? I think we need them to look into it and I don't have pycharm so it might be easier if you can reproduce, maybe they can release a patch and it will work in tidy3d after that.

I would suggest just trying to print a very long link in your pycharm and if it doesn't click, post the script you used and have them look at it. (Docs)

You could just try these two lines in your pycharm and see if they work or not.

from rich import print
print("My long link: [link=https://www.google.com/search?q=test]aaaaaaaaaaaaaaaaaaaaaaaaaabbbbbbbbbbbbbbbbbbbbbbbccccccccccccccccccccccc[/link]!")
xin-flex commented 1 year ago

Thanks for the info! I tested in PyCharm and reproduced the issue, and actually there are two issues. See the details here: https://github.com/Textualize/rich/issues/3036