Comments (5)
I would expect the Localization.EnsureInitialized
method to throw an exception when the Localization cannot be initialized (because the underlying Publication is not published); I don't like silently ignoring error conditions (it tends to lead to unclear errors/exception later in the process).
However, it seems to me this "issue" is related to your work-around for another issue: #45
Do you think this issue is still relevant if that other issue would be fixed?
from dxa-web-application-dotnet.
This issue is releated to #45 in the sense that #45 has a try-catch block as a workaround for this exception.
Comment #45 (comment) is descibing a workaournd to load all localizations. It calls Localization.EnsureInitialized()
which might throw this exception.
This issue (#48) will still be relevant when #45 is resolved because there can be other logic which calls Localization.EnsureInitialized()
.
from dxa-web-application-dotnet.
Maybe the real issue is that the Localization object exists in the first place. I agree that something should happen when `Localization.EnsureInitialized()' cannot load the Localization, but it is is unexpected when a publication's settings page is not published?
If DXA would load all Localization.SiteLocalizations
and remove the SiteLocalizations which cannot be loaded then it would not be an issue, and Localization.EnsureInitialized() can thow the error indeed. Added #45 (comment) to descirbe this in a bit more detail.
from dxa-web-application-dotnet.
I agree with the idea to suppress Localization for Publications which are not published from Localization.SiteLocalizations
and still letting Localization.EnsureInitialized
throw an exception in case it cannot be initialized (this is really be an exceptional, unrecoverable error condition). Would you agree with closing this issue and keeping #48 open, then?
from dxa-web-application-dotnet.
yes, agree 👍
from dxa-web-application-dotnet.
Related Issues (20)
- Sdl.Web.Common.Models.PageModel.GetXpmMarkup() calls unused XpmMetadata HOT 2
- DXA1.6 web solution (dxa-web-application-dotnet-DXA_1.6_Release.zip) HOT 1
- Language selector URL does not expect null page id HOT 2
- Use precompiled views HOT 1
- Have DXA sources in a symbol server HOT 2
- Only possible to embedded MediaItem entities in Rich Text fragments HOT 2
- Component Link mapping fails after link depth reached in web application. HOT 2
- Model Service (R2) ComponentTemplate missing from DCP(s) HOT 3
- ModelServiceClient ArgumentNullException crash HOT 2
- HtmlHelper null pointer exceptions HOT 3
- Ambiguous DXA exception for PCA DXA model addon
- Keyword Model extensions are not supported without a Metadata Schema
- RichText model extensions are not supported
- Output Cache is caching even if there is an error on the page HOT 1
- can DXA Container Framework be extended to support DXA 2.2 on Tridion 9/9.1
- Images with spaces return 404
- BinaryFileManager - StripDimensions UrlDecode ran only when no dimensions HOT 1
- MimeMapping.GetMimeMapping returns wrong mime types
- reuse HttpClient object / SNAT port exhaustion HOT 1
- Outputcache empty content after redirect HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dxa-web-application-dotnet.