dosubot[bot] commented on issue #38429:
URL: https://github.com/apache/superset/issues/38429#issuecomment-4002680114

   <!-- Answer -->
   This is a configuration issue caused by the 
`WEBDRIVER_BASEURL_USER_FRIENDLY` setting. The port 8888 comes from a 
[hardcoded value in the Docker development 
configuration](https://github.com/apache/superset/blob/829e4d92d91ceae4b43b1ed3b063ffe45377799c/docker/pythonpath_dev/superset_config.py#L104-L108),
 which incorrectly differs from the actual Superset port 8088.
   
   **To fix this**, set the correct value in your `superset_config.py`:
   
   ```python
   WEBDRIVER_BASEURL = "http://superset_app:8088/";  # Internal URL for 
screenshots
   WEBDRIVER_BASEURL_USER_FRIENDLY = "http://localhost:8088/";  # External URL 
for notifications
   ```
   
   The [alert URL construction uses 
`WEBDRIVER_BASEURL_USER_FRIENDLY`](https://github.com/apache/superset/blob/829e4d92d91ceae4b43b1ed3b063ffe45377799c/superset/utils/urls.py#L25-L42)
 as the base when building webhook payload URLs.
   
   **Note on `form_data` vs `form_data_key`**: The `form_data` parameter is 
actually correct behavior for alerts. Alert URLs [embed the chart ID directly 
in the form_data 
parameter](https://github.com/apache/superset/blob/829e4d92d91ceae4b43b1ed3b063ffe45377799c/superset/commands/report/execute.py#L218)
 as `{"slice_id": 73}` to create self-contained URLs that don't depend on Redis 
cache state. The `form_data_key` you see in the browser is used for complex 
explore sessions.
   
   The missing hostname (`http://:8888`) suggests 
`WEBDRIVER_BASEURL_USER_FRIENDLY` may be set to something like `:8888/` instead 
of a full URL. This is worth filing a PR to fix the default Docker 
configuration since it's a clear bug.
   
   
   <!-- Dosu Comment Footer -->
   *To reply, just mention [@dosu](https://go.dosu.dev/dosubot).*
   
   ---
   <sup>How did I do? 
[Good](https://app.dosu.dev/response-feedback/8cfa7e00-db74-4da7-9de3-ed6dc28b910c?feedback_type=great_response)
 | 
[Irrelevant](https://app.dosu.dev/response-feedback/8cfa7e00-db74-4da7-9de3-ed6dc28b910c?feedback_type=irrelevant_answer)
 | 
[Incorrect](https://app.dosu.dev/response-feedback/8cfa7e00-db74-4da7-9de3-ed6dc28b910c?feedback_type=incorrect_sources)
 | 
[Verbose](https://app.dosu.dev/response-feedback/8cfa7e00-db74-4da7-9de3-ed6dc28b910c?feedback_type=too_verbose)
 | 
[Hallucination](https://app.dosu.dev/response-feedback/8cfa7e00-db74-4da7-9de3-ed6dc28b910c?feedback_type=hallucination)
 | [Report 
🐛](https://app.dosu.dev/response-feedback/8cfa7e00-db74-4da7-9de3-ed6dc28b910c?feedback_type=bug_report)
 | 
[Other](https://app.dosu.dev/response-feedback/8cfa7e00-db74-4da7-9de3-ed6dc28b910c?feedback_type=other)</sup>
   
   [![Chat with 
Dosu](https://dosu.dev/dosu-chat-badge.svg)](https://app.dosu.dev/a28d3c7e-a9d3-459e-9fb6-3a6f9ff4f357/ask?utm_source=github)&nbsp;[![Open
 in 
Cursor](https://dosu.dev/dosu-in-cursor.svg)](https://cursor.com/link/prompt?text=This%20is%20a%20configuration%20issue%20caused%20by%20the%20%60WEBDRIVER_BASEURL_USER_FRIENDLY%60%20setting.%20The%20port%208888%20comes%20from%20a%20%5Bhardcoded%20value%20in%20the%20Docker%20development%20configuration%5D%28https%3A//github.com/apache/superset/blob/829e4d92d91ceae4b43b1ed3b063ffe45377799c/docker/pythonpath_dev/superset_config.py%23L104-L108%29%2C%20which%20incorrectly%20differs%20from%20the%20actual%20Superset%20port%208088.%0A%0A%2A%2ATo%20fix%20this%2A%2A%2C%20set%20the%20correct%20value%20in%20your%20%60superset_config.py%60%3A%0A%0A%60%60%60python%0AWEBDRIVER_BASEURL%20%3D%20%22http%3A//superset_app%3A8088/%22%20%20%23%20Internal%20URL%20for%20screenshots%0AWEBDRIVER_BASEURL_USER_FRIENDLY%20%3D%20%22http%3A//localhost%3A8088/
 
%22%20%20%23%20External%20URL%20for%20notifications%0A%60%60%60%0A%0AThe%20%5Balert%20URL%20construction%20uses%20%60WEBDRIVER_BASEURL_USER_FRIENDLY%60%5D%28https%3A//github.com/apache/superset/blob/829e4d92d91ceae4b43b1ed3b063ffe45377799c/superset/utils/urls.py%23L25-L42%29%20as%20the%20base%20when%20building%20webhook%20payload%20URLs.%0A%0A%2A%2ANote%20on%20%60form_data%60%20vs%20%60form_data_key%60%2A%2A%3A%20The%20%60form_data%60%20parameter%20is%20actually%20correct%20behavior%20for%20alerts.%20Alert%20URLs%20%5Bembed%20the%20chart%20ID%20directly%20in%20the%20form_data%20parameter%5D%28https%3A//github.com/apache/superset/blob/829e4d92d91ceae4b43b1ed3b063ffe45377799c/superset/commands/report/execute.py%23L218%29%20as%20%60%7B%22slice_id%22%3A%2073%7D%60%20to%20create%20self-contained%20URLs%20that%20don%27t%20depend%20on%20Redis%20cache%20state.%20The%20%60form_data_key%60%20you%20see%20in%20the%20browser%20is%20used%20for%20complex%20explore%20sessions.%0A%0AThe%20missing%20
 
hostname%20%28%60http%3A//%3A8888%60%29%20suggests%20%60WEBDRIVER_BASEURL_USER_FRIENDLY%60%20may%20be%20set%20to%20something%20like%20%60%3A8888/%60%20instead%20of%20a%20full%20URL.%20This%20is%20worth%20filing%20a%20PR%20to%20fix%20the%20default%20Docker%20configuration%20since%20it%27s%20a%20clear%20bug.)&nbsp;[![Join
 
Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot)&nbsp;[![Share
 on 
X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/apache/superset/issues/38429)


-- 
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