Open altomcat opened 2 years ago
I have the same problem on windows 11. If run dos2unix on pyproject.toml, then everything works, so a dumb workaround would be to configure git to keep pyproject.toml in unix format. The patch proposed by @altomcat two years ago seems like a good solution, why hasn't this been fixed?
Have the same issue on Windows 10.
Any progress on this?
I really can not reproduce this on any system, unfortunately.
I'll try to test this in a Windoze VM asap. And it will be Windows on ARM, for what it's worth.
However, the proposed fix is looking not right for me.
There's no final ]
that must be escaped IMHO, as ]
is only treated as a special character if there's a preceding unquoted [
and there isn't.
https://www.gnu.org/software/emacs/manual/html_node/elisp/Regexp-Special.html
In addition, it's still unclear to me what [^M]
should do any good in this case. If anything related to windows carriage return line breaks, the regex should be (\r?\n)
instead of $
, but this remains to be proven to be even remotely necessary.
For all the users affected by these issue (100% using MS Windows):
I'd be good to have the following information:
[ ] What version of poetry.el are you using? As a doom emacs user, e.g., the latest commits are not yet in upstream
[ ] How are you using Emacs on Windows? I'm guessing the whole WSL1/WSL2 user base does not have this problem, so it's limited to the binary builds from Corwin Brust available on gnu.org, right?
I did an update recently and my poetry projects were no longer recognized. I found a regex error in the poetry-find-project-root function where the final ] must be escaped.
Sometimes I've used a different text editor to edit pyproject.toml . It can add carriage returns at the end of each lines, so I've changed the regex a bit to handle them. There may be a more elegant way to do this, but that's another story.
Here is the diff with the changes I made.