Comments (2)
Hey @Carsak, you're currently using a blocking function (file_put_contents()
) inside your async function. The async()
function only works in tandem with the await() function and does not "magically" make any blocking function non-blocking. This is also described in the documentation for the async()
function. So as long as you're not using the await()
function, it doesn't make much sense to use async()
here.
I believe this should answer your question, so I will close this ticket for now. We can reopen this if you encounter the same issues again after trying out the solutions mentioned in here. If you do need to reopen the ticket, please provide some information about the steps you've taken so far, what worked and what didn't.
FYI: I think this kind of ticket is better suited for a discussion in our "Q&A" section. We recommend opening bug tickets only when you can provide evidence of something being broken, just as a friendly reminder for future tickets :)
from async.
thank you @SimonFrings
I solved my problem in another way. Maybe more radical, but it works.
Details in https://github.com/orgs/reactphp/discussions/550
from async.
Related Issues (14)
- await() error in SimpleFiber.php HOT 17
- Fibers + Cancellation HOT 2
- Use 0.x versions HOT 5
- Error: event_base_loop reentrant invocation HOT 9
- await() doesn't work with streaming HTTP response body HOT 9
- Allow `iterable` instead of `array` for `parallel()`, `series()` and `waterfall()` HOT 1
- Cancellation semantics for `async()` and `coroutine()` HOT 2
- Support Promise v3 HOT 1
- Using await in a destructor HOT 7
- Improve error reporting when incorrectly using `await()` (Value of type null is not callable in src/SimpleFiber.php:66) HOT 6
- Struggling with the simplest example HOT 1
- Basic question 'bout reactphp HOT 9
- reactphp/async
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from async.