I have found that syncing folders to SharePoint one-drive limits the file path character limit to 218 characters and it counts "space" as equal to 3 characters, encoded to %20. Please confirm if any other special character is encoded and will be taking more space which eventually means the actual path is less than 218 characters.
Other Info:
OS: Windows 10 Pro
Office 365/SharePoint Online.
One-Drive: Build 18.151.0729.0012