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

RASCAL.MF generated by newRascalProject triggers an error in VS Code #2079

Closed
sungshik opened this issue Nov 13, 2024 · 4 comments
Closed

RASCAL.MF generated by newRascalProject triggers an error in VS Code #2079

sungshik opened this issue Nov 13, 2024 · 4 comments
Assignees
Labels

Comments

@sungshik
Copy link
Contributor

Describe the bug

Function newRascalProject in module util::Reflective produces a META-INF/RASCAL.MF that triggers an error in VS Code when a Rascal terminal is opened.

image

To Reproduce

  1. Create a new Rascal project using function newRascalProject in module util::Reflective
  2. Open the new project in VS Code
  3. Open a new Rascal terminal (not necessarily using a code lens in a module)

Possible fix

This seems to be the code to generate RASCAL.MF:

private str rascalMF(str name)
= "Manifest-Version: 0.0.1
'Project-Name: <name>
'Source: src/main/rascal
'Require-Libraries:
";

Adding a single quote to line 412 might be enough (but I'm not sure):

    '";
@sungshik sungshik added the bug label Nov 13, 2024
@jurgenvinju
Copy link
Member

I think adding '\n" would fix this. I have the feeling we fixed this one before.. but who knows. Good catch!

@DavyLandman
Copy link
Member

I think @sungshik proposed fix is right, as indeed, a .MF file has to end with a blank newline. no spaces no nothing.

@jurgenvinju
Copy link
Member

Right! Let's do it.

Isn't it strange that there is no parse error in the original buggy template? Doesn't every non-escaped newline inside a string come with a single quote?

@sungshik sungshik self-assigned this Nov 18, 2024
@sungshik
Copy link
Contributor Author

sungshik commented Nov 18, 2024

Right! Let's do it.

Ok, doing this now Done. See #2080.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants