When a user has a notification warning, as the one we are showing with the PG11 migration info, the message shown appears in two different banners in API keys page. The banner below shouldn’t be appearing in this case.

More info can be read in https://github.com/CartoDB/cartodb/pull/14920
Hey! We are using the banner for a licensing warning we are going to add in the next on-premises release (this week!), so it would be nice if we could fix it before :angel:
@csubira
After a little bit of research I found that the duplicated notification is displayed in the application.html.erb layout which means that since this template is used in many other pages this issue is not only for the API keys page. (In some of the other cases we haven't seen it because it's hidden because of the positioning, or because we haven't checked them)
The pages affected by this issue are the ones rendered by the following admin controllers (All of them from the Settings section in Dashboard):
client_applications_controller.rb : API keys pageorganization_users_controller.rb and 'organizations_controller.rb': Organizations settings pagesusers_controller.rb: User settings. In _Profile_ and _Account_ pages it is not displayed since the render sets that layout to false and then it is not application the template.mobile_apps_controller.rb: Mobile apps pages/Connected Appsand then from superadmin:
users_controller.rborganizations_controller.rbplatform_controller.rbsynchronizations_controller.rbMy suggestion is to remove the code in application layout where if the user has notifications is checked and the duplicated banner displayed.
notifications property of User that we need to take into account?@gonzaloriestra @ana-md anything that can help me to strike any of the cons?
Thanks for the detailed analysis! :clap:
AFAIK, we only use this kind of notifications with a rake task, adding always a custom message, so I don't see any problem.
Regarding superadmin, I'd say it's ok if we don't show the banner there. It's only for us and we normally use other places to notify about this stuff (like Slack).
@alrocar?
👍
Thanks a lot for explaining it so clearly @csubira!!
Agree with @gonzaloriestra about Superadmin, at least from what I have seen on how we use it internally. About the rest, I am not familiar with it at all 😅
Thank you all! Merged and deployed! 🚀
Most helpful comment
Thank you all! Merged and deployed! 🚀