Skip to content

Commit

Permalink
Ensure export URI ends with a slash or filenaming will cause issues i…
Browse files Browse the repository at this point in the history
…n s3
  • Loading branch information
Wesley van Lee committed Nov 1, 2024
1 parent ed13afd commit aa7c701
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion scrapy_webarchive/extensions.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,8 @@ def _retrieve_store_uri_and_wacz_fname(self) -> Tuple[str, Union[str, None]]:
if os.path.isdir(export_uri):
return export_uri, None
else:
return os.path.split(export_uri)
export_uri, wacz_fname = os.path.split(export_uri)
return f"{export_uri}/", wacz_fname

def _get_store(self, store_uri: str) -> FilesStoreProtocol:
store_cls = self.STORE_SCHEMES[get_scheme_from_uri(store_uri)]
Expand Down

0 comments on commit aa7c701

Please sign in to comment.