Repository: ResonantGeoData/ResonantGeoData

Issue:
CD GitHub action for publishing rgdc on PyPI
We need CD for the `rgdc` package on tags


Discussion:

Resolving patch:
diff --git a/rgdc/rgdc/rgdc.py b/rgdc/rgdc/rgdc.py
--- a/rgdc/rgdc/rgdc.py
+++ b/rgdc/rgdc/rgdc.py
@@ -52,72 +52,72 @@ def __init__(
 
         self.session = RgdcSession(base_url=api_url, auth_header=auth_header)
 
-    def list_image_entry_tiles(self, image_entry_id: Union[str, int]) -> Dict:
-        """List geodata imagery image_entry tiles."""
-        r = self.session.get(f'geoprocess/imagery/{image_entry_id}/tiles')
+    def list_image_tiles(self, image_id: Union[str, int]) -> Dict:
+        """List geodata imagery tiles."""
+        r = self.session.get(f'geoprocess/imagery/{image_id}/tiles')
         return r.json()
 
-    def download_image_entry_file(
-        self, image_entry_id: Union[str, int], chunk_size: int = 1024 * 1024
+    def download_image_file(
+        self, image_id: Union[str, int], chunk_size: int = 1024 * 1024
     ) -> Iterator[bytes]:
         """
         Download the associated ImageFile data for this ImageEntry directly from S3.
 
         Args:
-            image_entry_id: The ID of the ImageEntry to download.
+            image_id: The ID of the ImageEntry to download.
             chunk_size: The size (in bytes) of each item in the returned iterator (defaults to 1MB).
 
         Returns:
             An iterator of byte chunks.
         """
-        r = self.session.get(f'geodata/imagery/{image_entry_id}/data', stream=True)
+        r = self.session.get(f'geodata/imagery/{image_id}/data', stream=True)
         return r.iter_content(chunk_size=chunk_size)
 
-    def download_image_entry_thumbnail(
+    def download_image_thumbnail(
         self,
-        image_entry_id: Union[str, int],
+        image_id: Union[str, int],
     ) -> bytes:
         """
         Download the generated thumbnail for this ImageEntry.
 
         Args:
-            image_entry_id: The ID of the ImageEntry to download.
+            image_id: The ID of the ImageEntry to download.
 
         Returns:
             Thumbnail bytes.
         """
-        r = self.session.get(f'geoprocess/imagery/{image_entry_id}/thumbnail')
+        r = self.session.get(f'geoprocess/imagery/{image_id}/thumbnail')
         return r.content
 
-    def download_raster_entry_thumbnail(
+    def download_raster_thumbnail(
         self,
-        raster_meta_entry_id: Union[str, int, dict],
+        raster_meta_id: Union[str, int, dict],
         band: int = 0,
     ) -> bytes:
         """
         Download the generated thumbnail for this ImageEntry.
 
         Args:
-            raster_meta_entry_id: The id of the RasterMetaEntry, which is a child to the desired raster entry, or search result.
+            raster_meta_id: The id of the RasterMetaEntry, which is a child to the desired raster entry, or search result.
             band: The index of the image in the raster's image set to produce thumbnail from.
 
         Returns:
             Thumbnail bytes.
         """
-        if isinstance(raster_meta_entry_id, dict):
-            raster_meta_entry_id = spatial_subentry_id(raster_meta_entry_id)
+        if isinstance(raster_meta_id, dict):
+            raster_meta_id = spatial_subentry_id(raster_meta_id)
 
-        r = self.session.get(f'geodata/imagery/raster/{raster_meta_entry_id}')
+        r = self.session.get(f'geodata/imagery/raster/{raster_meta_id}')
         parent_raster = r.json().get('parent_raster', {})
         images = parent_raster.get('image_set', {}).get('images', [])
         try:
-            return self.download_image_entry_thumbnail(images[band]['id'])
+            return self.download_image_thumbnail(images[band]['id'])
         except IndexError:
             raise IndexError(f'Band index ({band}) out of range.')
 
-    def download_raster_entry(
+    def download_raster(
         self,
-        raster_meta_entry_id: Union[str, int, dict],
+        raster_meta_id: Union[str, int, dict],
         pathname: Optional[str] = None,
         nest_with_name: bool = False,
         keep_existing: bool = True,
@@ -126,7 +126,7 @@ def download_raster_entry(
         Download the image set associated with a raster entry to disk.
 
         Args:
-            raster_meta_entry_id: The id of the RasterMetaEntry, which is a child to the desired raster entry, or search result.
+            raster_meta_id: The id of the RasterMetaEntry, which is a child to the desired raster entry, or search result.
             pathname: The directory to download the image set to. If not supplied, a temporary directory will be used.
             nest_with_name: If True, nests the download within an additional directory, using the raster entry name.
             keep_existing: If False, replace files existing on disk. Only valid if `pathname` is given.
@@ -134,10 +134,10 @@ def download_raster_entry(
         Returns:
             A dictionary of the paths to all files downloaded under the directory.
         """
-        if isinstance(raster_meta_entry_id, dict):
-            raster_meta_entry_id = spatial_subentry_id(raster_meta_entry_id)
+        if isinstance(raster_meta_id, dict):
+            raster_meta_id = spatial_subentry_id(raster_meta_id)
 
-        r = self.session.get(f'geodata/imagery/raster/{raster_meta_entry_id}')
+        r = self.session.get(f'geodata/imagery/raster/{raster_meta_id}')
         parent_raster = r.json().get('parent_raster', {})
 
         # Create dirs after request to avoid empty dirs if failed


Test patch: