Skip to content

Commit eb3901a

Browse files
committed
update invidious instances
1 parent c0ceb5c commit eb3901a

2 files changed

Lines changed: 33 additions & 16 deletions

File tree

extractor/src/main/java/org/schabi/newpipe/extractor/services/youtube/YoutubeParsingHelper.java

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -105,13 +105,29 @@ public static boolean isHooktubeURL(URL url) {
105105

106106
public static boolean isInvidioURL(URL url) {
107107
String host = url.getHost();
108-
return host.equalsIgnoreCase("invidio.us") || host.equalsIgnoreCase("dev.invidio.us") || host.equalsIgnoreCase("www.invidio.us") || host.equalsIgnoreCase("invidious.snopyta.org") || host.equalsIgnoreCase("de.invidious.snopyta.org") || host.equalsIgnoreCase("fi.invidious.snopyta.org") || host.equalsIgnoreCase("vid.wxzm.sx") || host.equalsIgnoreCase("invidious.kabi.tk") || host.equalsIgnoreCase("invidiou.sh") || host.equalsIgnoreCase("www.invidiou.sh") || host.equalsIgnoreCase("no.invidiou.sh") || host.equalsIgnoreCase("invidious.enkirton.net") || host.equalsIgnoreCase("tube.poal.co") || host.equalsIgnoreCase("invidious.13ad.de") || host.equalsIgnoreCase("yt.elukerio.org");
108+
return host.equalsIgnoreCase("invidio.us")
109+
|| host.equalsIgnoreCase("dev.invidio.us")
110+
|| host.equalsIgnoreCase("www.invidio.us")
111+
|| host.equalsIgnoreCase("invidious.snopyta.org")
112+
|| host.equalsIgnoreCase("fi.invidious.snopyta.org")
113+
|| host.equalsIgnoreCase("yewtu.be")
114+
|| host.equalsIgnoreCase("invidious.ggc-project.de")
115+
|| host.equalsIgnoreCase("yt.maisputain.ovh")
116+
|| host.equalsIgnoreCase("invidious.13ad.de")
117+
|| host.equalsIgnoreCase("invidious.toot.koeln")
118+
|| host.equalsIgnoreCase("invidious.fdn.fr")
119+
|| host.equalsIgnoreCase("watch.nettohikari.com")
120+
|| host.equalsIgnoreCase("invidious.snwmds.net")
121+
|| host.equalsIgnoreCase("invidious.snwmds.org")
122+
|| host.equalsIgnoreCase("invidious.snwmds.com")
123+
|| host.equalsIgnoreCase("invidious.sunsetravens.com")
124+
|| host.equalsIgnoreCase("invidious.gachirangers.com");
109125
}
110126

111127
/**
112-
* Parses the duration string of the video expecting ":" or "." as seperators
128+
* Parses the duration string of the video expecting ":" or "." as separators
113129
* @return the duration in seconds
114-
* @throws ParsingException when more than 3 seperators are found
130+
* @throws ParsingException when more than 3 separators are found
115131
*/
116132
public static int parseDurationString(final String input)
117133
throws ParsingException, NumberFormatException {

extractor/src/main/java/org/schabi/newpipe/extractor/services/youtube/linkHandler/YoutubeStreamLinkHandlerFactory.java

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,19 @@
11
package org.schabi.newpipe.extractor.services.youtube.linkHandler;
22

3-
import static org.schabi.newpipe.extractor.services.youtube.YoutubeParsingHelper.BASE_YOUTUBE_INTENT_URL;
4-
53
import org.schabi.newpipe.extractor.exceptions.FoundAdException;
64
import org.schabi.newpipe.extractor.exceptions.ParsingException;
75
import org.schabi.newpipe.extractor.linkhandler.LinkHandler;
86
import org.schabi.newpipe.extractor.linkhandler.LinkHandlerFactory;
97
import org.schabi.newpipe.extractor.services.youtube.YoutubeParsingHelper;
108
import org.schabi.newpipe.extractor.utils.Utils;
119

10+
import javax.annotation.Nullable;
1211
import java.net.MalformedURLException;
1312
import java.net.URI;
1413
import java.net.URISyntaxException;
1514
import java.net.URL;
1615

17-
import javax.annotation.Nullable;
16+
import static org.schabi.newpipe.extractor.services.youtube.YoutubeParsingHelper.BASE_YOUTUBE_INTENT_URL;
1817

1918
/*
2019
* Created by Christian Schabesberger on 02.02.16.
@@ -61,7 +60,7 @@ private static String assertIsId(@Nullable String id) throws ParsingException {
6160

6261
@Override
6362
public LinkHandler fromUrl(String url) throws ParsingException {
64-
if (url.startsWith(BASE_YOUTUBE_INTENT_URL)){
63+
if (url.startsWith(BASE_YOUTUBE_INTENT_URL)) {
6564
return super.fromUrl(url, BASE_YOUTUBE_INTENT_URL);
6665
} else {
6766
return super.fromUrl(url);
@@ -191,17 +190,19 @@ public String getId(String urlString) throws ParsingException, IllegalArgumentEx
191190
case "DEV.INVIDIO.US":
192191
case "INVIDIO.US":
193192
case "INVIDIOUS.SNOPYTA.ORG":
194-
case "DE.INVIDIOUS.SNOPYTA.ORG":
195193
case "FI.INVIDIOUS.SNOPYTA.ORG":
196-
case "VID.WXZM.SX":
197-
case "INVIDIOUS.KABI.TK":
198-
case "INVIDIOU.SH":
199-
case "WWW.INVIDIOU.SH":
200-
case "NO.INVIDIOU.SH":
201-
case "INVIDIOUS.ENKIRTON.NET":
202-
case "TUBE.POAL.CO":
194+
case "YEWTU.BE":
195+
case "INVIDIOUS.GGC-PROJECT.DE":
196+
case "YT.MAISPUTAIN.OVH":
203197
case "INVIDIOUS.13AD.DE":
204-
case "YT.ELUKERIO.ORG": { // code-block for hooktube.com and Invidious instances
198+
case "INVIDIOUS.TOOT.KOELN":
199+
case "INVIDIOUS.FDN.FR":
200+
case "WATCH.NETTOHIKARI.COM":
201+
case "INVIDIOUS.SNWMDS.NET":
202+
case "INVIDIOUS.SNWMDS.ORG":
203+
case "INVIDIOUS.SNWMDS.COM":
204+
case "INVIDIOUS.SUNSETRAVENS.COM":
205+
case "INVIDIOUS.GACHIRANGERS.COM": { // code-block for hooktube.com and Invidious instances
205206
if (path.equals("watch")) {
206207
String viewQueryValue = Utils.getQueryValue(url, "v");
207208
if (viewQueryValue != null) {

0 commit comments

Comments
 (0)