# Gradio. Could not find files for the given pattern(s)

**URL:** </static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgradio-could-not-find-files-for-the-given-pattern-s%2F112702%3E%5C
**Category:** Beginners\
**Created:** [October 18, 2024, 3:12pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgradio-could-not-find-files-for-the-given-pattern-s%2F112702 "2024-10-18T15:12:29Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Billy5000](https://avatars.discourse-cdn.com/v4/letter/b/77aa72/32.png) [@Billy5000](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FBilly5000)%5C
**Post date:** [October 18, 2024, 3:12pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgradio-could-not-find-files-for-the-given-pattern-s%2F112702%2F1 "2024-10-18T15:12:29Z")

</div>

Hi. Just installed Gradio, Wrote 3 or 4 test scripts and each one gives the error in the topic subject. All the apps I tested worked but don’t understand why im getting this message. I updated gradio with pip and i’ve tested both normal run and hot reload. Doesn’t matter if i start from .bat, cmd, or .py, the error still appears. Also, without creating a new topic, at times the app does not update and appears to use a cached previous version despite clearing the browser, changing the browser, rename the py, and even restarting the Win 10 PC…which I know doesn’t make any sense.

---

<div class="post-metadata">

**Author:** ![John6666](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/john6666/32/27664_2.png) [@John6666](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FJohn6666)%5C
**Post date:** [October 18, 2024, 3:31pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgradio-could-not-find-files-for-the-given-pattern-s%2F112702%2F2 "2024-10-18T15:31:09Z")

</div>

Gradio seems to give that kind of error if the path is not passed.

> <https://github.com/gradio-app/gradio/issues/7798>
>
> \### Describe the bug
> 
> \`import gradio\` fails on Windows 10 Enterprise
> 
> \### Ha…ve you searched existing issues? 🔎
> 
> \- \[X\] I have searched and found no existing issues
> 
> \### Reproduction
> 
> OS: Windows 10 Enterprise - Version 10.0.19045 Build 19045
> 
> Run Powershell \[Conda\] prompt: 
> \`\`\`powershell
> conda create -c conda-forge -p .conda python=3.11 gradio
> conda activate .\\.conda
> python
> \`\`\`
> Another irritating detail was that it was working for some time INSIDE at least (but also ONLY in) Jupyter Notebooks - I had these running inside VS Code - at least when I was testing the minimal \`gradio.Interface\` examples - BUT the some minimal ChatInterface tests I tried (that included \`gr.Textbox\` were throwing \`TypeError: Expected a gr.Textbox or gr.MultimodalTextbox component, but got \<class 'gradio.components.textbox.Textbox'\>\`. 
> I tried the solution mentioned in #7783 for issue #7781 ie pip installing gradio-client from github. This resulted in other errors (mainly related to \`anyio\`) so I cleaned it all up again. 
> But now nothing seems to work anymore? 
> I tried to reduce it to a minimum, and even the basic \`import gradio\` ends up "in trouble". 
> 
> \`\`\`python
> \>\>\> import gradio
> \`\`\`
> Output: 
> \`\`\`
> Traceback (most recent call last):
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\httpx\\\_urlparse.py", line 346, in normalize\_port
> port\_as\_int = int(port)
> ^^^^^^^^^
> ValueError: invalid literal for int() with base 10: '5986.mapi.s-mxs.net'
> 
> During handling of the above exception, another exception occurred:
> 
> Traceback (most recent call last):
> File "\<stdin\>", line 1, in \<module\>
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\gradio\\\_\_init\_\_.py", line 3, in \<module\>
> import gradio.\_simple\_templates
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\gradio\\\_simple\_templates\\\_\_init\_\_.py", line 1, in \<module\>
> from .simpledropdown import SimpleDropdown
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\gradio\\\_simple\_templates\\simpledropdown.py", line 6, in \<module\>
> from gradio.components.base import FormComponent
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\gradio\\components\\\_\_init\_\_.py", line 1, in \<module\>
> from gradio.components.annotated\_image import AnnotatedImage
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\gradio\\components\\annotated\_image.py", line 14, in \<module\>
> from gradio.components.base import Component
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\gradio\\components\\base.py", line 20, in \<module\>
> from gradio.blocks import Block, BlockContext
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\gradio\\blocks.py", line 29, in \<module\>
> from gradio import (
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\gradio\\networking.py", line 20, in \<module\>
> from gradio.routes import App
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\gradio\\routes.py", line 137, in \<module\>
> client = httpx.AsyncClient()
> ^^^^^^^^^^^^^^^^^^^
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\httpx\\\_client.py", line 1442, in \_\_init\_\_
> self.\_mounts: dict\[URLPattern, AsyncBaseTransport | None\] = {
> ^
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\httpx\\\_client.py", line 1443, in \<dictcomp\>
> URLPattern(key): None
> ^^^^^^^^^^^^^^^
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\httpx\\\_utils.py", line 370, in \_\_init\_\_
> url = URL(pattern)
> ^^^^^^^^^^^^
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\httpx\\\_urls.py", line 115, in \_\_init\_\_
> self.\_uri\_reference = urlparse(url, \*\*kwargs)
> ^^^^^^^^^^^^^^^^^^^^^^^
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\httpx\\\_urlparse.py", line 248, in urlparse
> parsed\_port: int | None = normalize\_port(port, scheme)
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> File "C:\\Users\\SomeUser\\gradio-app\\.conda\\Lib\\site-packages\\httpx\\\_urlparse.py", line 348, in normalize\_port
> raise InvalidURL(f"Invalid port: {port!r}")
> httpx.InvalidURL: Invalid port: '5986.mapi.some-address.net'
> \`\`\`
> 
> \### Screenshot
> 
> \_No response\_
> 
> \### Logs
> 
> \_No response\_
> 
> \### System Info
> 
> \`\`\`shell
> running \`gradio environment\` gives exactly the same output as above
> \`conda list | grep gradio\` gives
> gradio 4.22.0 pyhd8ed1ab\_0
> gradio-client 0.13.0 pyhd8ed1ab\_0
> 
> Here is the full \`conda list --export \> environment.yml\` content:
> 
> \# This file may be used to create an environment using:
> \# $ conda create --name \<env\> --file \<this file\>
> \# platform: win-64
> aiofiles=23.2.1=pyhd8ed1ab\_0
> altair=5.2.0=pyhd8ed1ab\_1
> annotated-types=0.6.0=pyhd8ed1ab\_0
> anyio=3.7.1=pyhd8ed1ab\_0
> aom=3.8.2=h63175ca\_0
> attrs=23.2.0=pyh71513ae\_0
> brotli=1.1.0=hcfcfb64\_1
> brotli-bin=1.1.0=hcfcfb64\_1
> brotli-python=1.1.0=py311h12c1d0e\_1
> bzip2=1.0.8=hcfcfb64\_5
> ca-certificates=2024.2.2=h56e8100\_0
> cairo=1.18.0=h1fef639\_0
> certifi=2024.2.2=pyhd8ed1ab\_0
> charset-normalizer=3.3.2=pyhd8ed1ab\_0
> click=8.1.7=win\_pyh7428d3b\_0
> colorama=0.4.6=pyhd8ed1ab\_0
> contourpy=1.2.0=py311h005e61a\_0
> cycler=0.12.1=pyhd8ed1ab\_0
> dav1d=1.2.1=hcfcfb64\_0
> exceptiongroup=1.2.0=pyhd8ed1ab\_2
> expat=2.6.2=h63175ca\_0
> fastapi=0.110.0=pyhd8ed1ab\_0
> ffmpeg=6.1.1=gpl\_hb766fab\_106
> ffmpy=0.3.0=pyhb6f538c\_0
> filelock=3.13.1=pyhd8ed1ab\_0
> font-ttf-dejavu-sans-mono=2.37=hab24e00\_0
> font-ttf-inconsolata=3.000=h77eed37\_0
> font-ttf-source-code-pro=2.038=h77eed37\_0
> font-ttf-ubuntu=0.83=h77eed37\_1
> fontconfig=2.14.2=hbde0cde\_0
> fonts-conda-ecosystem=1=0
> fonts-conda-forge=1=0
> fonttools=4.50.0=py311ha68e1ae\_0
> freetype=2.12.1=hdaf720e\_2
> fsspec=2024.3.1=pyhca7485f\_0
> gradio=4.22.0=pyhd8ed1ab\_0
> gradio-client=0.13.0=pyhd8ed1ab\_0
> graphite2=1.3.13=1000
> h11=0.14.0=pyhd8ed1ab\_0
> h2=4.1.0=pyhd8ed1ab\_0
> harfbuzz=8.3.0=h7ab893a\_0
> hpack=4.0.0=pyh9f0ad1d\_0
> httpcore=1.0.4=pyhd8ed1ab\_0
> httpx=0.27.0=pyhd8ed1ab\_0
> huggingface\_hub=0.21.4=pyhd8ed1ab\_0
> hyperframe=6.0.1=pyhd8ed1ab\_0
> icu=73.2=h63175ca\_0
> idna=3.6=pyhd8ed1ab\_0
> importlib-metadata=7.1.0=pyha770c72\_0
> importlib-resources=6.4.0=pyhd8ed1ab\_0
> importlib\_resources=6.4.0=pyhd8ed1ab\_0
> intel-openmp=2024.0.0=h57928b3\_49841
> jinja2=3.1.3=pyhd8ed1ab\_0
> jsonschema=4.21.1=pyhd8ed1ab\_0
> jsonschema-specifications=2023.12.1=pyhd8ed1ab\_0
> kiwisolver=1.4.5=py311h005e61a\_1
> lcms2=2.16=h67d730c\_0
> lerc=4.0.0=h63175ca\_0
> libblas=3.9.0=21\_win64\_mkl
> libbrotlicommon=1.1.0=hcfcfb64\_1
> libbrotlidec=1.1.0=hcfcfb64\_1
> libbrotlienc=1.1.0=hcfcfb64\_1
> libcblas=3.9.0=21\_win64\_mkl
> libdeflate=1.19=hcfcfb64\_0
> libexpat=2.6.2=h63175ca\_0
> libffi=3.4.2=h8ffe710\_5
> libglib=2.80.0=h39d0aa6\_1
> libhwloc=2.9.3=default\_haede6df\_1009
> libiconv=1.17=hcfcfb64\_2
> libjpeg-turbo=3.0.0=hcfcfb64\_1
> liblapack=3.9.0=21\_win64\_mkl
> libopus=1.3.1=h8ffe710\_1
> libpng=1.6.43=h19919ed\_0
> libsqlite=3.45.2=hcfcfb64\_0
> libtiff=4.6.0=h6e2ebb7\_2
> libwebp-base=1.3.2=hcfcfb64\_0
> libxcb=1.15=hcd874cb\_0
> libxml2=2.12.6=hc3477c8\_0
> libzlib=1.2.13=hcfcfb64\_5
> m2w64-gcc-libgfortran=5.3.0=6
> m2w64-gcc-libs=5.3.0=7
> m2w64-gcc-libs-core=5.3.0=7
> m2w64-gmp=6.1.0=2
> m2w64-libwinpthread-git=5.0.0.4634.697f757=2
> markdown-it-py=3.0.0=pyhd8ed1ab\_0
> markupsafe=2.1.5=py311ha68e1ae\_0
> matplotlib-base=3.8.3=py311h6e989c2\_0
> mdurl=0.1.2=pyhd8ed1ab\_0
> mkl=2024.0.0=h66d3029\_49657
> msys2-conda-epoch=20160418=1
> munkres=1.1.4=pyh9f0ad1d\_0
> numpy=1.26.4=py311h0b4df5a\_0
> openh264=2.4.1=h63175ca\_0
> openjpeg=2.5.2=h3d672ee\_0
> openssl=3.2.1=hcfcfb64\_1
> orjson=3.9.15=py311h633b200\_0
> packaging=24.0=pyhd8ed1ab\_0
> pandas=2.2.1=py311hf63dbb6\_0
> pcre2=10.43=h17e33f8\_0
> pillow=10.2.0=py311h4dd8a23\_0
> pip=24.0=pyhd8ed1ab\_0
> pixman=0.43.4=h63175ca\_0
> pkgutil-resolve-name=1.3.10=pyhd8ed1ab\_1
> pthread-stubs=0.4=hcd874cb\_1001
> pthreads-win32=2.9.1=hfa6e2cd\_3
> pydantic=2.6.4=pyhd8ed1ab\_0
> pydantic-core=2.16.3=py311hc37eb10\_0
> pydub=0.25.1=pyhd8ed1ab\_0
> pygments=2.17.2=pyhd8ed1ab\_0
> pyparsing=3.1.2=pyhd8ed1ab\_0
> pysocks=1.7.1=pyh0701188\_6
> python=3.11.8=h2628c8c\_0\_cpython
> python-dateutil=2.9.0=pyhd8ed1ab\_0
> python-multipart=0.0.9=pyhd8ed1ab\_0
> python-tzdata=2024.1=pyhd8ed1ab\_0
> python\_abi=3.11=4\_cp311
> pytz=2024.1=pyhd8ed1ab\_0
> pyyaml=6.0.1=py311ha68e1ae\_1
> referencing=0.34.0=pyhd8ed1ab\_0
> requests=2.31.0=pyhd8ed1ab\_0
> rich=13.7.1=pyhd8ed1ab\_0
> rpds-py=0.18.0=py311hc37eb10\_0
> ruff=0.3.4=py311hc14472d\_0
> semantic\_version=2.10.0=pyhd8ed1ab\_0
> setuptools=69.2.0=pyhd8ed1ab\_0
> shellingham=1.5.4=pyhd8ed1ab\_0
> six=1.16.0=pyh6c4a22f\_0
> sniffio=1.3.1=pyhd8ed1ab\_0
> starlette=0.36.3=pyhd8ed1ab\_0
> svt-av1=1.8.0=h63175ca\_0
> tbb=2021.11.0=h91493d7\_1
> tk=8.6.13=h5226925\_1
> tomlkit=0.12.0=pyha770c72\_0
> toolz=0.12.1=pyhd8ed1ab\_0
> tqdm=4.66.2=pyhd8ed1ab\_0
> typer=0.9.0=pyhd8ed1ab\_0
> typing-extensions=4.10.0=hd8ed1ab\_0
> typing\_extensions=4.10.0=pyha770c72\_0
> tzdata=2024a=h0c530f3\_0
> ucrt=10.0.22621.0=h57928b3\_0
> urllib3=2.2.1=pyhd8ed1ab\_0
> uvicorn=0.29.0=py311h1ea47a8\_0
> vc=14.3=hcf57466\_18
> vc14\_runtime=14.38.33130=h82b7239\_18
> vs2015\_runtime=14.38.33130=hcb4865c\_18
> websockets=11.0.3=py311ha68e1ae\_1
> wheel=0.43.0=pyhd8ed1ab\_0
> win\_inet\_pton=1.1.0=pyhd8ed1ab\_6
> x264=1!164.3095=h8ffe710\_2
> x265=3.5=h2d74725\_3
> xorg-libxau=1.0.11=hcd874cb\_0
> xorg-libxdmcp=1.1.3=hcd874cb\_0
> xz=5.2.6=h8d14728\_0
> yaml=0.2.5=h8ffe710\_2
> zipp=3.17.0=pyhd8ed1ab\_0
> zlib=1.2.13=hcfcfb64\_5
> zstd=1.5.5=h12be248\_0
> \`\`\`
> \`\`\`
> 
> 
> \### Severity
> 
> Blocking usage of gradio

> **[How to Set the Path and Environment Variables in Windows](https://www.computerhope.com/issues/ch000549.htm)**
>
> Information on how to set the path and environment variables in Windows 2000, Windows XP, Windows Vista, and Windows 7.

---

<div class="post-metadata">

**Author:** ![Billy5000](https://avatars.discourse-cdn.com/v4/letter/b/77aa72/32.png) [@Billy5000](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FBilly5000)%5C
**Post date:** [October 18, 2024, 3:36pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgradio-could-not-find-files-for-the-given-pattern-s%2F112702%2F3 "2024-10-18T15:36:58Z")

</div>

Hi. And thanks for the quick reply. Which path? If my applications are functional then we have to conclude the paths are correct. I have 5 Stable Diffusion UIs, sharing the same checkpoints and Loras, and they all work perfectly from one python installation on the same drive. Am I missing something? Please note I mistakenly wrote “Error” in my OP, but it’s Info, not an error. Still I’d like to understand why given it is not a path issue, at least not one with python.

---

<div class="post-metadata">

**Author:** ![John6666](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/john6666/32/27664_2.png) [@John6666](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FJohn6666)%5C
**Post date:** [October 18, 2024, 3:42pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgradio-could-not-find-files-for-the-given-pattern-s%2F112702%2F4 "2024-10-18T15:42:35Z")

</div>

So is this it?  
Because in Windows, if you call a batch file from Powershell or something like that, CMD will be launched.

> **[INFO: Could not find files for the given pattern(s). ·...](https://github.com/smartcontractkit/full-blockchain-solidity-course-py/discussions/859)**
>
> cavan@DESKTOP-ILR3U0U MINGW64 ~/Documents/python practice/trading-bot $ python deploy.py INFO: Could not find files for the given pattern(s). I have tried Bash & Powershell. My concern is maybe I d...

---

<div class="post-metadata">

**Author:** ![Billy5000](https://avatars.discourse-cdn.com/v4/letter/b/77aa72/32.png) [@Billy5000](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FBilly5000)%5C
**Post date:** [October 18, 2024, 4:17pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgradio-could-not-find-files-for-the-given-pattern-s%2F112702%2F5 "2024-10-18T16:17:44Z")

</div>

Thank you for the link John. Unfortunately the “solution” doesn’t answer my question. As you know there are dozens of ways to launch a python app. You can do it from CMD in explorer, from a .bat file, from powershell, by double clicking on the .py file itself, from a VS Code terminal, and on and on. This doesn’t explain why I’m getting this info message on a fresh install.

Edit: also the link you read isn’t related to Gradio. It is a generic error, and in this case was related to web3 and/or c++ tools, rather than Gradio which has different requirements and dependencies.  
Cheers

---

<div class="post-metadata">

**Author:** ![John6666](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/john6666/32/27664_2.png) [@John6666](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FJohn6666)%5C
**Post date:** [October 18, 2024, 4:38pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgradio-could-not-find-files-for-the-given-pattern-s%2F112702%2F6 "2024-10-18T16:38:57Z")

</div>

It is indeed strange that there is an error message instead of a warning or notice even though it works.  
Since I am also in a Windows environment, I often encounter phenomena that are difficult to encounter in Linux or Mac.  
In the case of Python, when there are multiple Pythons in the environment, and sometimes a different Python is called than expected. But even in this case, if an error occurs, we usually abort there.
