Skip to content

Commit 42624c3

Browse files
committed
update setup versioning format
1 parent 2855393 commit 42624c3

1 file changed

Lines changed: 7 additions & 24 deletions

File tree

  • libraries/microsoft-agents-a365-observability-extensions-agentframework
Lines changed: 7 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,13 @@
1-
# Copyright (c) Microsoft. All rights reserved.
2-
3-
import os
4-
from datetime import datetime
5-
from zoneinfo import ZoneInfo
1+
# Copyright (c) Microsoft Corporation.
2+
# Licensed under the MIT License.
63

4+
from os import environ
75
from setuptools import setup
86

9-
10-
def build_version():
11-
"""
12-
Example: 2025.10.3+preview.65532 (PEP 440 compliant; avoids hyphens)
13-
Uses UTC.
14-
"""
15-
16-
if defined_version := os.getenv("A365_SDK_VERSION"):
17-
return defined_version # For CI/CD to set a specific version.
18-
19-
today = datetime.now(ZoneInfo("UTC"))
20-
21-
return (
22-
f"{today.year}.{today.month}.{today.day}+preview.{today.hour}{today.minute}{today.second}"
23-
)
24-
25-
26-
VERSION = build_version()
7+
# Get version from environment variable set by CI/CD
8+
# This will be set by setuptools-git-versioning in the CI pipeline
9+
package_version = environ.get("AGENT365_PYTHON_SDK_PACKAGE_VERSION", "0.0.0")
2710

2811
setup(
29-
version=VERSION,
12+
version=package_version,
3013
)

0 commit comments

Comments
 (0)