Skip to content

Commit 6088ebb

Browse files
authored
fix auto release workflow (#4229)
* fix auto deploy * auto deploy * remove extra line
1 parent 706971b commit 6088ebb

File tree

3 files changed

+3
-9
lines changed

3 files changed

+3
-9
lines changed

paddlenlp/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright (c) 2020 PaddlePaddle Authors. All Rights Reserved.
1+
# Copyright (c) 2022 PaddlePaddle Authors. All Rights Reserved.
22
#
33
# Licensed under the Apache License, Version 2.0 (the "License");
44
# you may not use this file except in compliance with the License.

scripts/should_deploy.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -69,12 +69,8 @@ def read_version_of_local_package(version_file_path: str) -> str:
6969
}
7070
remote_version = read_version_of_remote_package(args.name)
7171

72-
# tmp fix
7372
if args.name == "paddlenlp":
74-
sys.path.append(".")
75-
from paddlenlp import __version__
76-
77-
local_version = __version__
73+
local_version = str(subprocess.check_output(["python", "setup.py", "--version"], text=True))
7874
elif args.name in version_file_map:
7975
PROJECT_ROOT = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
8076
local_version_file = os.path.join(PROJECT_ROOT, version_file_map[args.name])

setup.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@
1616

1717
import setuptools
1818

19-
from paddlenlp import __version__
20-
2119

2220
def read_requirements_file(filepath):
2321
with open(filepath) as fin:
@@ -61,7 +59,7 @@ def get_package_data_files(package, data, package_dir=None):
6159

6260
setuptools.setup(
6361
name="paddlenlp",
64-
version=__version__,
62+
version="2.4.7",
6563
author="PaddleNLP Team",
6664
author_email="[email protected]",
6765
description="Easy-to-use and powerful NLP library with Awesome model zoo, supporting wide-range of NLP tasks from research to industrial applications, including Neural Search, Question Answering, Information Extraction and Sentiment Analysis end-to-end system.",

0 commit comments

Comments
 (0)