Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
setuptools
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jérome Perrin
setuptools
Commits
6aae9fb3
Commit
6aae9fb3
authored
Dec 05, 2016
by
idle sign
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
`strict_mode` removed to improve forward compatibility.
parent
163f3644
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
21 deletions
+1
-21
setuptools/config.py
setuptools/config.py
+1
-9
setuptools/tests/test_config.py
setuptools/tests/test_config.py
+0
-12
No files found.
setuptools/config.py
View file @
6aae9fb3
...
...
@@ -100,12 +100,6 @@ class ConfigHandler(object):
"""
strict_mode
=
True
"""Flag. Whether unknown options in config should
raise DistutilsOptionError exception, or pass silently.
"""
def
__init__
(
self
,
target_obj
,
options
):
sections
=
{}
...
...
@@ -316,9 +310,7 @@ class ConfigHandler(object):
self
[
name
]
=
value
except
KeyError
:
if
self
.
strict_mode
:
raise
DistutilsOptionError
(
'Unknown distribution option: %s'
%
name
)
pass
# Keep silent for a new option may appear anytime.
def
parse
(
self
):
"""Parses configuration file items from one
...
...
setuptools/tests/test_config.py
View file @
6aae9fb3
...
...
@@ -417,18 +417,6 @@ class TestOptions:
with
get_dist
(
tmpdir
)
as
dist
:
assert
dist
.
packages
==
[
'fake_package'
]
def
test_unknown_options_item
(
self
,
tmpdir
):
fake_env
(
tmpdir
,
'[options]
\
n
'
'zip_safe = True
\
n
'
'usr_2to3 = 1
\
n
'
)
with
get_dist
(
tmpdir
,
parse
=
False
)
as
dist
:
with
pytest
.
raises
(
DistutilsOptionError
):
dist
.
parse_config_files
()
def
test_extras_require
(
self
,
tmpdir
):
fake_env
(
tmpdir
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment