mfuentesg / SyncSettings

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

'module' object has no attribute 'exceptions' #118

Closed tobihagemann closed 5 years ago

tobihagemann commented 5 years ago

Just updated to Sublime Text 3.2 and noticed that Sync Settings outputs the error, e.g. when trying to upload or download:

'module' object has no attribute 'exceptions'

But I'm not 100% certain that it's caused by the new update because I haven't used Sync Settings for a while. If someone can confirm the issue (or not), that would be great.

mfuentesg commented 5 years ago

hey @tobihagemann could you paste logs here please, run Show Logs command.

Thanks in advance

tobihagemann commented 5 years ago

Hm, I don't have the errors anymore but I haven't changed anything afaik. Well, here are the logs anyway but I guess the issue can be closed?!

Download

Traceback (most recent call last):
  File "/Users/<redacted>/Library/Application Support/Sublime Text 3/Installed Packages/Sync Settings.sublime-package/sync_settings/commands/download.py", line 45, in download
    ).get(settings.get('gist_id'))
  File "/Users/<redacted>/Library/Application Support/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 "/Users/<redacted>/Library/Application Support/Sublime Text 3/Installed Packages/Sync Settings.sublime-package/sync_settings/libs/gist.py", line 83, in get
    return self.__do_request('get', self.make_uri(gid)).json()
  File "/Users/<redacted>/Library/Application Support/Sublime Text 3/Installed Packages/Sync Settings.sublime-package/sync_settings/libs/gist.py", line 93, in __do_request
    except requests.exceptions.ConnectionError as e:
AttributeError: 'module' object has no attribute 'exceptions'
ERROR:Sync Settings.sync_settings.libs.logger:'module' object has no attribute 'exceptions'
Traceback (most recent call last):
  File "/Users/<redacted>/Library/Application Support/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)
AttributeError: 'module' object has no attribute 'patch'

Upload

Traceback (most recent call last):
  File "/Users/<redacted>/Library/Application Support/Sublime Text 3/Installed Packages/Sync Settings.sublime-package/sync_settings/commands/upload.py", line 28, in upload
    data={'files': files}
  File "/Users/<redacted>/Library/Application Support/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 "/Users/<redacted>/Library/Application Support/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 "/Users/<redacted>/Library/Application Support/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 "/Users/<redacted>/Library/Application Support/Sublime Text 3/Installed Packages/Sync Settings.sublime-package/sync_settings/libs/gist.py", line 93, in __do_request
    except requests.exceptions.ConnectionError as e:
AttributeError: 'module' object has no attribute 'exceptions'
ERROR:Sync Settings.sync_settings.libs.logger:'module' object has no attribute 'exceptions'
Traceback (most recent call last):
  File "/Users/<redacted>/Library/Application Support/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)
AttributeError: 'module' object has no attribute 'patch'
mfuentesg commented 5 years ago

the unique way to receive that kind of errors, is because the requests module has not been installed in your sublime text yet. probably, after restart, the installation had been completed.

tobihagemann commented 5 years ago

All right, everything is fine then. :smile: Thanks!

shirobachi commented 4 years ago

I had same problem. Restart resolved it 🤣 Thanks for that case :)