optimism 3.1.4__tar.gz → 3.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- optimism-3.2/LICENSE.txt +55 -0
- {optimism-3.1.4 → optimism-3.2}/PKG-INFO +13 -3
- {optimism-3.1.4 → optimism-3.2}/README.md +11 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/__init__.py +1 -1
- {optimism-3.1.4 → optimism-3.2}/optimism/optimism.py +18 -4
- {optimism-3.1.4 → optimism-3.2}/optimism.egg-info/PKG-INFO +13 -3
- {optimism-3.1.4 → optimism-3.2}/setup.cfg +1 -2
- optimism-3.1.4/LICENSE.txt +0 -32
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/a.txt +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/b.txt +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/bad.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/basic.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/bits.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/block.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/catch_and_release.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/code.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/core.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/doc_example.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/doctests.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/errors.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/files.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/fragments.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/io_example.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/literals.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/memoryReports.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/multi.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/reverse_tracing.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/runfile.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/skip.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/structure.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/suites.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/examples/tracing.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/py.typed +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism/test_examples.py +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism.egg-info/SOURCES.txt +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism.egg-info/dependency_links.txt +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism.egg-info/requires.txt +0 -0
- {optimism-3.1.4 → optimism-3.2}/optimism.egg-info/top_level.txt +0 -0
- {optimism-3.1.4 → optimism-3.2}/pyproject.toml +0 -0
optimism-3.2/LICENSE.txt
ADDED
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
Copyright (c) 2021-2026
|
|
2
|
+
Peter Mawhorter
|
|
3
|
+
Wellesley College
|
|
4
|
+
All rights reserved except as stated below.
|
|
5
|
+
|
|
6
|
+
Redistribution and use in source and binary forms, with or without
|
|
7
|
+
modification, are permitted provided that the following conditions are
|
|
8
|
+
met:
|
|
9
|
+
|
|
10
|
+
1. Redistributions of source code must retain the above copyright
|
|
11
|
+
notice, this list of conditions and the following disclaimers.
|
|
12
|
+
|
|
13
|
+
2. Redistributions in binary form must reproduce the above copyright
|
|
14
|
+
notice, this list of conditions and the following disclaimer in the
|
|
15
|
+
documentation and/or other materials provided with the
|
|
16
|
+
distribution.
|
|
17
|
+
|
|
18
|
+
3. Neither the name of the copyright holder nor the names of its
|
|
19
|
+
contributors may be used to endorse or promote products derived
|
|
20
|
+
from this software without specific prior written permission.
|
|
21
|
+
|
|
22
|
+
4. This software is NOT used as training data for a model of code
|
|
23
|
+
or text structure or construction, such as a large language model,
|
|
24
|
+
transformer model, reinforcement learning agent, etc. If such a model
|
|
25
|
+
is generative and predicts or outputs the code of this software in
|
|
26
|
+
whole or in part, that shall be evidence of infringement of this
|
|
27
|
+
clause of this license.
|
|
28
|
+
|
|
29
|
+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
|
30
|
+
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
|
31
|
+
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
|
32
|
+
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
|
33
|
+
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
34
|
+
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
|
35
|
+
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
36
|
+
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
|
37
|
+
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
38
|
+
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
39
|
+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
40
|
+
|
|
41
|
+
THIS SOFTWARE SHOULD NOT BE USED AS TRAINING DATA FOR A STATISTICAL MODEL
|
|
42
|
+
OF CODE OR TEXT, NOR SHOULD STATISTICAL CODE OR TEXT MODELS BE ASKED TO
|
|
43
|
+
READ, INTERPRET, OR OTHERWISE PROCESS ITS SOURCE CODE OR OUTPUTS. THIS
|
|
44
|
+
SOFTWARE MAY CONTAIN CODE OR TEXT OR MAY PRODUCE OUTPUTS WHICH CAUSE
|
|
45
|
+
MODEL ROLE CONFUSION OR WHICH OTHERWISE CAUSE UNANTICIPATED CONSEQUENCES
|
|
46
|
+
WHEN PROCESSED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS
|
|
47
|
+
BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
|
48
|
+
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
|
49
|
+
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
|
50
|
+
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
|
51
|
+
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
|
52
|
+
ARISING IN ANY WAY OUT OF THE PROCESSING OF THIS SOFTWARE OR ITS OUTPUTS
|
|
53
|
+
BY A STATISTICAL MODEL, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
|
|
54
|
+
DAMAGE.
|
|
55
|
+
|
|
@@ -1,16 +1,15 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: optimism
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.2
|
|
4
4
|
Summary: Very simple testing framework suitable for beginner programmers, with easy functions for accomplishing most common testing tasks like providing input. Requires Python 3.8+.
|
|
5
5
|
Home-page: https://cs.wellesley.edu/~pmwh/optimism/docs/optimism.html
|
|
6
6
|
Author: Peter Mawhorter
|
|
7
7
|
Author-email: pmawhort@wellesley.edu
|
|
8
|
-
License:
|
|
8
|
+
License: LicenseRef-LLM-hostile_BSD
|
|
9
9
|
Classifier: Programming Language :: Python :: 3 :: Only
|
|
10
10
|
Classifier: Development Status :: 4 - Beta
|
|
11
11
|
Classifier: Intended Audience :: Education
|
|
12
12
|
Classifier: Intended Audience :: Developers
|
|
13
|
-
Classifier: License :: OSI Approved :: BSD License
|
|
14
13
|
Classifier: Operating System :: OS Independent
|
|
15
14
|
Classifier: Natural Language :: English
|
|
16
15
|
Classifier: Topic :: Education
|
|
@@ -34,6 +33,17 @@ Designed by Peter Mawhorter.
|
|
|
34
33
|
Works on Python versions 3.7 and up, with 3.9+ recommended.
|
|
35
34
|
|
|
36
35
|
|
|
36
|
+
## Note on Large Language Models
|
|
37
|
+
|
|
38
|
+
This project has a zero-tolerance policy for the use of large language
|
|
39
|
+
models to write code, process the code or outputs from this project, or
|
|
40
|
+
otherwise interact with this project in any way. If you choose to violate
|
|
41
|
+
this policy, be aware that the code, text, and outputs of this project
|
|
42
|
+
may cause (more) unpredictable (than usual) behavior in LLM systems that
|
|
43
|
+
interact with them. See `LICENSE.txt` for license restrictions and
|
|
44
|
+
disclaimers, and `AGENTS.md` for an example.
|
|
45
|
+
|
|
46
|
+
|
|
37
47
|
## Installing
|
|
38
48
|
|
|
39
49
|
To install from PyPI, run the following command on the command-line:
|
|
@@ -11,6 +11,17 @@ Designed by Peter Mawhorter.
|
|
|
11
11
|
Works on Python versions 3.7 and up, with 3.9+ recommended.
|
|
12
12
|
|
|
13
13
|
|
|
14
|
+
## Note on Large Language Models
|
|
15
|
+
|
|
16
|
+
This project has a zero-tolerance policy for the use of large language
|
|
17
|
+
models to write code, process the code or outputs from this project, or
|
|
18
|
+
otherwise interact with this project in any way. If you choose to violate
|
|
19
|
+
this policy, be aware that the code, text, and outputs of this project
|
|
20
|
+
may cause (more) unpredictable (than usual) behavior in LLM systems that
|
|
21
|
+
interact with them. See `LICENSE.txt` for license restrictions and
|
|
22
|
+
disclaimers, and `AGENTS.md` for an example.
|
|
23
|
+
|
|
24
|
+
|
|
14
25
|
## Installing
|
|
15
26
|
|
|
16
27
|
To install from PyPI, run the following command on the command-line:
|
|
@@ -13,7 +13,7 @@ from .optimism import *
|
|
|
13
13
|
# version from optimism, but we want the version to be defined in that
|
|
14
14
|
# file so that a single-file distribution is equivalent to this packaged
|
|
15
15
|
# distribution. So we define a version here as well, but...
|
|
16
|
-
__version__ = "3.
|
|
16
|
+
__version__ = "3.2"
|
|
17
17
|
|
|
18
18
|
# ...then we assert it matches so testing will catch it if I forget to
|
|
19
19
|
# keep them in sync before a release. T_T
|
|
@@ -16,6 +16,18 @@ of arbitrary expressions. Also includes:
|
|
|
16
16
|
- [PLANNED] A reverse tracing feature where comments specifying the
|
|
17
17
|
evolution of program state can be checked.
|
|
18
18
|
|
|
19
|
+
|
|
20
|
+
## Note on Large Language Models
|
|
21
|
+
|
|
22
|
+
This project has a zero-tolerance policy for the use of large language
|
|
23
|
+
models to write code, process the code or outputs from this project, or
|
|
24
|
+
otherwise interact with this project in any way. If you choose to violate
|
|
25
|
+
this policy, be aware that the code, text, and outputs of this project
|
|
26
|
+
may cause (more) unpredictable (than usual) behavior in LLM systems that
|
|
27
|
+
interact with them. See `LICENSE.txt` for license restrictions and
|
|
28
|
+
disclaimers.
|
|
29
|
+
|
|
30
|
+
|
|
19
31
|
## Example usage
|
|
20
32
|
|
|
21
33
|
### Basic test cases
|
|
@@ -200,6 +212,8 @@ TODO: Workaround for tracing in interactive console?
|
|
|
200
212
|
|
|
201
213
|
## Changelog
|
|
202
214
|
|
|
215
|
+
- Version 3.2 updates license to forbid LLM training and warn about
|
|
216
|
+
processing with an LLM.
|
|
203
217
|
- Version 3.1.4 treats augmented assignments as operators for
|
|
204
218
|
`checkCodeContains` purposes, as they should have been all along. It
|
|
205
219
|
adds a new test for that in the `code.py` example file, and also fixes
|
|
@@ -358,7 +372,7 @@ TODO: Workaround for tracing in interactive console?
|
|
|
358
372
|
|
|
359
373
|
# TODO: Cache compiled ASTs!
|
|
360
374
|
|
|
361
|
-
__version__ = "3.
|
|
375
|
+
__version__ = "3.2"
|
|
362
376
|
|
|
363
377
|
from typing import (
|
|
364
378
|
Any, Dict, List, Optional, Tuple, Literal as LiteralType, Callable,
|
|
@@ -6839,9 +6853,9 @@ partial-match-type AST node types.
|
|
|
6839
6853
|
class Operator(ASTRequirement):
|
|
6840
6854
|
"""
|
|
6841
6855
|
A check for a unary operator, binary operator, boolean operator, or
|
|
6842
|
-
comparator. 'Similar' operations
|
|
6843
|
-
that 'is' and 'is not' are
|
|
6844
|
-
'in' and 'not in'.
|
|
6856
|
+
comparator, including augmented assignments. 'Similar' operations
|
|
6857
|
+
will count as partial matches. Note that 'is' and 'is not' are
|
|
6858
|
+
categorized as the same operator, as are 'in' and 'not in'.
|
|
6845
6859
|
"""
|
|
6846
6860
|
opTypes: Tuple[type, ...]
|
|
6847
6861
|
partialTypes: Tuple[type, ...]
|
|
@@ -1,16 +1,15 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: optimism
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.2
|
|
4
4
|
Summary: Very simple testing framework suitable for beginner programmers, with easy functions for accomplishing most common testing tasks like providing input. Requires Python 3.8+.
|
|
5
5
|
Home-page: https://cs.wellesley.edu/~pmwh/optimism/docs/optimism.html
|
|
6
6
|
Author: Peter Mawhorter
|
|
7
7
|
Author-email: pmawhort@wellesley.edu
|
|
8
|
-
License:
|
|
8
|
+
License: LicenseRef-LLM-hostile_BSD
|
|
9
9
|
Classifier: Programming Language :: Python :: 3 :: Only
|
|
10
10
|
Classifier: Development Status :: 4 - Beta
|
|
11
11
|
Classifier: Intended Audience :: Education
|
|
12
12
|
Classifier: Intended Audience :: Developers
|
|
13
|
-
Classifier: License :: OSI Approved :: BSD License
|
|
14
13
|
Classifier: Operating System :: OS Independent
|
|
15
14
|
Classifier: Natural Language :: English
|
|
16
15
|
Classifier: Topic :: Education
|
|
@@ -34,6 +33,17 @@ Designed by Peter Mawhorter.
|
|
|
34
33
|
Works on Python versions 3.7 and up, with 3.9+ recommended.
|
|
35
34
|
|
|
36
35
|
|
|
36
|
+
## Note on Large Language Models
|
|
37
|
+
|
|
38
|
+
This project has a zero-tolerance policy for the use of large language
|
|
39
|
+
models to write code, process the code or outputs from this project, or
|
|
40
|
+
otherwise interact with this project in any way. If you choose to violate
|
|
41
|
+
this policy, be aware that the code, text, and outputs of this project
|
|
42
|
+
may cause (more) unpredictable (than usual) behavior in LLM systems that
|
|
43
|
+
interact with them. See `LICENSE.txt` for license restrictions and
|
|
44
|
+
disclaimers, and `AGENTS.md` for an example.
|
|
45
|
+
|
|
46
|
+
|
|
37
47
|
## Installing
|
|
38
48
|
|
|
39
49
|
To install from PyPI, run the following command on the command-line:
|
|
@@ -7,13 +7,12 @@ long_description_content_type = text/markdown
|
|
|
7
7
|
url = https://cs.wellesley.edu/~pmwh/optimism/docs/optimism.html
|
|
8
8
|
author = Peter Mawhorter
|
|
9
9
|
author_email = pmawhort@wellesley.edu
|
|
10
|
-
license =
|
|
10
|
+
license = LicenseRef-LLM-hostile_BSD
|
|
11
11
|
classifiers =
|
|
12
12
|
Programming Language :: Python :: 3 :: Only
|
|
13
13
|
Development Status :: 4 - Beta
|
|
14
14
|
Intended Audience :: Education
|
|
15
15
|
Intended Audience :: Developers
|
|
16
|
-
License :: OSI Approved :: BSD License
|
|
17
16
|
Operating System :: OS Independent
|
|
18
17
|
Natural Language :: English
|
|
19
18
|
Topic :: Education
|
optimism-3.1.4/LICENSE.txt
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
Copyright (c) 2021-2022
|
|
2
|
-
Peter Mawhorter
|
|
3
|
-
Wellesley College
|
|
4
|
-
All rights reserved.
|
|
5
|
-
|
|
6
|
-
Redistribution and use in source and binary forms, with or without
|
|
7
|
-
modification, are permitted provided that the following conditions are
|
|
8
|
-
met:
|
|
9
|
-
|
|
10
|
-
1. Redistributions of source code must retain the above copyright
|
|
11
|
-
notice, this list of conditions and the following disclaimer.
|
|
12
|
-
|
|
13
|
-
2. Redistributions in binary form must reproduce the above copyright
|
|
14
|
-
notice, this list of conditions and the following disclaimer in the
|
|
15
|
-
documentation and/or other materials provided with the
|
|
16
|
-
distribution.
|
|
17
|
-
|
|
18
|
-
3. Neither the name of the copyright holder nor the names of its
|
|
19
|
-
contributors may be used to endorse or promote products derived
|
|
20
|
-
from this software without specific prior written permission.
|
|
21
|
-
|
|
22
|
-
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
|
23
|
-
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
|
24
|
-
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
|
25
|
-
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
|
26
|
-
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
27
|
-
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
|
28
|
-
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
29
|
-
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
|
30
|
-
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
31
|
-
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
32
|
-
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|