Skip to content

Commit 6c353a2

Browse files
authored
Copyedit error messages
1 parent af3eaa3 commit 6c353a2

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

adafruit_portalbase/network.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -154,8 +154,7 @@ def _get_setting(self, setting_name):
154154
env_value = secrets.get(secrets_setting_name)
155155
if env_value is not None:
156156
warnings.warn(
157-
"The using of `secrets`, is deprecated. Please put your settings in "
158-
"settings.toml"
157+
"Using secrets.py for network settings is deprecated. Put your settings in settings.toml."
159158
)
160159
self._settings[setting_name] = env_value
161160
return env_value
@@ -225,8 +224,8 @@ def get_strftime(self, time_format, location=None, max_attempts=10):
225224
aio_key = self._get_setting("ADAFRUIT_AIO_KEY")
226225
except KeyError:
227226
raise KeyError(
228-
"\n\nOur time service requires a login/password to rate-limit. "
229-
"Please register for a free adafruit.io account and place the user/key in "
227+
"\nThe Adafruit IO time service requires a login and password. "
228+
"Rgister for a free adafruit.io account and put the username and key in "
230229
"your settings.toml file under 'ADAFRUIT_AIO_USERNAME' and 'ADAFRUIT_AIO_KEY'"
231230
) from KeyError
232231

@@ -257,7 +256,7 @@ def get_strftime(self, time_format, location=None, max_attempts=10):
257256
reply = response.text
258257
except KeyError:
259258
raise KeyError(
260-
"Was unable to lookup the time, try setting 'timezone' in your settings.toml"
259+
"Unable to lookup the time, try setting 'timezone' in your settings.toml"
261260
"according to http://worldtimeapi.org/timezones"
262261
) from KeyError
263262
# now clean up

0 commit comments

Comments
 (0)