GithubHelp home page GithubHelp logo

Comments (6)

cthulahoops avatar cthulahoops commented on August 12, 2024

Thank you!

Yeah, this is a bit tricky - but I think I can do something that mostly works. So long as the pet server doesn't restart then the next time there's an event related to a user I can update all the pet names. So, if the user is active on Virtual RC there's no problem, I can update the pets.

The problem is that if user doesn't visit Virtual RC before the pet server restarts then on restart the pets won't recognise their owner. (There's a related problem if we have two Recursers with the same name.) This is just a limitation of the design, and I'd need to add server state to fix it.

I don't think polling helps, because I don't think the API tells us anything about offline users.

Have all the pets been abandoned already, or are there any I should rename manually? (Due to a quirk of Virtual RC, the abandonment message is only visible to anyone who's online at the time, anyone who joins later can't see it because the sender no longer exists.)

from rocket.

ntietz avatar ntietz commented on August 12, 2024

Ahh sorry for the faulty suggestion of polling! Thatโ€™s what I get for guessing without understanding the code haha.

Thanks for looking into this!

I already abandoned the old pets, on a lookout for a new penguin and crab haha.

from rocket.

cthulahoops avatar cthulahoops commented on August 12, 2024

Looking into code it looks like it's better than I remembered! Ownership is tracked based on bot_json["message"]["mentioned_entity_ids"][0], so there's no trouble tracking owners across name changes and restarts! It still won't update until the next time the owner visits Virtual RC, but that's not too bad I think.

I hope the genie is kind to you!

from rocket.

cthulahoops avatar cthulahoops commented on August 12, 2024

Okay, this should work. Now, I wonder if there's any way to try it without changing my name! ๐Ÿ˜ฌ

Do you know how long name changes take to propagate through? Can I reasonably change my name on RC and back again without confusing too many people?

from rocket.

ntietz avatar ntietz commented on August 12, 2024

Iโ€™m not sure! I think it was pretty near instantaneous for me. If you want a minimally confusing name change, putting an extra โ€œlโ€ in your last name may be not really noticed.

from rocket.

cthulahoops avatar cthulahoops commented on August 12, 2024

Good suggestion! Though, I do feel there's some sort of "testing is my middle name" joke to made. ๐Ÿ˜€

Have handled some more edge cases, and think I'm ready to go live with this. Thank you for the bug report, and sorry about the bad name handling.

from rocket.

Related Issues (5)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.