Skip to content

Commit 288c146

Browse files
committed
Ran pre-commit to hopefully resolve conflicting files
1 parent 27e248e commit 288c146

File tree

6 files changed

+56
-96
lines changed

6 files changed

+56
-96
lines changed

.pre-commit-config.yaml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# SPDX-FileCopyrightText: 2020 Diego Elio Pettenò
2+
#
3+
# SPDX-License-Identifier: Unlicense
4+
5+
repos:
6+
- repo: https://github.com/python/black
7+
rev: stable
8+
hooks:
9+
- id: black
10+
- repo: https://github.com/fsfe/reuse-tool
11+
rev: latest
12+
hooks:
13+
- id: reuse
14+
- repo: https://github.com/pre-commit/pre-commit-hooks
15+
rev: v2.3.0
16+
hooks:
17+
- id: check-yaml
18+
- id: end-of-file-fixer
19+
- id: trailing-whitespace

CODE_OF_CONDUCT.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
<!--
2+
SPDX-FileCopyrightText: 2014 Coraline Ada Ehmke
3+
SPDX-FileCopyrightText: 2019 Kattni Rembor for Adafruit Industries
4+
SPDX-License-Identifier: CC-BY-4.0
5+
-->
6+
17
# Adafruit Community Code of Conduct
28

39
## Our Pledge

adafruit_wiznet5k/adafruit_wiznet5k.py

Lines changed: 19 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,12 @@
1-
# The MIT License (MIT)
1+
# SPDX-FileCopyrightText: 2010 WIZnet
2+
# SPDX-FileCopyrightText: 2010 Arduino LLC
3+
# SPDX-FileCopyrightText: 2008 Bjoern Hartmann
4+
# SPDX-FileCopyrightText: 2018 Paul Stoffregen
5+
# SPDX-FileCopyrightText: 2020 Brent Rubell for Adafruit Industries
6+
# SPDX-FileCopyrightText: 2021 Patrick Van Oosterwijck
27
#
3-
# Copyright (c) 2010 WIZnet
4-
# Copyright (c) 2010 Arduino LLC
5-
# Copyright (c) 2008 Bjoern Hartmann
6-
# Copyright 2018 Paul Stoffregen
7-
# Modified by Brent Rubell for Adafruit Industries, 2020
8-
# Copyright (c) 2021 Patrick Van Oosterwijck
9-
#
10-
# Permission is hereby granted, free of charge, to any person obtaining a copy
11-
# of this software and associated documentation files (the "Software"), to deal
12-
# in the Software without restriction, including without limitation the rights
13-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
14-
# copies of the Software, and to permit persons to whom the Software is
15-
# furnished to do so, subject to the following conditions:
16-
#
17-
# The above copyright notice and this permission notice shall be included in
18-
# all copies or substantial portions of the Software.
19-
#
20-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
26-
# THE SOFTWARE.
8+
# SPDX-License-Identifier: MIT
9+
2710
"""
2811
`adafruit_wiznet5k`
2912
================================================================================
@@ -770,13 +753,17 @@ def socket_write(self, socket_num, buffer, timeout=0):
770753
while (
771754
self._read_socket(socket_num, REG_SNIR)[0] & SNIR_SEND_OK
772755
) != SNIR_SEND_OK:
773-
if self.socket_status(socket_num)[0] in (
774-
SNSR_SOCK_CLOSED,
775-
SNSR_SOCK_TIME_WAIT,
776-
SNSR_SOCK_FIN_WAIT,
777-
SNSR_SOCK_CLOSE_WAIT,
778-
SNSR_SOCK_CLOSING,
779-
) or (timeout and time.monotonic() - stamp > timeout):
756+
if (
757+
self.socket_status(socket_num)[0]
758+
in (
759+
SNSR_SOCK_CLOSED,
760+
SNSR_SOCK_TIME_WAIT,
761+
SNSR_SOCK_FIN_WAIT,
762+
SNSR_SOCK_CLOSE_WAIT,
763+
SNSR_SOCK_CLOSING,
764+
)
765+
or (timeout and time.monotonic() - stamp > timeout)
766+
):
780767
# self.socket_close(socket_num)
781768
return 0
782769
time.sleep(0.01)

adafruit_wiznet5k/adafruit_wiznet5k_dhcp.py

Lines changed: 4 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,8 @@
1-
# The MIT License (MIT)
1+
# SPDX-FileCopyrightText: 2009 Jordan Terell (blog.jordanterrell.com)
2+
# SPDX-FileCopyrightText: 2020 Brent Rubell for Adafruit Industries
23
#
3-
# Copyright (c) April 25, 2009 Jordan Terrell (blog.jordanterrell.com)
4-
# Modified by Brent Rubell for Adafruit Industries, 2020
5-
#
6-
# Permission is hereby granted, free of charge, to any person obtaining a copy
7-
# of this software and associated documentation files (the "Software"), to deal
8-
# in the Software without restriction, including without limitation the rights
9-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10-
# copies of the Software, and to permit persons to whom the Software is
11-
# furnished to do so, subject to the following conditions:
12-
#
13-
# The above copyright notice and this permission notice shall be included in
14-
# all copies or substantial portions of the Software.
15-
#
16-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22-
# THE SOFTWARE.
4+
# SPDX-License-Identifier: MIT
5+
236
"""
247
`adafruit_wiznet5k_dhcp`
258
================================================================================

adafruit_wiznet5k/adafruit_wiznet5k_dns.py

Lines changed: 4 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,8 @@
1-
# The MIT License (MIT)
1+
# SPDX-FileCopyrightText: 2009-2010 MCQN Ltd
2+
# SPDX-FileCopyrightText: Brent Rubell for Adafruit Industries
23
#
3-
# (c) Copyright 2009-2010 MCQN Ltd
4-
# Modified by Brent Rubell for Adafruit Industries, 2020
5-
#
6-
# Permission is hereby granted, free of charge, to any person obtaining a copy
7-
# of this software and associated documentation files (the "Software"), to deal
8-
# in the Software without restriction, including without limitation the rights
9-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10-
# copies of the Software, and to permit persons to whom the Software is
11-
# furnished to do so, subject to the following conditions:
12-
#
13-
# The above copyright notice and this permission notice shall be included in
14-
# all copies or substantial portions of the Software.
15-
#
16-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22-
# THE SOFTWARE.
4+
# SPDX-License-Identifier: MIT
5+
236
"""
247
`adafruit_wiznet5k_dns`
258
================================================================================

adafruit_wiznet5k/adafruit_wiznet5k_socket.py

Lines changed: 4 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,8 @@
1-
# The MIT License (MIT)
1+
# SPDX-FileCopyrightText: 2019 ladyada for Adafruit Industries
2+
# SPDX-FileCopyrightText: 2020 Brent Rubell for Adafruit Industries
23
#
3-
# Copyright (c) 2019 ladyada for Adafruit Industries
4-
# Modified by Brent Rubell for Adafruit Industries, 2020
5-
# Copyright (c) 2020 Patrick Van Oosterwijck
6-
#
7-
# Permission is hereby granted, free of charge, to any person obtaining a copy
8-
# of this software and associated documentation files (the "Software"), to deal
9-
# in the Software without restriction, including without limitation the rights
10-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11-
# copies of the Software, and to permit persons to whom the Software is
12-
# furnished to do so, subject to the following conditions:
13-
#
14-
# The above copyright notice and this permission notice shall be included in
15-
# all copies or substantial portions of the Software.
16-
#
17-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
23-
# THE SOFTWARE.
4+
# SPDX-License-Identifier: MIT
5+
246
"""
257
`adafruit_wiznet5k_socket`
268
================================================================================

0 commit comments

Comments
 (0)