Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .idea/codeStyles/Project.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
public class ArXivIdentifier extends EprintIdentifier {
private static final Logger LOGGER = LoggerFactory.getLogger(ArXivIdentifier.class);

private static final String ARXIV_PREFIX = "http(s)?://arxiv.org/(abs|pdf)/|arxiv|arXiv";
private static final String ARXIV_PREFIX = "http(s)?://arxiv.org/(abs|pdf|html)/|arxiv|arXiv";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure about alphabetical ordering?! I changed it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually that's my first contribution , i tried my best

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You did very well. You had a quick reaction time and kept communicating with the maintainers.
If something is addressed or modified by us, its mostly something simple we fix quickly in the web interface to get the PR ready to be merged. Nothing to be concerned of.

We would love to see more from you. Thank you!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just make sure you carefully read the contribution guidelines and stay true in what you code and what you write.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sure .

private final String identifier;
private final String classification;
private final String version;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -171,4 +171,25 @@ void constructCorrectURLForEprint() throws URISyntaxException {
Optional<ArXivIdentifier> parsed = ArXivIdentifier.parse("0706.0001v1");
assertEquals(Optional.of(new URI("https://arxiv.org/abs/0706.0001v1")), parsed.get().getExternalURI());
}

@Test
void parseHtmlUrl() {
Optional<ArXivIdentifier> parsed = ArXivIdentifier.parse("https://arxiv.org/html/2511.01348v2");

assertEquals(Optional.of(new ArXivIdentifier("2511.01348", "2", "")), parsed);
}

@Test
void parseHtmlUrlWithoutVersion() {
Optional<ArXivIdentifier> parsed = ArXivIdentifier.parse("https://arxiv.org/html/2511.01348");

assertEquals(Optional.of(new ArXivIdentifier("2511.01348", "", "")), parsed);
}

@Test
void parseHttpHtmlUrl() {
Optional<ArXivIdentifier> parsed = ArXivIdentifier.parse("http://arxiv.org/html/1502.05795v1");

assertEquals(Optional.of(new ArXivIdentifier("1502.05795", "1", "")), parsed);
}
}
Loading