Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
app-editors/wxhexeditor prints weird message to stdout, bug?
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Gentoo Chat
View previous topic :: View next topic  
Author Message
leyvi
Guru
Guru


Joined: 08 Sep 2023
Posts: 308

PostPosted: Sat Mar 15, 2025 9:49 pm    Post subject: app-editors/wxhexeditor prints weird message to stdout, bug? Reply with quote

app-editors/wxhexeditor prints the following message to the terminal when run on this core file from Chromium crashing:
Code:
leyvi ~ (0) $ wxHexEditor core
Rahman ve Rahim olan Allah'ın adıyla.
According to Google Translate, this is what it means, in Turkish:
Code:
In the name of Allah, the Most Gracious, the Most Merciful.
It's obviously harmless, but I'm pretty sure religion doesn't belong here. Should I file a bug report?
Back to top
View user's profile Send private message
Hu
Administrator
Administrator


Joined: 06 Mar 2007
Posts: 23326

PostPosted: Sun Mar 16, 2025 12:41 am    Post subject: Reply with quote

Do you mean a bug report to Gentoo or a bug report to upstream? Why would this be a bug report? You disagree with upstream's choice, but this is not something I would expect Gentoo to patch out.
Back to top
View user's profile Send private message
leyvi
Guru
Guru


Joined: 08 Sep 2023
Posts: 308

PostPosted: Sun Mar 16, 2025 1:53 am    Post subject: Reply with quote

I simply don't think that religion has a place in free software, unless religion is supposed to be a central feature of said software. In other words, unless declaring that God is gracious and merciful somehow makes wxHexEditor better at its job, I don't think that it should be making that declaration. Nothing against religion (as a religious man myself), but I really don't think it belongs here, especially since religion causes conflict and free software needs unity.

An example of a project I think should contain references to God, religion etc is the Sefaria project. It is a collection of Jewish texts, with searching, a web app/site, mobile apps, APIs for third-party use, and more, and unless I'm mistaken, the entire thing is GPL licensed. This makes sense, since I won't be using Sefaria for anything other than looking at religious texts.

So perhaps you can understand my confusion when I get lectured about someone else's God by a file editor of all things, and in Turkish, no less; it just seems a bit off-topic, if you catch my drift :?
Back to top
View user's profile Send private message
sMueggli
Guru
Guru


Joined: 03 Sep 2022
Posts: 579

PostPosted: Sun Mar 16, 2025 9:57 am    Post subject: Reply with quote

leyvi wrote:
I simply don't think that religion has a place in free software, unless religion is supposed to be a central feature of said software.


In other words, you want to change free software to not-so-free software?

By the way, free software allows you to modify the source code. As long as you do not violate the license you can modify ("improve") the software and redistribute it. Or you open a bug report upstream.
Back to top
View user's profile Send private message
leyvi
Guru
Guru


Joined: 08 Sep 2023
Posts: 308

PostPosted: Sun Mar 16, 2025 12:18 pm    Post subject: Reply with quote

Quote:
In other words, you want to change free software to not-so-free software?
Pardon me, but what exactly about pushing one's religion on others is free?

Quote:
By the way, free software allows you to modify the source code. As long as you do not violate the license you can modify ("improve") the software and redistribute it.
I'm not going to go through the trouble of forking a project just to patch out one line of code.

Quote:
Or you open a bug report upstream.
Yeah... that's kind of what this whole thread is about. I'm simply not sure if this qualifies as a bug, and I want to confirm before I go bother the developers. I do believe that this is a bug, but I want to know if I'm just biased.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 55162
Location: 56N 3W

PostPosted: Sun Mar 16, 2025 12:50 pm    Post subject: Reply with quote

leyvi,

It looks like a one line patch.
It will be faster to produce the patch than file the bug.

The patch goes into /etc/portage/patches/ so that it applied every time the package is built.

Free software (FOSS if you like) should be inclusive - that is regardless of religion or other things.

A long time ago I recall producing some avionic equipment for a Muslim country.
One of the requirements was that it had to display a message like the above, when it was starting up.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
leyvi
Guru
Guru


Joined: 08 Sep 2023
Posts: 308

PostPosted: Sun Mar 16, 2025 1:10 pm    Post subject: Reply with quote

Quote:
A long time ago I recall producing some avionic equipment for a Muslim country.
One of the requirements was that it had to display a message like the above, when it was starting up.
Is this a national law, or a religious one (out of curiosity)?
Perhaps the developers should make it a build-time option (maybe a macro, like PRAISE_ALLAH, off by default), that the user can toggle if they wish. These things really ought to be agnostic to religion, race, etc unless that is the explicit point, like my Sefaria example. In my opinion, leaving religion out of FOSS is a part of making it inclusive, and in the very least, religious features in secular applications should be made optional and off by default, as to some they are bugs, and certainly they are irrelevant to most. I seriously have no problem with our FOSS-developing friends who happen to be Muslims, and I would say the exact same thing about a message like 'בס"ד' or the Christian equivalent of those two, whatever that may be (I don't know many religious Christians).


Last edited by leyvi on Sun Mar 16, 2025 1:50 pm; edited 2 times in total
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 55162
Location: 56N 3W

PostPosted: Sun Mar 16, 2025 1:15 pm    Post subject: Reply with quote

leyvi,

I don't know where the requirement came from.
It was in the requirement specification, so the customer paid for it and got it.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
leyvi
Guru
Guru


Joined: 08 Sep 2023
Posts: 308

PostPosted: Sun Mar 16, 2025 1:26 pm    Post subject: Reply with quote

Quote:
I don't know where the requirement came from.
It was in the requirement specification, so the customer paid for it and got it.
Huh, interesting. I have a friend who works at one of Google's middle-eastern offices. I'll ask him if he knows about any regulations like this, religious or otherwise, as this seems like something he'd have heard of, and in the very least, he could probably ask a colleague.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 55162
Location: 56N 3W

PostPosted: Sun Mar 16, 2025 1:37 pm    Post subject: Reply with quote

leyvi,

The line you want to drop is at
Code:
/var/tmp/portage/app-editors/wxhexeditor-0.24-r3/work/wxHexEditor # grep -R "Rahman ve Rahim"
src/HexEditor.cpp:   printf("Rahman ve Rahim olan Allah'ın adıyla.\n");


With some context it reads
Code:
        ComparatorHexEditor=NULL;
        // Here, code praying to the GOD for protecting our open file from wxHexEditor's bugs and other things.
        // This is really crucial step! Be adviced to not remove it, even if you don't believer.
        printf("Rahman ve Rahim olan Allah'ın adıyla.\n");
        myfile = NULL;


Your patch is
Code:
# diff  -c3 src/HexEditor.cpp_org src/HexEditor.cpp
*** a/src/HexEditor.cpp_org   2025-03-16 13:20:08.051611894 +0000
--- b/src/HexEditor.cpp   2025-03-16 13:21:53.275837010 +0000
***************
*** 42,50 ****
     tagpanel(tagpanel_),
     dasmpanel(dasmpanel_) {
     ComparatorHexEditor=NULL;
-    // Here, code praying to the GOD for protecting our open file from wxHexEditor's bugs and other things.
-    // This is really crucial step! Be adviced to not remove it, even if you don't believer.
-    printf("Rahman ve Rahim olan Allah'ın adıyla.\n");
     myfile = NULL;
  #ifndef DO_NOT_USE_THREAD_FOR_SCROLL
     myscrollthread = NULL;
--- 42,47 ----


From the comment, its unlikely the patch would be accepted upstream
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.


Last edited by NeddySeagoon on Sun Mar 16, 2025 1:40 pm; edited 1 time in total
Back to top
View user's profile Send private message
sam_
Developer
Developer


Joined: 14 Aug 2020
Posts: 2271

PostPosted: Sun Mar 16, 2025 1:39 pm    Post subject: Reply with quote

leyvi wrote:
Quote:
I don't know where the requirement came from.
It was in the requirement specification, so the customer paid for it and got it.
Huh, interesting. I have a friend who works at one of Google's middle-eastern offices. I'll ask him if he knows about any regulations like this, religious or otherwise, as this seems like something he'd have heard of, and in the very least, he could probably ask a colleague.


It doesn't have to be a legal requirement. It could well have been a requirement from a customer, or something cultural, or ...

It may well have been even a customer's requirement because of the expectations of their users.
Back to top
View user's profile Send private message
sam_
Developer
Developer


Joined: 14 Aug 2020
Posts: 2271

PostPosted: Sun Mar 16, 2025 1:47 pm    Post subject: Reply with quote

leyvi wrote:
Quote:
In other words, you want to change free software to not-so-free software?
Pardon me, but what exactly about pushing one's religion on others is free?

Quote:
By the way, free software allows you to modify the source code. As long as you do not violate the license you can modify ("improve") the software and redistribute it.
I'm not going to go through the trouble of forking a project just to patch out one line of code.

Quote:
Or you open a bug report upstream.
Yeah... that's kind of what this whole thread is about. I'm simply not sure if this qualifies as a bug, and I want to confirm before I go bother the developers. I do believe that this is a bug, but I want to know if I'm just biased.


As Neddy suggests, it's not quite forking to put a patch in /etc/portage/patches. Anyway, no, I don't think it's clearly a bug, and I don't think you should bother the developers about it. They know it's there, they want it there. Their software is a gift to the world. They've made it as they wish, including this message which is important to them. But you don't have to use it. You have the freedom to patch it out if you wish, but whether it's polite or reasonable to ask them to remove this is another question entirely.

I would not personally write such a message and I think I'd prefer it not be there, but I also think it's wrong to ask them to change it with the rationale given here.

If you want to make the argument based on the lack of friendliness of the error(?) message, that might be more reasonable though. See https://yvoloshin.github.io/php/2018/01/20/why-does-php-speak-hebrew/.
Back to top
View user's profile Send private message
leyvi
Guru
Guru


Joined: 08 Sep 2023
Posts: 308

PostPosted: Sun Mar 16, 2025 2:17 pm    Post subject: Reply with quote

Hey sam_.
While the example you provided isn't quite the same situation (being related to language, not religion) I would say that the solution is to just not use any language besides English in code, as it is considered bad practice. Any comments, symbols etc written in Hebrew should have been commented out, and left there as a testament to the developer's hard work. Then they should have been replaced with more accessible options.

I actually asked about it just now.
Many middle-eastern religions write something like this at the top of most documents, signs, billboards, etc.
Muslims write "In the name of Allah, the Most Gracious, the Most Merciful.", and Jews write "With the help of heaven.", and there are others, too.
I've just never seen it in software before.

With this added information, I've changed my opinion:
Either this kind of message should be off by default at build time;
Or it should be based on locale/user-preference/setting.
So, maybe for someone with an Israeli locale, this message should be set to בס"ד, while for a Turk, it should be Rahman ve Rahim olan Allah'ın adıyla, etc depending on where you live.
I'm sure many different cultures and religions have their own versions.
But I think it's wrong to force someone to observe someone else's customs.

Quote:
Anyway, no, I don't think it's clearly a bug, and I don't think you should bother the developers about it. They know it's there, they want it there. Their software is a gift to the world. They've made it as they wish, including this message which is important to them.
I agree. Regardless of whatever changes are made to the software, I definitely think this should be left as a comment in the code, as a monument to the developer.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 55162
Location: 56N 3W

PostPosted: Sun Mar 16, 2025 2:28 pm    Post subject: Reply with quote

leyvi,

It's left as an exercise for the reader to make a new patch :)
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
sam_
Developer
Developer


Joined: 14 Aug 2020
Posts: 2271

PostPosted: Sun Mar 16, 2025 2:43 pm    Post subject: Reply with quote

leyvi wrote:
Hey sam_.
While the example you provided isn't quite the same situation (being related to language, not religion) I would say that the solution is to just not use any language besides English in code, as it is considered bad practice. Any comments, symbols etc written in Hebrew should have been commented out, and left there as a testament to the developer's hard work. Then they should have been replaced with more accessible options.


I understand. I was giving it as an example of an unfriendly error message if you wanted to pursue that angle, because I don't think making an argument against religious messages is a reasonable one to take to an upstream (see the rest of my earlier post).

leyvi wrote:

[...]
With this added information, I've changed my opinion:
Either this kind of message should be off by default at build time;
Or it should be based on locale/user-preference/setting.
So, maybe for someone with an Israeli locale, this message should be set to בס"ד, while for a Turk, it should be Rahman ve Rahim olan Allah'ın adıyla, etc depending on where you live.
I'm sure many different cultures and religions have their own versions.


I find this one quite an interesting angle on it and I suspect they may find that localisation perspective persuasive.
Back to top
View user's profile Send private message
sMueggli
Guru
Guru


Joined: 03 Sep 2022
Posts: 579

PostPosted: Sun Mar 16, 2025 4:25 pm    Post subject: Reply with quote

leyvi wrote:
Quote:
In other words, you want to change free software to not-so-free software?
Pardon me, but what exactly about pushing one's religion on others is free?


I hope you're not missing the irony here: You push your opinion over others.

But you do not seem to understand what "free software" means. The FSF defines free software at https://www.gnu.org/philosophy/free-sw.html.en:

Quote:
A program is free software if the program's users have the four essential freedoms: [1]

The freedom to run the program as you wish, for any purpose (freedom 0).
The freedom to study how the program works, and change it so it does your computing as you wish (freedom 1). Access to the source code is a precondition for this.
The freedom to redistribute copies so you can help others (freedom 2).
The freedom to distribute copies of your modified versions to others (freedom 3). By doing this you can give the whole community a chance to benefit from your changes. Access to the source code is a precondition for this.


Freedom 0 allows you to run the program "as you wish". And implicitly it means if you do not wish you are not forced to run the program. That is also a kind of freedom.
Freedom 1 allows you to patch the program to your liking. And freedom 3 allows you to distribute the changed program.

And that is all, what free software means. It luckily does not mean that software "should be inclusive". In contrast to the meaning of the word, ‘inclusive’ very often means the opposite.
Back to top
View user's profile Send private message
leyvi
Guru
Guru


Joined: 08 Sep 2023
Posts: 308

PostPosted: Sun Mar 16, 2025 4:36 pm    Post subject: Reply with quote

Dear sMueggli, in the time you spent writing your refutation of my opinion, the conversation has moved on. I urge you to catch up.
Back to top
View user's profile Send private message
Hu
Administrator
Administrator


Joined: 06 Mar 2007
Posts: 23326

PostPosted: Sun Mar 16, 2025 4:56 pm    Post subject: Reply with quote

There are newer posts, but I don't see anyone who directly responded to your point in the way that sMueggli did. Thus, that post is at least not a duplicate, and I thought it was an interesting take on software freedom. I see nothing wrong with that post, particularly since sMueggli was responding to your response to his earlier response, so we cannot even say that he interjected himself into an unrelated and finished conversation. As I read the timestamps, sMueggli's response comes only a little over 4 hours after the post it answers, which is relatively rapid for an asynchronous web forum.
Back to top
View user's profile Send private message
GDH-gentoo
Veteran
Veteran


Joined: 20 Jul 2019
Posts: 1852
Location: South America

PostPosted: Sun Mar 16, 2025 4:56 pm    Post subject: Reply with quote

Oh my God... pun intended

The software's author doesn't seem very active these days; you might try creating an issue in upstream's repository with a convincing rationale, but I expect it to sit there forever without progress, or to start an unproductive flame war.

Using /etc/portage/patches looks like the best option if that message annoys you; the location of the code that prints it has already been identified for you.
_________________
NeddySeagoon wrote:
I'm not a witch, I'm a retired electronics engineer :)
Ionen wrote:
As a packager I just don't want things to get messier with weird build systems and multiple toolchains requirements though :)
Back to top
View user's profile Send private message
pietinger
Moderator
Moderator


Joined: 17 Oct 2006
Posts: 5611
Location: Bavaria

PostPosted: Sun Mar 16, 2025 5:11 pm    Post subject: Reply with quote

I find the question - should or may there be a religious statement in a program - very interesting.

I have briefly modified it (specifically) to: This program was created in the best country in the world ... in my beloved *!*-land.

As a programmer, am I allowed to display this in the program I have created?

I would answer this question in the affirmative.

Is this output pleasing to other people in other countries?

I would say no. Why is it not pleasing? Because by implication it means that all other countries are shit ... Well, at least worse.


I am averse to all people who think that THEIR opinion is the only right and true one. I find that pretentious, arrogant and presumptuous.


What could I do about it?

If it's closed software, I would strongly consider buying something like that ... I'd rather buy a competitor's product without this nonsense.

But if it is OpenSource, I would patch out the nonsense immediately and make a fork of it. Then I would offer this fork to the world ... with the subtle hint: This is the original XYZ program but without the arrogant edition of the original programmer ... the world can then decide what it prefers. And yes, if all people from the country *!* prefer the original, then that's their business, which I'm not interested in. But I don't want to have to read that statement. (And no, an issue that depends on which country I live in doesn't make it any better).
_________________
https://wiki.gentoo.org/wiki/User:Pietinger
Back to top
View user's profile Send private message
leyvi
Guru
Guru


Joined: 08 Sep 2023
Posts: 308

PostPosted: Sun Mar 16, 2025 5:40 pm    Post subject: Reply with quote

I am glad to see that my inquiry has sparked such an interesting debate;
I am even more glad to see that everyone here is being mature about said debate, as this is not commonplace on the internet these days :)

I would first and foremost like to apologize in advance of anything I say: today is a national holiday where I live, and as such, I am quite intoxicated :wink: Please excuse me for any lack of clarity with my writings.

While drinking with friends, the following occurred to me:
If we assume, for the sake of debate, that messages like בס"ד and "Rahman ve Rahim olan Allah'ın adıyla." are to be considered something that should be locale-specific, then a few new questions have now arisen, namely:
  • Shouldn't this be implemented system-wide? That is, should (in my case) setting my locale to `he_IL` set a string somewhere to בס"ד, which can be printed by every application that wishes to thank God in some way or form? (and so on and so forth for every region/language combination)
  • What if the user wants a different message printed? Example: a Muslim Israeli. I would assume that they might not want בס"ד printed everywhere. So maybe some sort of environment variable could provide an override for the default value of the aforementioned string, so that it can be customized by the user, according to their religious and cultural beliefs?
I don't actually know how locales work under the hood, so maybe someone can provide an article? Anyway, it's interesting to think about.

Also:
pietinger wrote:
I find the question - should or may there be a religious statement in a program - very interesting.

I have briefly modified it (specifically) to: This program was created in the best country in the world ... in my beloved *!*-land.

As a programmer, am I allowed to display this in the program I have created?

I would answer this question in the affirmative.

Is this output pleasing to other people in other countries?

I would say no. Why is it not pleasing? Because by implication it means that all other countries are shit ... Well, at least worse.


I am averse to all people who think that THEIR opinion is the only right and true one. I find that pretentious, arrogant and presumptuous.


What could I do about it?

If it's closed software, I would strongly consider buying something like that ... I'd rather buy a competitor's product without this nonsense.

But if it is OpenSource, I would patch out the nonsense immediately and make a fork of it. Then I would offer this fork to the world ... with the subtle hint: This is the original XYZ program but without the arrogant edition of the original programmer ... the world can then decide what it prefers. And yes, if all people from the country *!* prefer the original, then that's their business, which I'm not interested in. But I don't want to have to read that statement. (And no, an issue that depends on which country I live in doesn't make it any better).
I definitely agree with you. However, this does not seem to be popular here.

Last edited by leyvi on Sun Mar 16, 2025 5:44 pm; edited 1 time in total
Back to top
View user's profile Send private message
leyvi
Guru
Guru


Joined: 08 Sep 2023
Posts: 308

PostPosted: Sun Mar 16, 2025 5:44 pm    Post subject: Reply with quote

Hu wrote:
There are newer posts, but I don't see anyone who directly responded to your point in the way that sMueggli did. Thus, that post is at least not a duplicate, and I thought it was an interesting take on software freedom. I see nothing wrong with that post, particularly since sMueggli was responding to your response to his earlier response, so we cannot even say that he interjected himself into an unrelated and finished conversation. As I read the timestamps, sMueggli's response comes only a little over 4 hours after the post it answers, which is relatively rapid for an asynchronous web forum.
I also do not see any problem with what he said. However, the conversation has moved on since I wrote that message, without a doubt. I was simply expressing my awareness of this fact.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 55162
Location: 56N 3W

PostPosted: Sun Mar 16, 2025 5:55 pm    Post subject: Reply with quote

leyvi,

How would you pander to atheists and agnostics?

Atheists may want to suppress religious messages completely
Agnostics may tolerate a few .

Locales don't cover them.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
leyvi
Guru
Guru


Joined: 08 Sep 2023
Posts: 308

PostPosted: Sun Mar 16, 2025 6:02 pm    Post subject: Reply with quote

NeddySeagoon wrote:
leyvi,

How would you pander to atheists and agnostics?

Atheists may want to suppress religious messages completely
Agnostics may tolerate a few .

Locales don't cover them.
You make a very good point. Perhaps the default message for each locale could be set to something that is tolerable to everyone by default, or maybe the whole standard for localization needs to be revamped, to enable people of different religions/religious statuses/cultures/etc to have a suitable message printed? I don't know what I think the answer should be at this time, but it is definitely a fun problem to think about.
Back to top
View user's profile Send private message
Banana
Moderator
Moderator


Joined: 21 May 2004
Posts: 1981
Location: Germany

PostPosted: Mon Mar 17, 2025 9:22 am    Post subject: Reply with quote

It is fun to think about, but there is no absolute answer to that.

The world is not black and white, it is coloful and so are the opinions of each and everyone.

One "answer" to this rainbow could be: Be respectful to each other
_________________
Forum Guidelines

PFL - Portage file list - find which package a file or command belongs to.
My delta-labs.org snippets do expire
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo Chat All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum