-
-
Notifications
You must be signed in to change notification settings - Fork 143
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
rdmd fixes (issues 14296, 16962 and 16978) #207
Conversation
…No such file or directory The actual fix was done by the revert. This simply adds a test.
The actual fix was done by the revert. This simply adds a test.
@wilzbach CI scripts should use fixed versions of components from other repositories (that are not being tested). Digger was "broken" (it failed to build due to a warning in ae) which was causing tests to fail. I've now pushed a fix, but Dub can't pick it up:
This is despite the tag existing on GitHub, of course. I think this is an instance of dlang/dub#1000, i.e. Dub being "broken by design" for now as far as deployment goes, so it's not usable for CI or deployment. |
Oh, OK. Tests are failing because #202 isn't in stable. |
Revert of #194 is fine with me. As I said in the discussion for issue 16962, I don't really have time to look into this at the moment. |
~ [ "-of"~fullExeTemp ] | ||
~ [ "-od"~objDir ] | ||
~ [ "-I"~dirName(root) ] | ||
~ [ root ]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
space around operators :)
// regardless of the operating system it's running on. | ||
std.file.write(rspName, array(map!escapeWindowsArgument(todo)).join(" ")); | ||
|
||
todo = [ "@"~rspName ]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
spaces
} | ||
|
||
immutable result = run([ compiler ] ~ todo); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
like here
auto depsGetter = | ||
// "cd "~shellQuote(rootDir)~" && " | ||
[ compiler ] ~ compilerFlags ~ | ||
["-v", "-o-", rootModule, "-I"~rootDir]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
spaces
@@ -28,11 +28,13 @@ version (Posix) | |||
{ | |||
enum objExt = ".o"; | |||
enum binExt = ""; | |||
enum libExt = ".a"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice
~this() | ||
{ | ||
import core.thread; | ||
Thread.sleep(100.msecs); // Hack around Windows locking the directory |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Put a version around it? Are there better workarounds? We shouldn't have people wait 100 extra milliseconds on all platforms. Note that currently "rdmd hello.d" takes 200ms on a typical Posix system to build.
I'll ask for changes because of this, rest are optional nits.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I didn't write this code (it was a refactoring), but might as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thx!!
|
||
version (linux) | ||
{ | ||
TmpDir srcDir = "rdmdTest"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
braces should indent
Please review commit by commit. You are reviewing changes in revert / refactoring commits. |
@CyberShadow well I clicked on "Files changed", wouldn't that comprise everything? |
Yes, but that's generally a broken way to review a multi-commit PR (where the successive commits aren't fixups, and they aren't here). |
I'll add the requested changes anyhow. |
Oh, and I should point out that that particular hack was in the test suite, not rdmd itself. But yeah, point stands. The problem is usually due to Windows Defender, the standard Windows anti-malware, or some other antivirus locking the directory so it could have a look at the files we create. We've had problems with it in Phobos tests as well. |
core.exception.AssertError@rdmd_test.d(139): /tmp/.rdmd-1000/eval.E60124B13F32A50795E744C041B53089.d(6): Error: module cstream is in file 'std/cstream.d' which cannot be read |
Yes, the fix for that is on another branch (master) as mentioned above. |
oh lemme take a lookie |
@CyberShadow @MartinNowak so what's the sequence needed to do this right? Pull #202 in stable first? |
@CyberShadow @MartinNowak ping |
I think we can cherry-pick #202 here. @MartinNowak ? Or we can ignore the CI status, since stable was failing without or with this PR. |
I think we should, because it was fixing a real problem |
Yes, cherry-picking is OK if necessary, but generally all fixes of released issues should always go into stable. |
No description provided.