-
-
Notifications
You must be signed in to change notification settings - Fork 390
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
Wrong package folder after AHK installation #1198
Comments
While I don't doubt there could be a bug, I don't see it. To reproduce, I used:wineserver -k ; rm -rf ~/.wine ~/.cache/winetricks/ahk/ ~/.cache/winetricks/mt4/ ; winetricks -q mt4 so it's a clean prefix and mt4/ahk aren't downloaded. I added some echos to see what the cwd is:
running that (after WINEDEBUG=-all to reduce output), shows the cwd is set properly:
w_download will cd (to the cache directory), but it does a cd to the previous directory before it finishes. As you can see above, when w_ahk_do() runs, the CWD is ~/.cache/winetricks/mt4. If you want set -x; you can use winetricks -v (though calling it directly with bash -x should also work). There's a small portion of the code that disables set -x (generating the metadata) which is superverbose, but if you want it, you can use -vv or --really-verbose. In addition, the files are in their correct place in the cache:
Note: I'm not using docker. I don't see why docker would break things, but you may wan to try without docker to see what's different. In addition, make sure you're really using the latest winetricks (20190310-next) |
I've recorded cast at: To play on local terminal, so it can be terminal scrolled, run:
Here is the relevant log:
This could be the cause?
Not sure what's special in my configuration. Maybe it's because AHK every time is downloaded after 2nd attempt, it's due to Captcha hit while downloading AHK, so it always gets the archived version (I've got the Captcha on their website even on my web-browser, I'm from UK, I didn't use VPN). So if the code tried to back to previous path, not sure of the logic, it goes back to AHK, since it was entering this dir around 3 times. Re captcha, I've other scripts which are installing AHK (which can help), but from the GitHub directly, to avoid Captcha. |
I wasn't aware that there was a github option now, that's good to know. Yeah, I was suspicious of the olddir variable. It's being set inside the loop, which would cause your problem. I don't know why I'm not getting the captcha, I ran several times without issue. In any case, does https://github.com/austin987/winetricks/tree/1198-autohotkey make a difference for you? It should solve the problem in two ways (use github so you don't get the captcha, and fix the variable being overwritten). |
The branch fails to install 7z.
It seems Log file: winetricks.log |
It's unset if you don't use -q, which makes sense on first thought, but yeah, is bad if a user doesn't have 7z installed AND runs winetricks in GUI mode AND uses a verb with w_ahk_do(). So, there are at least two things that I think need to happen:
Could you confirm that winetricks -q mt4 (with my branch with the previously mentioned branch) correctly launches the mt4 installer for you (it won't install, since the upstream installer changed, which is what I assume you meant to fix in the first place)? |
Issue with 7zip installationI've run as
It failed for Wine v4.5 (Windows 7). Same with I've checked I thought the workaround would be installing So in summary:
I've tried changing Windows 10 back to Windows 7 and opposite. So I'm not quiet sure why it's installing in different folder. WorkaroundFor workaround, removing Original issueFollowing the above workaround with 7zip, the installation wizard seems to run correctly. I've tested on Ubuntu host using In summary, as reported originally, it seems the folder is changed to correct one after the fixes, right before running AHK script:
If you think 7zip installation can be improved, that's great, otherwise I think your branch got enough fixes for now. |
The 7zip installation may have a bug, but I can't reproduce it. Works here with 32/64 bit wine, with/without xvfb. E.g.,:
I'll push the current fixes shortly and close this. If you find more issues, please open a new bug (or send a PR for the mt4 stuff ;) ). |
I'm using the latest
winetricks
.I'd like to fix/improve the installation of MT4, however I've encouraged some bug in
winetricks
.In
load_mt4()
we dow_download
then_try_cd "$W_CACHE/$W_PACKAGE"
right beforew_ahk_do
in order to run${file1}
.However first time when AHK is installed, on
w_ahk_do
execution, we're already in the wrong folder. We are in AHK folder, not in package one.Here are reproducible steps using Docker container:
docker run -it ea31337/ea-tester bash
.wget https://raw.githubusercontent.com/Winetricks/winetricks/master/src/winetricks
../eval.sh set_display
(you can connect to it via VNC).DISPLAY
by:export DISPLAY=:0.0
.bash -x winetricks mt4
.Relevant output:
Additional notes:
${file1}
doesn't exist inahk
folder, but it exists inmt4
(~/.cache/winetricks/mt4/
).-x
) at some point, so it's not clear what's going on.w_download
just beforew_try_cd
, but it seems it didn't fix it.w_ahk_do
it-self, changes the folder?w_ahk_do
with$file1
in AHK script.The text was updated successfully, but these errors were encountered: