Giter Site home page Giter Site logo

carbonara's People

Contributors

dependabot[bot] avatar erim32 avatar honzahommer avatar petersolopov avatar superruzafa avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

carbonara's Issues

error on POST request

<title>Application Error</title> <style media="screen"> html,body,iframe { margin: 0; padding: 0; } html,body { height: 100%; overflow: hidden; } iframe { width: 100%; height: 100%; border: 0; } </style> <iframe src="//www.herokucdn.com/error-pages/application-error.html"></iframe>

Specific Characters Inhibiting Bash Script from Generating Previews

I am reading the content of my code files and storing it inside a variable. Then, I am using the variable inside the bash script to create a preview with the code.

However, as I am manually executing the bash script from inside of my script, specific characters included in my code files are hindering the bash script to execute/complete. This is resulting in corrupted, unopenable .png files.

And sometimes, characters in the file name are prohibiting the bash script from executing. Spaces in the name caused this issue. I believe numbers also were a problem. I am not exactly sure.

The temporary solution I came up with is to use lookalike Unicode characters. However, this causes another issue, as the API cannot interpret the characters to mean what they are supposed to mean, and the coloring is ruined.

Therefore, I am currently left with a script that succeeds 50% of the time yet still produces wrong previews.

The specific characters that causes issues for me are:

  • {
  • }
  • "
  • '
  • (
  • )
  • /

If I had found all of the characters, my script would be executing with a higher successful rate. As I am not educated about using bash, I was unable to identify the additional characters that were causing issues.

In addition, as I am reading the content of my code, the actual typed out newlines '\n' are getting mixed up with the interpreted newlines (actually pressing enter).

Heroku Endpoint is giving error response

Error:

<!DOCTYPE html>
	<html>
	  <head>
		<meta name="viewport" content="width=device-width, initial-scale=1">
		<meta charset="utf-8">
		<title>Application Error</title>
		<style media="screen">
		  html,body,iframe {
			margin: 0;
			padding: 0;
		  }
		  html,body {
			height: 100%;
			overflow: hidden;
		  }
		  iframe {
			width: 100%;
			height: 100%;
			border: 0;
		  }
		</style>
	  </head>
	  <body>
		<iframe src="//www.herokucdn.com/error-pages/application-error.html"></iframe>
	  </body>
	</html>

Running image without SYS_ADMIN capability

Hi there, great work on the API, I'm liking it so far!

I would like to deploy it on the PaaS Caprover, which is built on Docker Swarm. Your documentation however asks me to use the --cap-add=SYS_ADMIN flag, but that is is completely unsupported on swarm. Is there a way to modify your dockerfile not to rely on that being available? If you could just tell me which steps it is required for maybe I could patch it myself :)

Add transparent background support

Hi there,

I'd like to see transparent background to be implemented, It is possible if i set alpha to 0 in the rgba option, but I don't think puppeteer takes transparent screenshots.

Thanks,
cosmicice

API Request Timeout

This API call takes around 15 to 20 seconds, but i am trying to use this via Vercel Server which has limit of 10 seconds timeout, this Request is so slow is there any improvement for this ?

Thanks.

UnhandledPromiseRejectionWarning: TimeoutError: Navigation timeout of 30000 ms exceeded

I try to run it on my server but it report a error when I send a post request, which don't happen if use https://carbonara.now.sh/

(node:17) UnhandledPromiseRejectionWarning: TimeoutError: Navigation timeout of 30000 ms exceeded
    at /home/pptruser/app/node_modules/puppeteer-core/lib/LifecycleWatcher.js:100:25
  -- ASYNC --
    at Frame.<anonymous> (/home/pptruser/app/node_modules/puppeteer-core/lib/helper.js:82:19)
    at Page.goto (/home/pptruser/app/node_modules/puppeteer-core/lib/Page.js:440:53)
    at Page.<anonymous> (/home/pptruser/app/node_modules/puppeteer-core/lib/helper.js:83:27)
    at module.exports (/home/pptruser/app/src/takeScreenshot.js:41:14)
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:17) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:17) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

I 'm not familiar with node.js, so I search it in google. But I can't solve it. I wish if someone can help me.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.