Skip to content

Commit af3eb0b

Browse files
TCatshoeknejch
andcommitted
docs(api-docs): make iterator download documentation more generic
Co-authored-by: Nejc Habjan <hab.nejc@gmail.com>
1 parent d7ee6f8 commit af3eb0b

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

docs/gl_objects/pipelines_and_jobs.rst

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -274,12 +274,13 @@ You can also directly stream the output into a file, and unzip it afterwards::
274274
subprocess.run(["unzip", "-bo", zipfn])
275275
os.unlink(zipfn)
276276

277-
It is also possible to use the underlying iterator directly::
277+
Or, you can also use the underlying response iterator directly::
278278

279279
artifact_bytes_iterator = build_or_job.artifacts(streamed=True, action='iterator')
280280

281-
This can be used with FastAPI/Starlette StreamingResponse to forward a download from gitlab without having to download
282-
the entire file server side first::
281+
This can be used with frameworks that expect an iterator (such as FastAPI/Starlette's
282+
``StreamingResponse``) to forward a download from GitLab without having to download
283+
the entire content server-side first::
283284

284285
@app.get("/download_artifact")
285286
def download_artifact():

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy