Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsExtension Verif...Extension Verif... incompatible encoding (System.Text.ASCIIEncoding) detected in the following file incompatible encoding (System.Text.ASCIIEncoding) detected in the following file
Previous
 
Next
New Post
6/18/2013 12:28 PM
 

I'm getting this error on my resource files.  I'm not sure why because they are using utf-8 encoding.  To download a sample, go here and download the DigArticle Trial and choose any of the .resx files.  If you need further info, please let me know.

ExtensionMessageID: 44285

ExtensionID: 4852

MessageTypeID: 1

MessageID: 1b9b2b2c-c42f-408c-8810-268d4a4f23fc

Message: incompatible encoding (System.Text.ASCIIEncoding) detected in the following file: C:\Resources\directory\e78e1a2776a84837b93b1ddf637d8a18.EVSWorker.CustomTempLocalStore\9d11a2c3-dad6-4eb8-9b00-479711b9af2c\2eaf3cfd-b488-42f1-8237-de6335c98179\App_LocalResources\ViewArticle.ascx.resx

Rule: PackageVerification.Rules.FileEncodingChecker


Thanks
Mike

 
New Post
6/18/2013 1:30 PM
 
Hi Mike,

I looked into this and while your *.resx files have xml version="1.0" encoding="utf-8" at the top, it doesn't necessarily make your file UTF-8 encoded.

To test the encoding of a file, open the file in notepad and select "Save As" then look at the Encoding drop down. If it says anything other than "UTF-8", your file is not actually UTF-8 encoded. When I looked at the *.resx files included in your extensions they all seem to be ANSI encoded which would match the results that EVS is giving you.

Let me know if you have any other questions.

Cheers,

Nathan Rover
 
New Post
6/18/2013 3:26 PM
 
Hi Nathan,
Thanks for looking into this. I use Notepad++ and it detects my resx files as UTF 8 without BOM. When I save them in notepad, Notepad++ detects them as UTF8 with BOM. I assume it's the detection of the BOM that makes it pass or fail the test. I found this interesting entry on stackoverflow on the subject:

http://stackoverflow.com/questions/22...

It seems the existence of BOM isn't a requirement for a file to be considered utf8.

In fact, if I am in Visual Studio and I put some chinese characters in the resx and save it, it doesn't put the BOM marker in the file.

As another test. I saved it with the BOM, then I edited the .resx in Visual Studio, and it seemed to take out the BOM marker.

Lastly.... I tested the DNN Feedback module ( a recently updated DNN module) and it's showing the same error. It's resx files do not have the BOM marker.

It the BOM marker being used to determine if it's UTF8?

Thanks
Mike
 
New Post
6/19/2013 11:40 AM
 

Hi,

The BOM marker is being used to determine if the .resx file is UTF-8 encoded. The reason is that we have found localized resource files causing an exception because .NET XML libraries can't correctly load them and this is just another reason (please, check issue "DNN24879 Print failing resx file when logging error in loading resources" http://support.dotnetnuke.com/project... for more info).

The problem with Visual Studio removing the BOM markers is also a well-known issue (see http://stackoverflow.com/questions/54... for more info).

Effectively DNN Feedback has this problem in the current release. We are contacting the most used Open Source project coordinators to let them know about this and other Azure incompatibilities.

IMHO, this issue should be considered in EVS as a Warning, and out of the Azure checks, since is something that affects all DNN installations.

Hope this helps,

David Rodriguez


David Rodriguez
DNN Cloud Team Lead Engineer | Microsoft Azure MVP | Microsoft Azure Insider / Advisor

 
New Post
6/19/2013 1:55 PM
 
Okay, As per Davids recommendation, I've dropped these down to warnings, and have removed them from being a requirement for being SQL azure compatible.

Please let me know if you have any other questions.

Cheers,

Nathan Rover
 
Previous
 
Next
HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsExtension Verif...Extension Verif... incompatible encoding (System.Text.ASCIIEncoding) detected in the following file incompatible encoding (System.Text.ASCIIEncoding) detected in the following file


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out