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.

Planning for missing regexMatch for urls

See original GitHub issue

I noticed that there were no public methods for me to create regex matchers, even though the FieldMatcher has some code to support regex. So obviously it is not implemented yet.

Is there any plan when to put it in?

I am interested because i want to use hoverfly delays which only accepts exact matches and (go) regexes. The only way to use delays with hoverfly-java is with exact matches. I have dynamic urls in my usecase.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
mqzrycommented, Apr 15, 2018

Good to see that you are working on this. These three functions will cover a high percentage of usecases.

My usecase is comma separated list of integers in a url and I want to match it without caring about the order. So “a,b,c” and “b,c,a” should both match. So I would want to write the regex ^(a|b|c)(,(a|b|c)){2}$. My case is very specific, so a predefined one would not make a lot of sense. Therefore I would really like the goRegexMatcher for my case 😃

0reactions
mqzrycommented, Apr 17, 2018

Thanks! Incredibly fast response and resolution, 👍

Read more comments on GitHub >

github_iconTop Results From Across the Web

What is the best regular expression to check if a string ...
The first to get the regexp to match IP address URLs correctly in PHP (v5.2.10) with the preg_match() function. I had to add...
Read more >
Liberal, Accurate Regex Pattern for Matching Web URLs
The regex patterns in this gist are intended only to match web URLs -- http, ... Your example is missing subdomains with dashes...
Read more >
9 Regular Expressions You Should Know - Code - Envato Tuts+
Regular expressions (also known as regex) are a concise and flexible way to search and replace within text strings. With a regular expression, ......
Read more >
Regular Expression Matching Can Be Simple And Fast
The Plan 9 regular expression library incorporates Unicode by running an NFA with a single Unicode character as the input character for each...
Read more >
URLPattern brings routing to the web platform
At its heart, routing involves taking a URL, applying some pattern ... and JavaScript developers can use modules like path-to-regexp or ...
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