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
Cannot make cache folder #5
Comments
Thank you for using my application.
If there is no such directory in the current directory, I think we failed to create the directory in the binary. |
or please use #4 (comment) binary |
I was using the Release build "SlackLogViewer.v1.1.Beta-4.1-macos.tar.xz", will try the approach in the comment, thank you @thayakawa-gh @cielavenir ! Will let you know how it goes |
Thank you! I used the binary linked by @cielavenir , it still did not work, but then I took it apart and recreated in the following way:
And it worked. Seems that the Cache and Resource folders need to be place alongside of the "SlackLogViewer" inside the Having created this folder structure, my observations were the following:
|
@rusq It seems extracting by Unarchiver is subject to quarantine (gatekeeper) and it causes weird cwd. as shown in this movie, please extract by Archive Utility (or terminal "tar xf"). extract_slacklogviewer.mp4 |
oh, need to run |
Hi @cielavenir, thanks for the update, and sharing the video: I tried it with the same result - recorded a video too: https://mega.nz/file/uzBSgRob#_WyX874j5dglxwODDm_VXTCUpKK7Yo7ZlQs8n4LG-bk (325.8 MB) I did reset xattr, but I also used The reason I'm looking at this project, as I'm thinking of listing it as an option to view Slack files in the slackdump project, before this, I'm trying to test it myself, to understand how easy is it to use. I personally really like it - it works much faster than |
@rusq Perhaps I have to fix the codes accessing to caches and resources. I have been looking into the behavior of macOS and application bundle for a while, and it seems that these files cannot be accessed correctly in the same way as windows or linux. As you know, this application was just made for windows, not for macOS. I was just testing to make it read the zip file that slackdump outputs (and found some problems). I will publish a new release including the fixes above in the near future. |
ah... thank you for the video, according to it your "current directory" is clearly I get sometimes confused as I'm not sure about GUI apps current directory on both macOS and Win and I don't know how to fix it... Anyway with #8 , Cache and Resources are moved to SlackLogViewer.app/Content/MacOS and the "current directory" is forced there, and the issue should be gone. Please check the "macos" binary in https://github.com/cielavenir/SlackLogViewer/actions/runs/2949398984 (As a "bonus", this SlackLogViewer.app can be put to /Applications) |
@cielavenir I think that using the absolute paths to Cache and Resources are more preferable than changing current directory in the application. It is possible that for some reason, for example, when users want to output some files to the working directory, the current directory becomes unchangeable. And, in the Qt app, there is an easy way to get the path. By the way, is "MacOS" directory suitable for the location of the resources and temporary files? Some articles seems to suggest that such files should be placed in "Resources" directory. |
@thayakawa-gh actually SlackLogViewer.app/Contents/Resources/ and $HOME/Caches/SlackLogViewer are better dirs. The thing is SlackLogViewer's entire directory access has to be rewritten. |
Thanks for looking into this. Probably, for cache dir, it would be possible to adopt the same logic used by Or, probably, $TEMP could be considered? |
@thayakawa-gh to be clear, I mean there are so many hardcoded Cache/ and Resource/. Could you put these string into a function? (otherwise I still feel chdir is quickest workaround) |
Please check the test branch. All hard-coded paths have been rewritten, and the paths to Cache and Resources are defined in lines 13-29 of main.cpp. I'm not sure whether QDir::temp() (returns The binary for macOS is here (thanks to @cielavenir). However, I have a hard time deciding where to store caches. I use the function of the cache as practially a backup of files (and recommend users to do so in this article). If they are stored in the temporary dir, there is a possibility that users may unintentionally delete them. Should we allow users to choose where to store them? For example, place under the same directory as the Resources by default and make it rewritable in |
@thayakawa-gh the binary does not work... direct execution says this |
@cielavenir Thank you for testing. |
This one works @rusq ok on your machine as well? |
@cielavenir @thayakawa-gh It works, straight out of the archive! Thank you for resolving this :) |
I will have couple of more suggestions, if you don't mind, will describe in separate issues. Thanks for resolving this so quickly - it's a great product and I personally think it's much better and more convenient to use then other viewers out there in both speed of operation and the code quality. There's a high interest in export viewers, because slack has introduced this silly 90-day policy on the free accounts, where any message older than 90 days is hidden, so people are exporting their workspaces. I'll post a link to the SlackLogViewer in the slackdump repo. |
@rusq that's nice @thayakawa-gh thank you for the support |
@rusq I'm glad I could help you. @cielavenir Thank you for your investigation. Comments and Suggestions are always welcome, please feel free to contact me. However, I will be very busy for the next half year, so I don't know if I will be able to accommodate you right away... |
Thank you! Of course, I understand. Open source projects are like collective farm - everyone is responsible for their own happiness 😂 Maybe I'll refresh my C++ knowledge and would be able to contribute at some point, I have QtCreator installed on my machine, but did not have any practical application for it. Maybe that's the chance! I mentioned this project, along with what I'm to suggest in the discussion that was started by one of the contributors to slackdump - maybe you could share some insights and suggestions too?rusq/slackdump#127 |
@rusq I browsed the discussion and found it interesting. I will comment if I come up something. |
Hi there, just read about this tool on note.com, it looks great, I was eager to try it out, but getting this error on macOS 15.2 monterey: "cannot make cache folder"
Steps to reproduce:
Expected behaviour:
4. File is loaded.
I read this article (with google translate), and understand that there's some difficulty for testing and debugging on macOS, but thought I'd create an issue to flag this.
Thank you :)
The text was updated successfully, but these errors were encountered: