How to hide pages of multiweb page app using st-pages?

To display pages in the main .py file, I use show_pages as follows:

from st_pages import hide_pages, show_pages, Page

show_pages(
    [
        Page("app.py"),
        Page("pages/1_A.py"),
        Page("pages/2_B.py"),
    ]
)

But what if I want to hide a page using hide_pages ?
If I add to the code above:

hide_pages(
    [
        Page("pages/test.py"),
     ]
)

And then I want to open a test page using the url http://localhost:8501/test,
it prints:

Page not found

You have requested page /test, but no corresponding file was found in the app’s pages/ directory. Running the app’s main page.

Doesn’t the call to hide_pages actually hide the pages?

According to the documentation, these pages should only be hidden via CSS and can still be visited using the URL.

 These pages are only hidden via CSS, and can still be visited by the URL.

That is right.

And if i try to open the hidden page using URL it says:

Page not found

You have requested page /test, but no corresponding file was found in the app’s pages/ directory. Running the app’s main page.

To better clarify the issue: Page not found: no corresponding file was found · Issue #80 · blackary/st_pages (github.com)

@blackary Would you be able to help? Thank you in advance :pray: