
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
issue-reporter
Advanced tools
A lib that generates issue reports for unexcepted errors.
yarn add issue-reporter
const issueReporter = require('issue-reporter')
async function main() {
try {
throw new Error('Some unexcepted error')
} catch (e) {
await issueReporter({
error: e,
user: 'frinyvonnick',
repo: 'issue-reporter',
})
}
}
issue-reporter
's output depends on your environment:
If you terminal supports Hyperlinks it will print a friendly error message with a clickable link that opens a form to create a new issue with a prefilled error report on your project.
If your terminal doesn't support Hyperlinks, issue-reporter
will copy the error report in your clipboard and print an url that opens a new issue on your project so you can directly paste the report on the issue template.
In case of a CI it will print an url that opens a new issue on your project followed by a full report error in markdown you can copy paste in the issue body.
option | description | type | required |
---|---|---|---|
error | An Error instance | Error | required |
user | You GitHub handle | string | required |
repo | The repository name of your project | string | required |
envinfo | A configuration object that is passed down to envinfo | Object | optional |
sections | Custom sections to add in the error report | Array | optional |
formatReport | A function that allows to write your own error report template | function | optional |
issue-reporter
takes an extra option called sections
that let you add information specific to your project. You can add as many sections as you want.
const issueReporter = require('issue-reporter')
async function main() {
try {
throw new Error('Some unexcepted error')
} catch (e) {
await issueReporter({
error: e,
user: 'frinyvonnick',
repo: 'issue-reporter',
sections: [
{
title: "My project specific information",
content: {
version: "1.0.1",
release: "2.0.0",
commit: "qwej79qwjeqw8euqo8wj8eq8"
}
}
]
})
}
}
issue-reporter
has a default markdown formatter. If you want a more flexible way to format your error reporter you can provide your own formatting function.
const issueReporter = require('issue-reporter')
async function main() {
try {
throw new Error('Some unexcepted error')
} catch (e) {
await issueReporter({
error: e,
user: 'frinyvonnick',
repo: 'issue-reporter',
formatReport: (errorReport) => {
return `## ${errorReport.error.title}
${errorReport.error.stack}
## ${errorReport.environment.title}
${errorReport.environment.markdown}
`
},
})
}
}
yarn run test
👤 Yvonnick FRIN
👤 Franck ABGRALL
Contributions, issues and feature requests are welcome!
Feel free to check issues page.
Give a ⭐️ if this project helped you!
Copyright © 2019 Yvonnick FRIN.
This project is Apache--2.0 licensed.
This README was generated with ❤️ by readme-md-generator
FAQs
A lib that generates issue reports for unexcepted errors.
The npm package issue-reporter receives a total of 745 weekly downloads. As such, issue-reporter popularity was classified as not popular.
We found that issue-reporter demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.