mfuentesg / SyncSettings

Sync Settings - The cross-platform solution to keep Sublime Text configuration synchronized
https://mfuentesg.dev/SyncSettings
MIT License
287 stars 38 forks source link

Uploading Errors Out - "FileNotFoundError: No such file or directory" #202

Open munkybutt opened 2 years ago

munkybutt commented 2 years ago

Describe the bug I noticed that my settings were no longer syncing automatically, so I attempted to upload them manually and get this error:

ERROR:Sync Settings.sync_settings.libs.logger:Can`t perform this action due to network errors. reason: [Errno 2] No such file or directory
Traceback (most recent call last):
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\sublime-github.sublime-package\lib\requests\packages\urllib3\util.py", line 360, in ssl_wrap_socket
    context.load_verify_locations(ca_certs)
FileNotFoundError: [Errno 2] No such file or directory

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\sublime-github.sublime-package\lib\requests\adapters.py", line 292, in send
    timeout=timeout
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\sublime-github.sublime-package\lib\requests\packages\urllib3\connectionpool.py", line 428, in urlopen
    body=body, headers=headers)
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\sublime-github.sublime-package\lib\requests\packages\urllib3\connectionpool.py", line 280, in _make_request
    conn.request(method, url, **httplib_request_kw)
  File "./python3.3/http/client.py", line 1065, in request
  File "./python3.3/http/client.py", line 1103, in _send_request
  File "./python3.3/http/client.py", line 1061, in endheaders
  File "./python3.3/http/client.py", line 906, in _send_output
  File "./python3.3/http/client.py", line 844, in send
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\sublime-github.sublime-package\lib\requests\packages\urllib3\connectionpool.py", line 107, in connect
    ssl_version=resolved_ssl_version)
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\sublime-github.sublime-package\lib\requests\packages\urllib3\util.py", line 364, in ssl_wrap_socket
    raise SSLError(e)
requests.packages.urllib3.exceptions.SSLError: [Errno 2] No such file or directory

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\Sync Settings.sublime-package\sync_settings/libs/gist.py", line 92, in __do_request
    response = getattr(requests, verb)(url, headers=self.headers, proxies=self.proxies, **kwargs)
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\sublime-github.sublime-package\lib\requests\api.py", line 110, in patch
    return request('patch', url,  data=data, **kwargs)
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\sublime-github.sublime-package\lib\requests\api.py", line 44, in request
    return session.request(method=method, url=url, **kwargs)
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\sublime-github.sublime-package\lib\requests\sessions.py", line 335, in request
    resp = self.send(prep, **send_kwargs)
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\sublime-github.sublime-package\lib\requests\sessions.py", line 438, in send
    r = adapter.send(request, **kwargs)
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\sublime-github.sublime-package\lib\requests\adapters.py", line 331, in send
    raise SSLError(e)
requests.exceptions.SSLError: [Errno 2] No such file or directory

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\Sync Settings.sublime-package\sync_settings/commands/upload.py", line 28, in upload
    data={'files': files}
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\Sync Settings.sublime-package\sync_settings/libs/gist.py", line 36, in auth_wrapper
    return func(self, *args, **kwargs)
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\Sync Settings.sublime-package\sync_settings/libs/gist.py", line 46, in with_gid_wrapper
    return func(self, *args, **kwargs)
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\Sync Settings.sublime-package\sync_settings/libs/gist.py", line 73, in update
    return self.__do_request('patch', self.make_uri(gid), data=json.dumps(data)).json()
  File "C:\Users\Sheaky\AppData\Roaming\Sublime Text 3\Installed Packages\Sync Settings.sublime-package\sync_settings/libs/gist.py", line 94, in __do_request
    raise NetworkError('Can`t perform this action due to network errors. reason: {}'.format(str(e)))
Sync Settings.sync_settings.libs.gist.NetworkError: Can`t perform this action due to network errors. reason: [Errno 2] No such file or directory

Desktop (please complete the following information):

Log file content with debug property in true Log files are empty and I the debug property doesn't seem to exist in the settings :/

mfuentesg commented 2 years ago

Hey! Hmm, this has happened before, and it is due to some conflicting packages/plugins which are overwriting the file system for requests package, used to fetch/push information from/to GitHub.

As you can see in the logs, there are references to the "conflicting package". This time, this package is "sublime-github".

Si, as workaround, uninstall it and restart Sublime, and trying again. Please let me know if it solves the issue.

mfuentesg commented 2 years ago

Did you try it @munkybutt ?

munkybutt commented 2 years ago

Hey @mfuentesg - apologies for the delayed response. Yes this resolved the issue, but obviously there is now an issue of having to have another plugin I use disabled. I guess I should reach out to the dev of sublime-github about it?