Skip to content

Commit

Permalink
Bump expected python version to 3.11
Browse files Browse the repository at this point in the history
  • Loading branch information
Avasam committed Jul 14, 2024
1 parent 269c5a6 commit 29d114b
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 5 deletions.
3 changes: 1 addition & 2 deletions Dolphin scripts/Entrance Randomizer/lib/graph_creation.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,7 @@ def create_graphml(
seed_string: SeedType,
starting_area: int,
):
# In Python 3.9 this can be simplified to |
all_transitions = {**transitions_map, **{item: item for item in temp_disabled_exits}}
all_transitions = dict(transitions_map) | {item: item for item in temp_disabled_exits}

graphml_text = (
'<?xml version="1.0" encoding="UTF-8"?>'
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Update expected Python version for the randomizer to `3.11`. This means the Dolphin version has to be at least <https://github.com/Felk/dolphin/releases/tag/scripting-preview3>
15 changes: 12 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,14 @@
# https://github.com/BesLogic/shared-configs/blob/main/ruff.toml
# Modifications to this file that are not project-specific should also be done upstream.
# These configs were last updated for ruff==0.3.7

# https://docs.astral.sh/ruff/configuration/
[tool.ruff]
line-length = 100
preview = true
target-version = "py38" # Change this to the oldest supported version by your application
# Change this to the oldest supported version by your application
# (same as https://github.com/Felk/dolphin/releases/tag/scripting-preview3 )
target-version = "py311"
# Exclude auto-generated files
# exclude = [""]

Expand Down Expand Up @@ -78,6 +81,12 @@ ignore = [
# False-positives
"TCH004", # https://github.com/astral-sh/ruff/issues/3821

###
# Conflict with formatter (you can remove this section if you don't use Ruff as a formatter)
###
# "COM812", # missing-trailing-comma
# "ISC001", # single-line-implicit-string-concatenation

###
# Specific to this project
###
Expand Down Expand Up @@ -171,9 +180,9 @@ per_file_ignores = ["*.pyi: E302"]

# https://github.com/microsoft/pyright/blob/main/docs/configuration.md#sample-pyprojecttoml-file
[tool.pyright]
# Minimal python version supported
extraPaths = ["Dolphin scripts/typings"]
pythonVersion = "3.8"
# Minimal python version supported (same as https://github.com/Felk/dolphin/releases/tag/scripting-preview3 )
pythonVersion = "3.11"
typeCheckingMode = "strict"
# Extra strict
reportCallInDefaultInitializer = "error"
Expand Down

0 comments on commit 29d114b

Please sign in to comment.