We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
This program will not exit if foo.tcss does not exist:
foo.tcss
import asyncio from textual.app import App class MyApp(App): CSS_PATH = "foo.tcss" async def my_test(): app = MyApp() async with app.run_test() as pilot: pilot.press("enter") asyncio.run(my_test())
We see the StyleSheetError printed to the console, but the app then continues (or hangs).
In pytest, this test will simply hang, and not fail if the stylesheet doesn't exist:
import asyncio from textual.app import App @pytest.mark.asyncio def test_cannot_find_stylesheet(): class MyApp(App): CSS_PATH = "foo.tcss" app = MyApp() async with app.run_test() as pilot: pilot.press("enter")
In contrast, this raises and exits:
from textual.app import App class MyApp(App): CSS_PATH = "foo.tcss" app = MyApp() app.run()
The text was updated successfully, but these errors were encountered:
Thank you for your issue. Give us a little time to review it.
PS. You might want to check the FAQ if you haven't done so already.
This is an automated reply, generated by FAQtory
Sorry, something went wrong.
Don't forget to star the repository!
Follow @textualizeio for Textual updates.
Successfully merging a pull request may close this issue.
This program will not exit if
foo.tcss
does not exist:We see the StyleSheetError printed to the console, but the app then continues (or hangs).
In pytest, this test will simply hang, and not fail if the stylesheet doesn't exist:
In contrast, this raises and exits:
Textual Diagnostics
Versions
Python
Operating System
Terminal
Rich Console options
The text was updated successfully, but these errors were encountered: