Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed #33866 -- Added pathlib.Path support to GDALRaster constructor. #15879

Merged
merged 1 commit into from
Jul 25, 2022

Conversation

claudep
Copy link
Member

@claudep claudep commented Jul 25, 2022

No description provided.

@@ -25,6 +26,11 @@ def setUp(self):
)
self.rs = GDALRaster(self.rs_path)

def test_gdalraster_input_as_path(self):
rs_path = Path(__file__).parent.joinpath("data", "rasters", "raster.tif")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
rs_path = Path(__file__).parent.joinpath("data", "rasters", "raster.tif")
rs_path = Path(__file__).parent / "data" / "rasters" / "raster.tif"

@@ -25,6 +26,11 @@ def setUp(self):
)
self.rs = GDALRaster(self.rs_path)

def test_gdalraster_input_as_path(self):
rs_path = Path(__file__).parent.joinpath("data", "rasters", "raster.tif")
GDALRaster(rs_path)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
GDALRaster(rs_path)
self.rs = GDALRaster(rs_path)

@claudep
Copy link
Member Author

claudep commented Jul 25, 2022

Sorry @felixxm, I pushed without my latest changes :-(

Copy link
Member

@felixxm felixxm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@claudep Thanks 👍 I pushed docs changes.

@felixxm felixxm changed the title Fixed #33866 -- Added Path support to GDALRaster constructor. Fixed #33866 -- Added pathlib.Path support to GDALRaster constructor. Jul 25, 2022
@claudep
Copy link
Member Author

claudep commented Jul 25, 2022

Nice!

@felixxm felixxm merged commit 2d23a07 into django:main Jul 25, 2022
@felixxm felixxm temporarily deployed to schedules July 26, 2022 03:33 Inactive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants