Welcome to the Builder Academy

Question Bug in is_name() ?

More
16 May 2024 23:03 - 16 May 2024 23:08 #10394 by Salty
Bug in is_name() ? was created by Salty
This is an odd one and I can't seem to figure it out.  It's present in the 2024 version on github.
Code:
500H 100M 82V > eq <worn on finger>     a leather ring <worn on finger>     a leather ring <worn around neck>   a leather gorget <worn around neck>   a leather gorget

If 'n' is a number, and 'arg' is an argument, when I try to remove/wear n.arg it fails if 'arg' is exactly four (4) characters.
Code:
500H 100M 82V > rem 2.leat You don't seem to be using a ltat. 500H 100M 82V > rem 2.lea You stop using a leather ring. 500H 100M 82V > rem 2.leath          You stop using a leather ring.

In the above example, the n.arg works unless 'arg' is 4 characters long.

Code:
500H 100M 82V > eq You are using: Nothing. 500H 100M 82V > i You are carrying: ( 2) a leather gorget ( 2) a leather ring 500H 100M 82V > wear 2.ring You don't seem to have a rgng. 500H 100M 82V > wear ring You slide a leather ring on to your right ring finger. 500H 100M 82V > wear 3.leat You don't seem to be using a ltat.

While unequipped, same behavior.  

There's only a failure on remove/wear of an n.arg when n>1 and 'arg' is exactly four characters.

This isn't game breaking whatsoever, but you can't "remove 2.ring" or "wear 2.neck"  Ring is the big issue because it's exactly 4 characters.

Any thoughts?  Please advise.

Thanks!
Last edit: 16 May 2024 23:08 by Salty.

Please Log in or Create an account to join the conversation.

More
18 May 2024 12:58 #10395 by thomas
Replied by thomas on topic Bug in is_name() ?
Something is apparently messing up the string when splitting the n. from the name. Your example shows an error using the phrase "you dont seem to have a rgng" and the same for "ltat". This seems like a bug we should be able to fix :)

Please Log in or Create an account to join the conversation.

More
19 May 2024 22:19 - 19 May 2024 22:20 #10396 by thomas
Replied by thomas on topic Bug in is_name() ?
I've tried to reproduce it, with no luck, using the most recent build:
Code:
464H 100M 82V (news) (motd) > eq You are using: <worn on finger>    a leather ring <worn on finger>    a leather ring <worn around neck>  a leather gorget <worn around neck>  a leather gorget 464H 100M 82V (news) (motd) > rem 2.leat You stop using a leather ring.
Anything in particular you are doing here?
Last edit: 19 May 2024 22:20 by thomas.

Please Log in or Create an account to join the conversation.

More
22 May 2024 05:37 #10397 by Salty
Replied by Salty on topic Bug in is_name() ?

I've tried to reproduce it, with no luck, using the most recent build:

Interesting.  

My test build was taken straight from github and compiled on Ubuntu 22.04.4 LTS.  

I spun up a new VM running Ubuntu 22.04.6 LTS, cloned from github, configured and compiled.  The issue remains.  The same issue is present on the clean VM running Debian 12.5

Could it be a library function causing the weirdness?

Please Log in or Create an account to join the conversation.

More
22 May 2024 19:57 - 22 May 2024 19:59 #10398 by thomas
Replied by thomas on topic Bug in is_name() ?
Here's my attempt. Also a raw checkout from github, in a separate directory, just my character
Code:
~/code/5589-bug-in-is-name$ git clone https://github.com/tbamud/tbamud.git Cloning into 'tbamud'... ... ~/code/5589-bug-in-is-name$ cd tbamud/ ~/code/5589-bug-in-is-name/tbamud$ ./configure && cd src && make && cd .. && bin/circle 9091 creating cache ./config.cache checking for less... less ... May 22 21:45:48 2024 :: Entering game loop. May 22 21:45:48 2024 :: No connections.  Going to sleep. Telnet in through another terminal and get this: 500H 100M 82V (news) (motd) > load obj 3082 2 You create a leather gorget. You create a leather gorget. 500H 100M 82V (news) (motd) > load obj 3083 2 You create a leather ring. You create a leather ring. 500H 100M 82V (news) (motd) > wear all You slide a leather ring on to your right ring finger. You slide a leather ring on to your left ring finger. You wear a leather gorget around your neck. You wear a leather gorget around your neck. 500H 100M 82V (news) (motd) > rem 2. leat You don't seem to be using an . 500H 100M 82V (news) (motd) > rem 2.leat You stop using a leather ring.
I am current running on a rather old instance of linux (ubuntu 22.04.1), so that might be the reason:
Code:
$ uname -a Linux thomas-c-ubuntu 6.5.0-35-generic #35~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue May  7 09:00:52 UTC 2 x86_64 x86_64 x86_64 GNU/Linux
I'll try updating to a newer version and try again.
Last edit: 22 May 2024 19:59 by thomas. Reason: formatting

Please Log in or Create an account to join the conversation.

More
23 May 2024 03:58 - 23 May 2024 04:44 #10399 by Salty
Replied by Salty on topic Bug in is_name() ?
Thomas,

I appreciate the help.  I did some more digging.  Looks like it might be a linux kernel issue.  

I notice your ubuntu build is: (issue not present)
Code:
[color=#333333][size=2][font=Roboto][color=#e93f8e]Linux thomas-c-ubuntu 6.5.0-35-generic #35~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue May  7 09:00:52 UTC 2 x86_64 x86_64 x86_64 GNU/Linux[/color][/font][/size][/color]

My gameserver build is: (issue present)
Code:
Linux OMG 5.4.0-155-generic #172-Ubuntu SMP Fri Jul 7 16:10:02 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

ubuntu on wsl2 built as: (issue present)
Code:
Linux ALONE 5.15.146.1-microsoft-standard-WSL2 #1 SMP Thu Jan 11 04:09:03 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux

debian on wsl2 is built as: (issue present)
Code:
Linux ALONE 5.15.146.1-microsoft-standard-WSL2 #1 SMP Thu Jan 11 04:09:03 UTC 2024 x86_64 GNU/Linux

Today, I built a new Ubuntu in virtualbox: (issue not present)
Code:
Linux salty-VirtualBox 6.8.0-31-generic #31-Ubuntu SMP PREEMPT_DYNAMIC Sat Apr 20 00:46:06 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux

The issue is not present in your 6.5.0-35-generic or the 6.8.0-31-generic kernel, but is present in 5.4.0-155-generic and the wsl2 kernels.

edit:
Fresh VM, ubuntu server 24.04 LTS
Code:
Linux utest 6.8.0-31-generic #31-Ubuntu SMP PREEMPT_DYNAMIC Sat Apr 20 00:40:06 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Downloaded my modified MUD from my github, compiled and ran the test again, no issue present.

Interesting stuff.  Seems like it might be the kernel?

Thoughts?
Last edit: 23 May 2024 04:44 by Salty. Reason: Additional Test

Please Log in or Create an account to join the conversation.

Time to create page: 0.197 seconds