-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Better error message when URL is an empty string #2730
Comments
This issue is also being tracked on Linear. We use Linear to manage our development process, but we keep the conversations on Github. LINEAR-ID: 76fbcb73-8707-4c4e-a9b0-d45fce9a2b58 |
This issue was marked as stale because it didn't have any activity in the last 30 days. If you think it's still relevant, please leave a comment indicating so. Otherwise, it will be closed in 7 days. |
This issue was closed because it has been stalled for 7 days with no activity. |
Hi @fvictorio , Can you please assign this issue to me? Thanks. |
Done! Let me know if you need help. |
Hi @fvictorio , I have made a pull request for it. You can have a look. Thanks. |
#3825 better message when url is an empty string. |
Hello @fvictorio, I'm looking at the list of good first issues and am interested in taking a stab at this issue if its okay. P.S. your evm-puzzles were really helpful in making me understand evm at a practical level :) |
Hey @kshyun28, sorry for not responding sooner and thanks for the PR!
That's a great point. Do you want to send a separate PR improving that warning? Ideally we would change the environment variables names too, but that will be a huge change and maybe it's not worth it
Super glad to read that 😄 |
I'm okay with sending an additional PR to improve the warning message. Currently I'm thinking I'd also suggest to add a section in CONTRIBUTING.md on configuring environment variables for tests as needed. A note/hint could work, since I only knew that environment variables are needed after attempting to run the test. Might have to review if steps to configure env variables are the same in windows, but CONTRIBUTING.md ## Testing
All tests are written using [mocha](https://mochajs.org) and [chai](https://www.chaijs.com).
### Environment variables
Some tests require having `INFURA_URL` and `ALCHEMY_URL` configured.
You can set them in your terminal using `export ALCHEMY_URL=value INFURA_URL=value`.
### Per-package
You can run a package's tests by executing `yarn test` inside its folder.
### Entire project
You can run all the tests at once by running `yarn test` from the root folder. |
An empty string in the forking URL or in a network URL produces this error message:
We should handle this as a special case and print a better error message. Also, this is not caught during config validation; instead, it happens the first time a request is sent.
This comment also seems to suggest that an "only absolute URLs are supported" message can be shown when an empty string is used; maybe that depends on the OS or it happens in other scenarios.
The text was updated successfully, but these errors were encountered: