# Problemen met het gebruik van het disqus.rb importscript

**URL:** <https://meta.discourse.org/t/issues-with-using-disqus-rb-import-script/169984>\
**Category:** Product Support\
**Created:** [12 november 2020 om 21:10 UTC](https://meta.discourse.org/t/issues-with-using-disqus-rb-import-script/169984 "2020-11-12T21:10:33Z")\
**Posts on this page:** 1\
**Showing post:** 10

<div class="post-metadata">

**Author:** ![jbrains](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jbrains/32/208183_2.png) [@jbrains](https://meta.discourse.org/u/jbrains)\
**Post date:** [3 februari 2021 om 01:14 UTC](https://meta.discourse.org/t/issues-with-using-disqus-rb-import-script/169984/10 "2021-02-03T01:14:22Z")

</div>

I made it farther, but now something _new_ is `nil`. I’ll hunt and poke, but I would appreciate help, and I commit to contribute my discoveries back.

I applied the patches in this thread, and then became stuck here when importing topics:

```bash
Traceback (most recent call last):
        5: from script/import_scripts/disqus.rb:236:in `<main>'
        4: from /var/www/discourse/script/import_scripts/base.rb:47:in `perform'
        3: from script/import_scripts/disqus.rb:29:in `execute'
        2: from script/import_scripts/disqus.rb:70:in `import_topics_and_posts'
        1: from script/import_scripts/disqus.rb:70:in `each'
script/import_scripts/disqus.rb:84:in `block in import_topics_and_posts': undefined method `topic' for nil:NilClass (NoMethodError)

```

OK. I don’t think I’m up for this tonight.

I’ve been able to figure out that `find_remote()` returns `nil` for a comment and I have no idea what this means nor why it matters. I suspect that it has something to do with HTTP/HTTPS, so out of desperation, I’m going to just change all the URLs from HTTP to HTTPS in my Disqus export files and hope for the best.

Advice is _so_ welcome.

[UPDATE!]

My current conjecture: if the Disqus comment is on a post whose link doesn’t have a Disqus thread any more (such as a tumblr blog from 1853), then this import script dies a horrible death.

By chance, if I’m right, could someone who knows the code better than I suggest how to patch the importer so that it happily skips such threads and comments?

And if I’m not right, well, then I’ll probably reply to this with more discoveries. 😛

[UPDATE!]

I deleted, by hand, all the comments from threads with links that no longer go anywhere. This appears to have sufficed to import all my Disqus comments. I believe, therefore, it would be nice if someone who can read the code for this script could patch it accordingly. I don’t think I can do it.

I hope, at least, that these words help the next poor soul who follows me. Good luck.

Peace.

---

_[View the full topic](https://meta.discourse.org/t/issues-with-using-disqus-rb-import-script/169984)._
