Manually updating plugins

Discussion in 'Plugin Help' started by LoneDespairYt, Dec 2, 2018.

  1. LoneDespairYt

    LoneDespairYt Spider

    Messages:
    7
    Aside from changing the api on plugin.yml of the plugins, what are the most important things to consider on manually updating plugins and what to do if i keep on getting this type of bugs and thanks

    Enabling ReplaySystem v1.3.0
    2018-12-02 [13:50:30] [Server thread/INFO]: [ReplaySystem] [ReplaySystem] by McpeBooster!
    2018-12-02 [13:50:35] [Server thread/CRITICAL]: ErrorException: "file_get_contents(): php_network_getaddresses: gethostbyname failed. errno=2" (EXCEPTION) in "ReplaySystem-McpeBooster.phar/src/ReplaySystem/ReplaySystem" at line 108
    2018-12-02 [13:50:35] [Server thread/DEBUG]: #0 (): pocketmine\utils\Utils::errorExceptionHandler(integer 2, string file_get_contents(): php_network_getaddresses: gethostbyname failed. errno=2, string phar:///storage/emulated/0/PocketMine-MP/plugins/ReplaySystem-McpeBooster.phar/src/ReplaySystem/ReplaySystem.php, integer 108, array Array())
    2018-12-02 [13:50:35] [Server thread/DEBUG]: #1 ReplaySystem-McpeBooster.phar/src/ReplaySystem/ReplaySystem(108): file_get_contents(string https://raw.githubusercontent.com/McpeBooster/ReplaySystem-McpeBooster/master/plugin.yml, boolean , resource Resource id #1042)
    2018-12-02 [13:50:35] [Server thread/DEBUG]: #2 ReplaySystem-McpeBooster.phar/src/ReplaySystem/ReplaySystem(63): ReplaySystem\ReplaySystem->checkUpdate()
    2018-12-02 [13:50:35] [Server thread/DEBUG]: #3 src/pocketmine/plugin/PluginBase(108): ReplaySystem\ReplaySystem->onEnable()
    2018-12-02 [13:50:35] [Server thread/DEBUG]: #4 src/pocketmine/plugin/PluginManager(566): pocketmine\plugin\PluginBase->setEnabled(boolean 1)
    2018-12-02 [13:50:35] [Server thread/DEBUG]: #5 src/pocketmine/Server(1918): pocketmine\plugin\PluginManager->enablePlugin(ReplaySystem\ReplaySystem object)
    2018-12-02 [13:50:35] [Server thread/DEBUG]: #6 src/pocketmine/Server(1904): pocketmine\Server->enablePlugin(ReplaySystem\ReplaySystem object)
    2018-12-02 [13:50:35] [Server thread/DEBUG]: #7 src/pocketmine/Server(1698): pocketmine\Server->enablePlugins(integer 1)
    2018-12-02 [13:50:35] [Server thread/DEBUG]: #8 src/pocketmine/PocketMine(249): pocketmine\Server->__construct(BaseClassLoader object, pocketmine\utils\MainLogger object, string /storage/emulated/0/PocketMine-MP/, string /storage/emulated/0/PocketMine-MP/plugins/)
    2018-12-02 [13:50:35] [Server thread/DEBUG]: #9 /storage/emulated/0/PocketMine-MP/PocketMine-MP.phar(1): require(string phar:///storage/emulated/0/PocketMine-MP/PocketMine-MP.phar/src/pocketmine/PocketMine.php)
    2018-12-02 [13:50:35] [Server thread/INFO]: Disabling ReplaySystem v1.3.0
     
  2. EdwardHamHam

    EdwardHamHam Skeleton

    Messages:
    913
    GitHub:
    edwardhamham
    Just changing the API number in plugin.yml hardly works, unless you're very lucky and/or it's a very basic plugin. Either way, it's not advised. Take a look at this guide.
     
  3. LoneDespairYt

    LoneDespairYt Spider

    Messages:
    7
    Thanks for help, it would definitely help me,

    I am just curious, why do functions is always certainly changed on every api update?
     
  4. CupidonSauce173

    CupidonSauce173 Zombie

    Messages:
    284
    GitHub:
    cupidonsauce173
    It's more the "library" of pmmp that change, the methods. It change to or fix new issues (blame Mojan) or to add new things or to change the way of certain things works so it's less laggy or messy. What I propose you to do is to look how the plugin is made and to see what was the api, when you will see the api (orginal one) just go in github releases of pmmo and look every changes that it had since now. You will certainly find what are the things on your plugin that changed. :))
     
  5. SOFe

    SOFe Administrator Staff Member PMMP Team Poggit Admin

    Messages:
    1,910
    GitHub:
    sof3
    There are 3 main reasons:
    1. A lot of technical debt in old PocketMine codebase. Blame Shoghi.
    [​IMG]
    The original code did not have a good design and is quite maintainable, and we are working on improving it. It's a massive project, and we can only improve the API bit by bit.
    For example, we figured it was a wrong idea to do PluginTask, and instead, each plugin should have its own scheduler. Indeed, we could add some duct tape to make sure the old plugins are still working, but we don't want new developers to learn the wrong (old) way, so we just forced everyone to change.
    It is a heavy but unnecessary task to keep maintaining so much duct tape and remove them later on. Remember we are a community-driven project where developers work on PocketMine for free, and we don't have that much time and effort to introduce a lot of trouble just to let old plugins work for a few more months. After all, the plugins have to change eventually.
    Also note that we don't force everyone to update; even if a new version is released, we would still add new client version support to them for a few versions (depending on the time). In addition, right now we only do big backward-incompatible changes about twice per year, so it's not that often anymore.
    2. The game is consistently updating. Sometimes old features are no longer available and must be removed. Although Shoghi isn't the only one who decided to add these new features into the game, Blame Shoghi Again.
    [​IMG]
    3. PHP is consistently updating, and we really want to use the new features. For example, the onCommand() function ought to have typehints, but this is only possible until PHP 7. But who decided to use PHP, which is such a poorly-maintained, feature-lacking and future-incompatible language? Blame Shoghi again again.
    [​IMG]

    Conclusion: dktapps good, shoghicp bad

    [​IMG]
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.