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

Doc update main #142

Merged
merged 3 commits into from
Jan 8, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/doc-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
cd optimum
version=`echo "$(grep '^__version__ =' tpu/version.py | cut -d '=' -f 2- | xargs)"`

if [[ $version == *a* ]]
if [[ $version == *.dev0 ]]
then
echo "VERSION=main" >> $GITHUB_ENV
else
Expand Down
2 changes: 1 addition & 1 deletion optimum/tpu/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@
from packaging.version import parse


__version__ = "0.2.3"
__version__ = "0.2.3.dev0"
VERSION = parse(__version__)
2 changes: 1 addition & 1 deletion text-generation-inference/docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ RUN apt-get update -y \
RUN pip3 --no-cache-dir install --upgrade pip

ARG ENABLE_GOOGLE_FEATURE
ARG VERSION='0.2.3'
ARG VERSION='0.2.3.dev0'
RUN test -n ${VERSION:?}

FROM base AS optimum-tpu-installer
Expand Down
10 changes: 5 additions & 5 deletions text-generation-inference/integration-tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def validate_ci_tpu_env_format(env_string: str) -> bool:
"""
Validate that CI TPU environment string follows '--env Argument' pattern.
Returns True if valid, False otherwise.
"""
"""
parts = env_string.split()
return len(parts) % 2 == 0 and all(
parts[i] == "--env" and not parts[i + 1].startswith("--env")
Expand All @@ -49,15 +49,15 @@ def process_ci_tpu_env_vars(env_string: str) -> dict:
env_vars = {}
# Extract variables from string
tpu_vars = [x.strip() for x in env_string.split('--env') if x.strip()]

# Process each variable
for var in tpu_vars:
env_value = os.environ.get(var, "")
env_vars[var] = env_value
# Log if environment variable is not set
if not env_value:
logger.warning(f"TPU environment variable {var} is not set")

return env_vars


Expand Down Expand Up @@ -212,12 +212,12 @@ def docker_launcher(

# Add TPU environment variables when running in CI
if TPU_ENV:
logger.info(f"TPU_ENV is set, adding specific TPU environment variables for the CI")
logger.info("TPU_ENV is set, adding specific TPU environment variables for the CI")
logger.debug(f"TPU_ENV: {TPU_ENV}")
# Validate TPU environment format
if not validate_ci_tpu_env_format(TPU_ENV):
raise ValueError("Invalid TPU environment format", TPU_ENV)

# Process TPU environment variables
tpu_env_vars = process_ci_tpu_env_vars(TPU_ENV)
env.update(tpu_env_vars)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from pkg_resources import parse_version


__version__ = "0.2.3"
__version__ = "0.2.3.dev0"
VERSION = parse_version(__version__)
Loading