-
Notifications
You must be signed in to change notification settings - Fork 966
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
.Humanize() on "Arabic" letters returns empty string (or any other casing) #578
Comments
Could you please check 2.1? |
Ok |
Using Xamarin Studio 6 and getting following error while upgrading:
|
Never mind, I switched to Visual Studio to update the nugets to v2.1. It's still occurring. The values returned are empty string. I have installed
|
For Xamarin Studio, you need to be on the beta channel. |
@onovotny kindly read my comment above. I switched to VS to update the nugets but still same problem with me |
We'll need more information to diagnose. What project type, what does your solution look like, what does your project look like? |
HYG
|
What kind of app is this? .NET 4.5 or .NET Core App 1.0? |
@onovotny .net 4.6.1 command line as shown in |
These characters are of the Unicode category "Letter, Other" and currently not matched by the regex. The easiest fix would be to pass them through as-is, but I can't say if that's enough to "humanize" Arabic, Hebrew or Egyptian hieroglyphics … |
* Add Esperanto support to NumberToWords. Fixes Humanizr#558 * Fixed incorrect locale in readme For example on `ToOrdinalWords` the Arabic example was incorrectly listed as 'Brazilian Portuguese' * Pass through the content of the "Letter, other" Unicode category. fixes Humanizr#578 * Fix misspelling Fixed misspelling of "Uper" to "Upper". * added translation for DateHumanize_Now * update for latest gv config * Add resource validation for DefaultFormatter to prevent "Value cannot be null." exception on the .NET format. * Fix missing format value for the argument exception. * Validate resource key before using .FormatWith extension. * Use string interpolation beside string format. * Add summary for DefaultFormatter. * temp disable gitlink * Fix CONTRIBUTING.md of broken links. * Squashed commit of the following: commit f9423de Author: hangy <hangy@hangy.de> Date: Thu Dec 1 20:48:01 2016 +0100 Update TimeSpanHumanizeTests.cs commit 2e5dfe5 Author: hangy <hangy@hangy.de> Date: Thu Dec 1 20:37:50 2016 +0100 Apparently I'm stupid and 7 days actually get humanized as 1 week. commit 152a119 Author: hangy <hangy@hangy.de> Date: Wed Nov 30 23:50:51 2016 +0100 Workaround for unneeded suffix: Just use the same value. The reason for this workaround is that at the method that decides if the suffix should be applied, the information about the time unit is not available. So it would either need to do some string magic and explicitly exclude the "TimeSpanHumanize_MultipleDays" resource key from adding the postfix, or most of the `TimeSpan` formatting code would need to be rewriten for Croatian or modified for all languages to support Croatian. Neither seems reasonable for a quick change. commit 002cc7b Author: hangy <hangy@hangy.de> Date: Wed Nov 30 23:12:57 2016 +0100 Added some more tests. From what I've read, all days should resolve to "dana" for the Croatian language. (No "_DualTrialQuadral" postfix.") commit c190e9d Author: hangy <hangy@hangy.de> Date: Tue Nov 22 00:29:51 2016 +0100 Add initial test for issue 597. * fix cmd build * update packages * Revert "Add Esperanto support to NumberToWords. Fixes Humanizr#558" * Add Authenticode signing to binaries * install signclient package * Register Portuguese TimeSpan localisation as "pt". According to Humanizr#601, the localisation is good for Portuguese in general, not just for Brazilian Portuguese. I copied the unit test, so that we can prove that there's no regression. Additionally, I copied the `OrginalizeTests`, because those were already registered as "pt", not "pt-BR". Note that `NumberToWords` is still only valid for pt-BR unless confirmed otherwise. * Syntax correction in readme.md Very minor correction to the syntax. Named parameters require a :, not a =. (I found this when I copy/pasted the code and it didn't work without changes) * Added test to reproduce issue * Handles issue without try-catch Utilize null-checks to verify there is a description in the enums display attribute * Added whitespace before if-statement Added a whitespace before if-statement * adding parameter decimals toMetric(). See issue Humanizr#609 * Added Sweedish collection formatter * issue 611: added the method Kebaberize * removed a comment and an empty char * Update readme.md * Update to VS 2017 * remove file from root * gv * update CS url * appveyor * clean code a bit I am not sure about the line 12. I think the difference between both is more clear like this. * Revert "clean code a bit" This reverts commit eb110e5. * IsDefined is prefered `IsDefined` won't loop through all the attributes. Just saying, didn't bench it. * Latvian localization Thanks to Līva Miltuze for help with translation. * Create Humanizer.Core.lv.nuspec * Update Humanizer.sln * Update Humanizer.old.csproj * Implemented TimeSpan Humanize extension method for TimeUnit.Month and TimeUnit.Year with translations. * Readme updated. * Changes in csproj reverted. * Test for uniqueness of day sequences added. * Include LV in main package * remove old project file * Build script updates * Add sourcelink * fix sign client syntax * Add support for long to ToQuantity * Update Number to words to take a long * Add long.ToQuantity(ShowQuantityAs.Words) * Add extra public method for int and long * Update public_api_approved.txt * Add tests for long.ToWords() and update XML comment * Removing out of range test, correcting names of large numbers * update to long * fix merge * Add ToOrdinalWords extension with gender overload * Use localisation for ToOrdinalWords to allow for localised implementation and add readme section * Update XML docs for DateToOrdinalWords * VS...grr. * pdb is embedded now * Incorporated review comments by @khellang, @M-Zuber, @jeremymeng. Marked reviewed language with "Native speaker". Marked 'sv' as reviewed even confirmation is pending. * Marked confirmed translations with "Native speaker". * Update xUnit and fix test overload issue * Added greek language resources as per #pr632 * v2.2 release notes * Update package
I have an app where string being humanized could be of any culture.
I have Thread Culture properly set to Arabic.
Expected behavior: It should return exact same string.
The text was updated successfully, but these errors were encountered: