File tree Expand file tree Collapse file tree 5 files changed +171
-1
lines changed
workshop_playwright_python/apps Expand file tree Collapse file tree 5 files changed +171
-1
lines changed Original file line number Diff line number Diff line change @@ -164,3 +164,4 @@ cython_debug/
164
164
requirements.txt
165
165
generated
166
166
tests /test_codegen.py
167
+ .streamlit /*
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ make install-deps-dev
15
15
16
16
- [[ BUG] Host system is missing dependencies to run browsers (WSL2) #19100 ] ( https://github.com/microsoft/playwright/issues/19100 )
17
17
18
- ## Guides
18
+ ## Fundamentals
19
19
20
20
To run some demos, please follow the instructions below.
21
21
@@ -30,6 +30,35 @@ make show-trace
30
30
make codegen
31
31
```
32
32
33
+ ## Guides
34
+
35
+ ### Authentication
36
+
37
+ To run a frontend application with authentication, you can refer to the following links.
38
+
39
+ - [ User authentication and information] ( https://docs.streamlit.io/develop/concepts/connections/authentication )
40
+ - [ Use Microsoft Entra to authenticate users] ( https://docs.streamlit.io/develop/tutorials/authentication/microsoft )
41
+
42
+ For example, you can use the following file [ .streamlit/secrets.toml] ( ../.streamlit/secrets.toml ) to set up authentication with Microsoft Entra ID.
43
+
44
+ ``` toml
45
+ [auth ]
46
+ redirect_uri = " http://localhost:8501/oauth2callback"
47
+ cookie_secret = " xxx"
48
+
49
+ [auth .microsoft ]
50
+ client_id = " your-client-id"
51
+ client_secret = " your-client-secret"
52
+ server_metadata_url = " https://login.microsoftonline.com/consumers/v2.0/.well-known/openid-configuration"
53
+ ```
54
+
55
+ Then, run the application using the following command:
56
+
57
+ ``` shell
58
+ # Run the application
59
+ uv run streamlit run workshop_playwright_python/apps/authentication.py
60
+ ```
61
+
33
62
## [ Microsoft Playwright Testing] ( https://learn.microsoft.com/ja-jp/azure/playwright-testing/ )
34
63
35
64
- [ Get Started Sample] ( https://github.com/microsoft/playwright-testing-service/tree/main/samples/get-started )
Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ description = "A GitHub template repository for Python"
5
5
readme = " README.md"
6
6
requires-python = " >=3.10"
7
7
dependencies = [
8
+ " authlib>=1.5.2" ,
8
9
" playwright>=1.52.0" ,
9
10
" pytest-playwright>=0.7.0" ,
10
11
" streamlit>=1.45.0" ,
You can’t perform that action at this time.
0 commit comments