pierre-storage 1.0.0__py3-none-any.whl → 1.0.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
pierre_storage/client.py CHANGED
@@ -1,6 +1,7 @@
1
1
  """Main client for Pierre Git Storage SDK."""
2
2
 
3
3
  import uuid
4
+ from datetime import datetime, timezone
4
5
  from typing import Any, Dict, Optional, cast
5
6
  from urllib.parse import urlencode
6
7
 
@@ -216,6 +217,7 @@ class GitStorage:
216
217
  name,
217
218
  api_version,
218
219
  self._generate_jwt,
220
+ created_at=datetime.now(timezone.utc).isoformat(),
219
221
  )
220
222
 
221
223
  async def list_repos(
@@ -317,6 +319,7 @@ class GitStorage:
317
319
 
318
320
  body = response.json()
319
321
  default_branch = body.get("default_branch", "main")
322
+ created_at = body.get("created_at", "")
320
323
 
321
324
  # These are guaranteed to be set in __init__
322
325
  api_base_url: str = self.options["api_base_url"] # type: ignore[assignment]
@@ -332,6 +335,7 @@ class GitStorage:
332
335
  name,
333
336
  api_version,
334
337
  self._generate_jwt,
338
+ created_at=created_at,
335
339
  )
336
340
 
337
341
  async def delete_repo(
pierre_storage/repo.py CHANGED
@@ -112,6 +112,7 @@ class RepoImpl:
112
112
  name: str,
113
113
  api_version: int,
114
114
  generate_jwt: Callable[[str, Optional[Dict[str, Any]]], str],
115
+ created_at: str = "",
115
116
  ) -> None:
116
117
  """Initialize repository.
117
118
 
@@ -123,9 +124,11 @@ class RepoImpl:
123
124
  name: Customer name
124
125
  api_version: API version
125
126
  generate_jwt: Function to generate JWT tokens
127
+ created_at: Repository creation timestamp
126
128
  """
127
129
  self._id = repo_id
128
130
  self._default_branch = default_branch
131
+ self._created_at = created_at
129
132
  self.api_base_url = api_base_url.rstrip("/")
130
133
  self.storage_base_url = storage_base_url
131
134
  self.name = name
@@ -142,6 +145,11 @@ class RepoImpl:
142
145
  """Get default branch name."""
143
146
  return self._default_branch
144
147
 
148
+ @property
149
+ def created_at(self) -> str:
150
+ """Get repository creation timestamp."""
151
+ return self._created_at
152
+
145
153
  async def get_remote_url(
146
154
  self,
147
155
  *,
pierre_storage/types.py CHANGED
@@ -409,6 +409,11 @@ class Repo(Protocol):
409
409
  """Get the default branch name."""
410
410
  ...
411
411
 
412
+ @property
413
+ def created_at(self) -> str:
414
+ """Get the repository creation timestamp."""
415
+ ...
416
+
412
417
  async def get_remote_url(
413
418
  self,
414
419
  *,
pierre_storage/version.py CHANGED
@@ -1,7 +1,7 @@
1
1
  """Version information for Pierre Storage SDK."""
2
2
 
3
3
  PACKAGE_NAME = "code-storage-py-sdk"
4
- PACKAGE_VERSION = "0.12.1"
4
+ PACKAGE_VERSION = "0.12.2"
5
5
 
6
6
 
7
7
  def get_user_agent() -> str:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pierre-storage
3
- Version: 1.0.0
3
+ Version: 1.0.1
4
4
  Summary: Pierre Git Storage SDK for Python
5
5
  Author-email: Pierre <support@pierre.io>
6
6
  License-Expression: MIT
@@ -0,0 +1,15 @@
1
+ pierre_storage/__init__.py,sha256=8t6r3VUY4MSZhSuBXaoxzuxd4FLRAbVLWFxXiC_fcQY,1905
2
+ pierre_storage/auth.py,sha256=aT0KNaUKa9fXERtQvJb8C6zL5IxrfA1KLxMBcprAq5A,2074
3
+ pierre_storage/client.py,sha256=FzX42isIjQO9SzONHkjTVpzaA6N8i5kcjM6c84aw_5w,15098
4
+ pierre_storage/commit.py,sha256=ks5hKScHHricJ3sx8DyLSAASM72CPmVv-tbtUgHbUF4,16766
5
+ pierre_storage/errors.py,sha256=-vuA2BUGwyDlErFtdh2boLdk0fDFDFYBEIohJk4AsIs,2184
6
+ pierre_storage/py.typed,sha256=8PjyZ1aVoQpRVvt71muvuq5qE-jTFZkK-GLHkhdebmc,26
7
+ pierre_storage/repo.py,sha256=5VesZSzoCbhOMN7C7C43mgL-Z5JkVbo4FaNBoZ2Uw8Y,46723
8
+ pierre_storage/types.py,sha256=yDdHX-QTWbUiwWpYWytMEchfk8WT33kJca6hVfo3uPA,15377
9
+ pierre_storage/version.py,sha256=02J7KBSNBg8Ecf2G68x6KSPBF5CdMnTCJthybrQ7etc,316
10
+ pierre_storage/webhook.py,sha256=hyjSmTlU_x35m612erXDqNXbLUh5i5As5GRw7kxylFc,7425
11
+ pierre_storage-1.0.1.dist-info/licenses/LICENSE,sha256=E9kr4Y1c6sUm8zzJa2kCoU0Wjz4dSxa-c48Ppw2n_pg,10899
12
+ pierre_storage-1.0.1.dist-info/METADATA,sha256=jKn9xrdwsRvFNcOW5dgLayGzLZKj7Nb3GZX1-kXHoHU,23935
13
+ pierre_storage-1.0.1.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
14
+ pierre_storage-1.0.1.dist-info/top_level.txt,sha256=RzcYFaSdETlcwX-45G9Q39xUgXWZLJEWcOiK0p6ZepY,15
15
+ pierre_storage-1.0.1.dist-info/RECORD,,
@@ -1,15 +0,0 @@
1
- pierre_storage/__init__.py,sha256=8t6r3VUY4MSZhSuBXaoxzuxd4FLRAbVLWFxXiC_fcQY,1905
2
- pierre_storage/auth.py,sha256=aT0KNaUKa9fXERtQvJb8C6zL5IxrfA1KLxMBcprAq5A,2074
3
- pierre_storage/client.py,sha256=FVUB-r1Oxr112nFAXPEo_rpkGVFdxYvu_NpBXh8aclI,14908
4
- pierre_storage/commit.py,sha256=ks5hKScHHricJ3sx8DyLSAASM72CPmVv-tbtUgHbUF4,16766
5
- pierre_storage/errors.py,sha256=-vuA2BUGwyDlErFtdh2boLdk0fDFDFYBEIohJk4AsIs,2184
6
- pierre_storage/py.typed,sha256=8PjyZ1aVoQpRVvt71muvuq5qE-jTFZkK-GLHkhdebmc,26
7
- pierre_storage/repo.py,sha256=IsCYYDvZVbQCnydTl_XDODVDrsgABfDQLGhXKx5m9PQ,46472
8
- pierre_storage/types.py,sha256=peRfmcYi0Hls17yC3j2A9hYspaPh0iY1HEQdxz9Ic7g,15264
9
- pierre_storage/version.py,sha256=L7upS30suP-fz3rFGhpCsKcU2OKkpynrjqNIfdNDhFc,316
10
- pierre_storage/webhook.py,sha256=hyjSmTlU_x35m612erXDqNXbLUh5i5As5GRw7kxylFc,7425
11
- pierre_storage-1.0.0.dist-info/licenses/LICENSE,sha256=E9kr4Y1c6sUm8zzJa2kCoU0Wjz4dSxa-c48Ppw2n_pg,10899
12
- pierre_storage-1.0.0.dist-info/METADATA,sha256=w-COyqU_PBGiTUB3lPpsMqjBQVDOP7Fjucf1ge9Rwvs,23935
13
- pierre_storage-1.0.0.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
14
- pierre_storage-1.0.0.dist-info/top_level.txt,sha256=RzcYFaSdETlcwX-45G9Q39xUgXWZLJEWcOiK0p6ZepY,15
15
- pierre_storage-1.0.0.dist-info/RECORD,,