Skip to content

Commit

Permalink
Merge pull request #159 from nabenabe0928/add-future-annotations
Browse files Browse the repository at this point in the history
Add future annotations as some modules fail with Python 3.9
  • Loading branch information
not522 authored Oct 11, 2024
2 parents d6e89b6 + 1c8e469 commit 8ff7188
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,6 @@ Otherwise, please check the following TODO list:
- [ ] Replace `<COPYRIGHT HOLDER>` in `LICENSE` of your package with your name
- [ ] Fill out `README.md` in your package
- [ ] Add import statements of your function or class names to be used in `__init__.py`
- [ ] (Optional) Add `from __future__ import annotations` at the head of any Python files that include typing to support older Python versions
- [ ] Apply the formatter based on the tips in [`README.md`](https://github.com/optuna/optunahub-registry/tree/main)
- [ ] Check whether your module works as intended based on the tips in [`README.md`](https://github.com/optuna/optunahub-registry/tree/main)
2 changes: 2 additions & 0 deletions package/samplers/nelder_mead/generate_initial_simplex.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.

from __future__ import annotations

import numpy as np


Expand Down
2 changes: 2 additions & 0 deletions package/samplers/plmbo/plmbo.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
from __future__ import annotations

from typing import Any

import GPy
Expand Down

0 comments on commit 8ff7188

Please sign in to comment.