Skip to content

Commit

Permalink
Flagged register and upload commands and deprecated.
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Sep 5, 2024
1 parent c2c1f32 commit ddc1555
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions distutils/command/register.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import logging
import urllib.parse
import urllib.request
import warnings
from distutils._log import log

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

def run(self):
warnings.warn("register command is deprecated. Do not use.")
self.finalize_options()
self._set_config()

Expand Down
2 changes: 2 additions & 0 deletions distutils/command/upload.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import io
import logging
import os
import warnings
from base64 import standard_b64encode
from urllib.parse import urlparse
from urllib.request import HTTPError, Request, urlopen
Expand Down Expand Up @@ -63,6 +64,7 @@ def finalize_options(self):
self.password = self.distribution.password

def run(self):
warnings.warn("upload command is deprecated. Do not use.")
if not self.distribution.dist_files:
msg = (
"Must create and upload files in one command "
Expand Down
4 changes: 4 additions & 0 deletions pytest.ini
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,7 @@ filterwarnings=
# https://sourceforge.net/p/docutils/bugs/490/
ignore:'encoding' argument not specified::docutils.io
ignore:UTF-8 Mode affects locale.getpreferredencoding()::docutils.io

# suppress known deprecation
ignore:register command is deprecated
ignore:upload command is deprecated

0 comments on commit ddc1555

Please sign in to comment.