Go Down

Topic: Arduino IDE and OneDrive (Read 203 times) previous topic - next topic

mc2software

I've read a few posts on issues compiling a project with the IDE if you use OneDrive for your sketches and some libraries.  I've started building my own library of functions that I regularly use in various projects, and have recently found that the IDE cannot load the header file if it's on OneDrive. One post (arduino not finding my libraries) from 2018, reports that the issue was resolved in an up-coming build, but I seem to still have that issue.  I cannot move my sketches to a local drive (as I have two computers on which I do development) and I cannot set OneDrive to store all cloud files locally (which is what happens when you unmark "Files On-Demand") due to the amount of data stored on my OneDrive, however the setting for the folder and all subfolders where sketches are stored is set to "Always keep on this device", which stores files locally. Is this sitll an issue with the Arduino IDE? I'm running 1.8.13 but have the same issue on 1.8.12. Oddly, I recall not having this issue a few months ago but don't recall which build I was running. 

pert

I wonder if it's related to the relatively recent "controlled folder access" feature added to Windows Defender:
https://docs.microsoft.com/en-us/windows/security/threat-protection/microsoft-defender-atp/controlled-folders
This adds special restrictions to the C:\Users\<user name>\Documents folder and some other similar folders which can interfere with the Arduino IDE's ability to access files in those folders.

If it affects the location of your sketchbook folder, you might try temporarily disabling this feature then doing a compilation with a library you were having trouble with to check whether it makes the problem go away. If so, you could either configure Windows Defender to whitelist the folder or else you can move the Arduino sketchbook folder to a location not under the "controlled folder access" restrictions (you can customize your sketchbook location in the Arduino IDE at File > Preferences > Sketchbook Location).

ballscrewbob

Using ONEDRIVE has always been fraught with random issues.
You may have better luck using the SYNC mode for onedrive.
That will allow you to keep local copies and run those but will sync with one drive to keep a copy on there.

If the computers are close enough also consider a shared folder which can be a more robust version of sharing than onedrive.

It may not be the answer you were looking for but its the one I am giving based on either experience, educated guess, google (who would have thunk it ! ) or the fact that you gave nothing to go with in the first place so I used my wonky crystal ball.

mc2software

Using ONEDRIVE has always been fraught with random issues.
You may have better luck using the SYNC mode for onedrive.
That will allow you to keep local copies and run those but will sync with one drive to keep a copy on there.

If the computers are close enough also consider a shared folder which can be a more robust version of sharing than onedrive.
That folder is configured to store files locally and sync to the cloud.  
Considered a shared folder, but now that I'm no longer running a domain internally, shares are cumbersome, but mostly it would also make me use my VPN when I'm travelling and I'd lose the versioning/file history I get from OneDrive. 
I'm mostly trying to figure out why it was working a month ago and not now rather than changing my configurations. I do not allow automatic Windows updates but ran the update last week, so I might revert to a backup from when it was working to see if Windows is the issue (though, if that's the outcome, I'm hosed for Windows updates). 

mc2software

I wonder if it's related to the relatively recent "controlled folder access" feature added to Windows Defender:
I don't have that feature installed, but I did test compilation with Defender disabled and same problem.

ballscrewbob

You don't need to have a domain to use shared folders.

The CREATE option as an IDE could also be useful to you if you really want to be able to access the same sketches from multiple computers.

Using remote access VPN as you say can also be a viable option.

I don't use regular cloud based services simply because you are at the mercy of changes by those services in terms of OS changes.





It may not be the answer you were looking for but its the one I am giving based on either experience, educated guess, google (who would have thunk it ! ) or the fact that you gave nothing to go with in the first place so I used my wonky crystal ball.

mc2software

You don't need to have a domain to use shared folders.
I am aware of that. They're just harder to manage in a workgroup if you're regularly changing your login password.


mc2software

The CREATE option as an IDE could also be useful to you if you really want to be able to access the same sketches from multiple computers.
Interesting option, but I currently develop in about 1/2 dozen languages and environments, so keeping everything in one location on OneDrive is the most efficient.

ballscrewbob

As it seems specific to your particular case I don't really know what else to offer for advice apart from maybe opening an official ticket HERE

Not sure how much traction that will get you but certainly worth the effort.

Bob.

It may not be the answer you were looking for but its the one I am giving based on either experience, educated guess, google (who would have thunk it ! ) or the fact that you gave nothing to go with in the first place so I used my wonky crystal ball.

mc2software

I was trying to see if someone had a similar issue, where it was working fine a few weeks ago (on both PCs) and then suddenly it wasn't working. I suspect it's related to a Windows update but haven't dug any further into a compiler log or trying the command line.  I've a work-around for now (copying the code from the library into the sketch) and that'll be fine for the short term. 

Go Up