question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Latest version breaks library

See original GitHub issue

Describe the bug When using the latest version I get the following error: TypeError: o.sockets.subscribe is not a function

This is caused when I try to run this.sockets.subscribe('name', ...)

Expected behavior The app is supposed to access the sockets via this.sockets. as it did in previous version

Desktop (please complete the following information):

  • OS: Linux
  • Browser Chrome, Firefox

Additional context Reverting to previous version 3.0.7 solved the issue.

I could not pinpoint the issue in source code due to … minimization?

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:13
  • Comments:15

github_iconTop GitHub Comments

19reactions
goliafrscommented, May 8, 2020

Until the bug is fixed, everyone who has a similar problem and don’t wants to change own code - can install the version 3.0.5.

npm i vue-socket.io@3.0.5 - in dependencies

And lock version in packege.json: "vue-socket.io": "3.0.5"

I have the same problem but this version is not broken yet. And I don’t understand why to make such changes in the patch version. It’s breaking changes. They should be at least in a minor, and preferably a major version with explanations.

Problem started from this changes.

9reactions
kovinetcommented, May 5, 2020

Since last version component methods in sockets: don’t get triggered anymore. I don’t get any error, but sample methods (connect, customEmit) from example below never get triggered:

    sockets: {
        connect: function () {
            console.log('socket connected')
        },
        customEmit: function (data) {
            console.log('this method was fired by the socket server. eg: io.emit("customEmit", data)')
        }
    },

I think it is related to original issue reported … ? When I downgraded to 3.0.7 is started working again.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Breaking changes and .NET libraries - Microsoft Learn
A binary breaking change happens when you change the public API of your library, so assemblies compiled against older versions of your library...
Read more >
[AskJS] How do you release libraries updates with breaking ...
I'm working on a new version of a npm library and the v2 changelog is huge, with a lot of breaking changes (removed...
Read more >
Why do library developers deliberately break existing code?
Major version updates tend to break stuff. That's why they're major version updates. They are the biggest scope on how a library can...
Read more >
What will I break if I install a newer version of a library?
I'm a Kerbal Space Program player, trying to use a particular game mod called Principia to better model multi-body and non-uniform body orbits....
Read more >
Dev server breaks library entry type #4469 - GitHub
Bug report We have an app with two entries - the main one for the app, and a second entry for a library....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found