@@ -90,7 +90,12 @@ def from_service_account_file(cls, filename, *args, **kwargs):
90
90
91
91
@classmethod
92
92
def annotated_dataset_path (cls , project , dataset , annotated_dataset ):
93
- """Return a fully-qualified annotated_dataset string."""
93
+ """DEPRECATED. Return a fully-qualified annotated_dataset string."""
94
+ warnings .warn (
95
+ "Resource name helper functions are deprecated." ,
96
+ PendingDeprecationWarning ,
97
+ stacklevel = 1 ,
98
+ )
94
99
return google .api_core .path_template .expand (
95
100
"projects/{project}/datasets/{dataset}/annotatedDatasets/{annotated_dataset}" ,
96
101
project = project ,
@@ -100,7 +105,12 @@ def annotated_dataset_path(cls, project, dataset, annotated_dataset):
100
105
101
106
@classmethod
102
107
def annotation_spec_set_path (cls , project , annotation_spec_set ):
103
- """Return a fully-qualified annotation_spec_set string."""
108
+ """DEPRECATED. Return a fully-qualified annotation_spec_set string."""
109
+ warnings .warn (
110
+ "Resource name helper functions are deprecated." ,
111
+ PendingDeprecationWarning ,
112
+ stacklevel = 1 ,
113
+ )
104
114
return google .api_core .path_template .expand (
105
115
"projects/{project}/annotationSpecSets/{annotation_spec_set}" ,
106
116
project = project ,
@@ -109,7 +119,12 @@ def annotation_spec_set_path(cls, project, annotation_spec_set):
109
119
110
120
@classmethod
111
121
def data_item_path (cls , project , dataset , data_item ):
112
- """Return a fully-qualified data_item string."""
122
+ """DEPRECATED. Return a fully-qualified data_item string."""
123
+ warnings .warn (
124
+ "Resource name helper functions are deprecated." ,
125
+ PendingDeprecationWarning ,
126
+ stacklevel = 1 ,
127
+ )
113
128
return google .api_core .path_template .expand (
114
129
"projects/{project}/datasets/{dataset}/dataItems/{data_item}" ,
115
130
project = project ,
@@ -119,14 +134,24 @@ def data_item_path(cls, project, dataset, data_item):
119
134
120
135
@classmethod
121
136
def dataset_path (cls , project , dataset ):
122
- """Return a fully-qualified dataset string."""
137
+ """DEPRECATED. Return a fully-qualified dataset string."""
138
+ warnings .warn (
139
+ "Resource name helper functions are deprecated." ,
140
+ PendingDeprecationWarning ,
141
+ stacklevel = 1 ,
142
+ )
123
143
return google .api_core .path_template .expand (
124
144
"projects/{project}/datasets/{dataset}" , project = project , dataset = dataset
125
145
)
126
146
127
147
@classmethod
128
148
def evaluation_path (cls , project , dataset , evaluation ):
129
- """Return a fully-qualified evaluation string."""
149
+ """DEPRECATED. Return a fully-qualified evaluation string."""
150
+ warnings .warn (
151
+ "Resource name helper functions are deprecated." ,
152
+ PendingDeprecationWarning ,
153
+ stacklevel = 1 ,
154
+ )
130
155
return google .api_core .path_template .expand (
131
156
"projects/{project}/datasets/{dataset}/evaluations/{evaluation}" ,
132
157
project = project ,
@@ -136,7 +161,12 @@ def evaluation_path(cls, project, dataset, evaluation):
136
161
137
162
@classmethod
138
163
def evaluation_job_path (cls , project , evaluation_job ):
139
- """Return a fully-qualified evaluation_job string."""
164
+ """DEPRECATED. Return a fully-qualified evaluation_job string."""
165
+ warnings .warn (
166
+ "Resource name helper functions are deprecated." ,
167
+ PendingDeprecationWarning ,
168
+ stacklevel = 1 ,
169
+ )
140
170
return google .api_core .path_template .expand (
141
171
"projects/{project}/evaluationJobs/{evaluation_job}" ,
142
172
project = project ,
@@ -145,7 +175,12 @@ def evaluation_job_path(cls, project, evaluation_job):
145
175
146
176
@classmethod
147
177
def example_path (cls , project , dataset , annotated_dataset , example ):
148
- """Return a fully-qualified example string."""
178
+ """DEPRECATED. Return a fully-qualified example string."""
179
+ warnings .warn (
180
+ "Resource name helper functions are deprecated." ,
181
+ PendingDeprecationWarning ,
182
+ stacklevel = 1 ,
183
+ )
149
184
return google .api_core .path_template .expand (
150
185
"projects/{project}/datasets/{dataset}/annotatedDatasets/{annotated_dataset}/examples/{example}" ,
151
186
project = project ,
@@ -156,7 +191,12 @@ def example_path(cls, project, dataset, annotated_dataset, example):
156
191
157
192
@classmethod
158
193
def instruction_path (cls , project , instruction ):
159
- """Return a fully-qualified instruction string."""
194
+ """DEPRECATED. Return a fully-qualified instruction string."""
195
+ warnings .warn (
196
+ "Resource name helper functions are deprecated." ,
197
+ PendingDeprecationWarning ,
198
+ stacklevel = 1 ,
199
+ )
160
200
return google .api_core .path_template .expand (
161
201
"projects/{project}/instructions/{instruction}" ,
162
202
project = project ,
@@ -165,7 +205,12 @@ def instruction_path(cls, project, instruction):
165
205
166
206
@classmethod
167
207
def project_path (cls , project ):
168
- """Return a fully-qualified project string."""
208
+ """DEPRECATED. Return a fully-qualified project string."""
209
+ warnings .warn (
210
+ "Resource name helper functions are deprecated." ,
211
+ PendingDeprecationWarning ,
212
+ stacklevel = 1 ,
213
+ )
169
214
return google .api_core .path_template .expand (
170
215
"projects/{project}" , project = project
171
216
)
0 commit comments