diff --git a/docs/source/getting_started/example_scenes.rst b/docs/source/getting_started/example_scenes.rst index e6cdee06e8..486cc92eab 100644 --- a/docs/source/getting_started/example_scenes.rst +++ b/docs/source/getting_started/example_scenes.rst @@ -426,7 +426,7 @@ CoordinateSystemExample # you can call call axes.coords_to_point, abbreviated to # axes.c2p, to associate a set of coordinates with a point, # like so: - dot = Dot(color=RED) + dot = Dot(fill_color=RED) dot.move_to(axes.c2p(0, 0)) self.play(FadeIn(dot, scale=0.5)) self.play(dot.animate.move_to(axes.c2p(3, 2))) @@ -537,7 +537,7 @@ GraphExample # You can use axes.input_to_graph_point, abbreviated # to axes.i2gp, to find a particular point on a graph - dot = Dot(color=RED) + dot = Dot(fill_color=RED) dot.move_to(axes.i2gp(2, parabola)) self.play(FadeIn(dot, scale=0.5)) diff --git a/example_scenes.py b/example_scenes.py index b78bd6f4e8..9d6a6cee84 100644 --- a/example_scenes.py +++ b/example_scenes.py @@ -375,7 +375,7 @@ def construct(self): # you can call call axes.coords_to_point, abbreviated to # axes.c2p, to associate a set of coordinates with a point, # like so: - dot = Dot(color=RED) + dot = Dot(fill_color=RED) dot.move_to(axes.c2p(0, 0)) self.play(FadeIn(dot, scale=0.5)) self.play(dot.animate.move_to(axes.c2p(3, 2))) @@ -480,7 +480,7 @@ def construct(self): # You can use axes.input_to_graph_point, abbreviated # to axes.i2gp, to find a particular point on a graph - dot = Dot(color=RED) + dot = Dot(fill_color=RED) dot.move_to(axes.i2gp(2, parabola)) self.play(FadeIn(dot, scale=0.5)) diff --git a/manimlib/utils/file_ops.py b/manimlib/utils/file_ops.py index 86e9a009a8..f9a27421bb 100644 --- a/manimlib/utils/file_ops.py +++ b/manimlib/utils/file_ops.py @@ -29,13 +29,15 @@ def find_file( extensions: Iterable[str] | None = None ) -> Path: # Check if this is a file online first, and if so, download - # it to a temporary directory + # it to the configured downloads directory if validators.url(file_name): suffix = Path(file_name).suffix file_hash = hash_string(file_name) folder = manimlib.utils.directories.get_downloads_dir() - path = Path(folder, file_hash).with_suffix(suffix) + + # ensure that the target folder exists before downloading + guarantee_existence(folder) urllib.request.urlretrieve(file_name, path) return path