Skip to content

Commit ddc1555

Browse files
committed
Flagged register and upload commands and deprecated.
1 parent c2c1f32 commit ddc1555

File tree

3 files changed

+8
-0
lines changed

3 files changed

+8
-0
lines changed

distutils/command/register.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
import logging
1111
import urllib.parse
1212
import urllib.request
13+
import warnings
1314
from distutils._log import log
1415

1516
from more_itertools import always_iterable
@@ -50,6 +51,7 @@ def finalize_options(self):
5051
self.distribution.command_options['check'] = check_options
5152

5253
def run(self):
54+
warnings.warn("register command is deprecated. Do not use.")
5355
self.finalize_options()
5456
self._set_config()
5557

distutils/command/upload.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
import io
1010
import logging
1111
import os
12+
import warnings
1213
from base64 import standard_b64encode
1314
from urllib.parse import urlparse
1415
from urllib.request import HTTPError, Request, urlopen
@@ -63,6 +64,7 @@ def finalize_options(self):
6364
self.password = self.distribution.password
6465

6566
def run(self):
67+
warnings.warn("upload command is deprecated. Do not use.")
6668
if not self.distribution.dist_files:
6769
msg = (
6870
"Must create and upload files in one command "

pytest.ini

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,3 +44,7 @@ filterwarnings=
4444
# https://sourceforge.net/p/docutils/bugs/490/
4545
ignore:'encoding' argument not specified::docutils.io
4646
ignore:UTF-8 Mode affects locale.getpreferredencoding()::docutils.io
47+
48+
# suppress known deprecation
49+
ignore:register command is deprecated
50+
ignore:upload command is deprecated

0 commit comments

Comments
 (0)