Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Client does not add file if tracker is set to false #434

Closed
VoR0220 opened this issue Sep 16, 2015 · 2 comments
Closed

Client does not add file if tracker is set to false #434

VoR0220 opened this issue Sep 16, 2015 · 2 comments
Labels

Comments

@VoR0220
Copy link

@VoR0220 VoR0220 commented Sep 16, 2015

Any help again is welcome. Works when tracker is set to true. But when set to false, nothing appends.

client defined here:

self.client = new WebTorrent({tracker: false, dht: true, torrentPort: addr});
    self.client.add(self.file, function(torrent) {
      // Got torrent metadata!
      //torrent.addPeer(addr);
      var file = torrent.files[0]; // Let's say the first file is an audio file...

      console.log('Client is downloading:', torrent.infoHash);
      console.log('Client is listening for:', addr);

      torrent.files.forEach(function(file) {
        // Display the file by appending it to the DOM. Supports video, audio, images, and
        // more. Specify a container element (CSS selector or reference to DOM node).
        var playerTarget = document.querySelector('.track-details');

        file.appendTo(playerTarget, function(err, elem) {
          if (err) throw err; //file failed to download or display in DOM
          console.log('New DOM node with the content', elem);
        });
      });
    });
@feross

This comment has been minimized.

Copy link
Member

@feross feross commented Feb 28, 2016

@VoR0220 I assume this is in the browser?

Right now, WebTorrent in the browser requires the use of trackers. There is no DHT. So this outcome is not surprising to me.

@feross feross closed this Feb 28, 2016
@feross feross added the question label Feb 28, 2016
@lock

This comment has been minimized.

Copy link

@lock lock bot commented May 4, 2018

This thread has been automatically locked because it has not had recent activity. To discuss futher, please open a new issue.

@lock lock bot locked as resolved and limited conversation to collaborators May 4, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.