bxsx commented on code in PR #42495:
URL: https://github.com/apache/superset/pull/42495#discussion_r3670062425


##########
docs/admin_docs/configuration/alerts-reports.mdx:
##########
@@ -277,7 +277,7 @@ WEBDRIVER_OPTION_ARGS = [
 ]
 
 # This is for internal use, you can keep http
-WEBDRIVER_BASEURL = "http://superset:8088"; # When running using docker compose 
use "http://superset_app:8088'
+WEBDRIVER_BASEURL = "http://superset:8088"; # This is also the default for 
Docker Compose, where the app service is named "superset"

Review Comment:
   The comment reflects how the value is actually consumed. Every path joined 
onto this base is root-relative - `url_for()` output via `get_url_path()`, or 
the literal `/login/` in 
[machine_auth.py](https://github.com/apache/superset/blob/master/superset/utils/machine_auth.py)
 - and for root-relative paths `urljoin` discards the base path entirely: 
`urljoin("http://superset:8088//"`, `"/superset/dashboard/1/")` -> 
`http://superset:8088/superset/dashboard/1/`. The trailing slash and base path 
cannot change the result. The app-root prefix is applied on the path side - 
from `APPLICATION_ROOT` -it is not read from this base URL. See: 
https://github.com/apache/superset/blob/00c60bf2def2db276cca0c0e614a3cd011e69bde/superset/utils/urls.py#L34-L49
   
   The one consumer that doesn't go through `urljoin` is cache warm-up which 
concatenates after `rstrip('/')`: 
https://github.com/apache/superset/blob/00c60bf2def2db276cca0c0e614a3cd011e69bde/superset/tasks/cache.py#L56-L67
   That's why the f-string keeps `{SUPERSET_APP_ROOT}` in the value. Happy to 
extend the comment with that nuance if maintainers feel it earns the extra 
lines.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to