KentonWhite/ProjectTemplate

Clear objects from the workspace - deleted cached files - no such file or directory

Closed this issue · 4 comments

Report an Issue / Request a Feature

I'm submitting a (Check one with "x") :

  • [X ] bug report
  • feature request

Issue Severity Classification -

(Check one with "x") :

  • [X ] 1 - Severe
  • 2 - Moderate
  • 3 - Low
Expected Behavior

Files should load from cached folder, if exists, or data folder and recreate cached objects.

Current Behavior

I get the following errors and cannot load anything ...

Autoloading data
Loading data set: Dealers
Error in file(file, "rt") : cannot open the connection
In addition: Warning message:
In file(file, "rt") :
cannot open file 'C:\Users\wl694\AppData\Local\Temp\RtmpGWg6LA/Dealers.csv': No such file or directory

Steps to Reproduce Behavior

I copied several files into the data folder which were from another project and didn't want the objects loaded in memory for this project. I pressed the "clear objects from the workspace" button, deleted the files from the data folder and ran load.project() to reload. Unfortunately it reloaded the objects from the cache folder so I repeated the process and deleted cached objects in between. I suspect it has some hidden records of what was loaded which do not automatically get removed?

insert short code snippets here

Screenshots
Version Information
Possible Solution

Perhaps the program needs to check whether cached objects still exist and remove them from some record somewhere at the beginning?

Its not advised manually deleting files from the cache. If you want to remove cached files, try the clear.cacher() command.

I actually ran that command but I still have the error. I will try to rename the project and then recreate with the original name and see if that resolves the issue.

I renamed the directory. Created a project with the original name in the original location. Copied my config and data files. Tried to load the project but it gives me the same error. Are the files I previously loaded stored in a file somewhere so I can delete the entries and reload? I didn't know I couldn't delete the cached files ... next time I'll use the cache clear function.

Disregard, I figured out the issue. I had zip files in my data directory to keep file size down for integrating version control. The zip file names were long so I renamed them; however, the file inside had the original name. The program must use the zip file name to look for the unzipped file and this will fail whenever the two are not the same. Perhaps it could get the name as it opens the zip to prevent this kind of failure in the future. Please close this issue.