Open kansoadi opened 5 months ago
i solved the problem related to the
"get_full_data(sync, meili_settings.insert_size)"
but i got a new one
TypeError: 'async for' received an object from aiter that does not implement anext: coroutine
meilisync start
C:\Python312\Lib\site-packages\meilisync\main.py:135: RuntimeWarning: coroutine 'Source.aiter' was never awaited
async for event in source:
RuntimeWarning: Enable tracemalloc to get the object allocation traceback
┌─────────────────────────────── Traceback (most recent call last) ────────────────────────────────┐
│ C:\Python312\Lib\site-packages\meilisync\main.py:174 in start │
│ │
│ 171 │ │ lock = asyncio.Lock() │
│ 172 │ │ await asyncio.gather((), interval()) │
│ 173 │ │
│ > 174 │ asyncio.run(run()) │
│ 175 │
│ 176 │
│ 177 @app.command(help="Refresh all data by swap index") │
│ │
│ ┌─────────────────────────────────────────── locals ───────────────────────────────────────────┐ │
│ │ = <function start.
I wanted to provide a quick update regarding the recent issues we encountered. In light of the numerous errors and their perplexing nature, I decided to leverage Docker as a solution.
The transition to Docker has proven to be highly effective, and the application is now running smoothly without any hiccups. It appears that the challenges we faced were rooted in the operating environment, and Docker has provided a robust and reliable workaround.
I’m using Meilisync using docker compose
and I have the same issue:
meilisync-1 | TypeError: 'async for' requires an object with __aiter__ method, got coroutine
meilisync-1 exited with code 0
Edit: looks like an issue with progress.path
because when I commented-out the line the problem went away.
@bfontaine, what do you mean by "Edit: looks like an issue with progress.path because when I commented-out the line the problem went away" unfortunately, when i deploy the app on AWS i receive the same error, i try 2 methods: 1- Meilisearch and Meilisync were installed in 2 docker container 2- an EC2 was created by Meilisearch image, Meilisync installed by docker
i am stuck in the 2 methods by the error "TypeError: 'async for' requires an object with aiter method, got coroutine"
After deploying the app using two methods—utilizing Docker containers with Meilisearch and Meilisync installed separately, and creating an EC2 instance with Meilisearch image and Meilisync installed via Docker—we've hit the same roadblock. The error message we're grappling with is: "TypeError: 'async for' requires an object with aiter method, got coroutine."
@kansoadi I had a custom path
in the config, and when I removed it the issue went away.
With this config I have the error:
progress:
type: file
path: myprogress.json
# ...
With this one I don’t:
progress:
type: file
# ...
@bfontaine, but path is required if the type is set to file (type: file or redis, if set to file, another option path is required.)
_meilisync_1 | ValidationError: 1 validation error for Settings
meilisync_1 | progress
meilisync_1 | Field required [type=missing, input_value={'debug': True,
meilisync_1 | 'plugins'...ronment': 'production'}}, input_type=dict]
meilisync_1 | For further information visit https://errors.pydantic.dev/2.5/v/missing_
Please try latest source code
Sure, The latest source code was used; ' docker pull long2ice/meilisync Using default tag: latest latest: Pulling from long2ice/meilisync Digest: sha256:0916df358ccdcfeebad4d8c946c46641d2bf72a220907cde220d963638759f69 Status: Image is up to date for long2ice/meilisync:latest docker.io/long2ice/meilisync:latest "
I can't re reproduce locally.
For refresh:
For start:
I do have the same problem with the latest image, but was able to launch meilisync with older version
i got something familiar to this error :( exception=TypeError("'async for' requires an object with aiter method, got list")> i just pull the image (latest) plz HELP :)
I have the same issue when i run "meilisync refresh"
Plz Help
i saw another error when i was running "meilisearch check"
instead of using ret[0], i replace it with ret["count"] and it worked.
Hi, @kansoadi Have you resolved the issue? I have the same error "TypeError: 'async for' requires an object with aiter method, got coroutine" Config below
debug: true
plugins:
- meilisync.plugin.Plugin
progress:
type: file
source:
type: postgres
host: docker.for.mac.host.internal
port: 5433
database: test
user: postgres
password: <password>
meilisearch:
api_url: http://docker.for.mac.host.internal:7700
api_key: <admin_key>
insert_size: 1000
insert_interval: 10
sync:
- table: games
index: games_index
full: true
fields:
id:
Hello,
I wanted to bring to your attention some issues I have been experiencing with Meilisync. Unfortunately, I have noticed many errors while trying to integrate it into my app, which has made the process quite difficult.
It seems that Meilisync may require more thorough testing from its developer, especially when it comes to working with Postgresql. I have noticed that the replication increases in size and ultimately causes the app to crash. Additionally, it does not sync properly with the dedicated table(s), leading to discrepancies in the data.
I believe that addressing these issues and conducting further tests on Meilisync, particularly with Postgresql integration, will greatly improve its functionality and usability. I appreciate your attention to this matter and look forward to a resolution.
Thank you.
On Thu, May 23, 2024 at 1:01 PM Yurii Poliakov @.***> wrote:
Hi, @kansoadi https://github.com/kansoadi Have you resolved the issue? I have the same error "TypeError: 'async for' requires an object with aiter method, got coroutine" Config below
debug: trueplugins:
- meilisync.plugin.Pluginprogress: type: filesource: type: postgres host: docker.for.mac.host.internal port: 5433 database: test user: postgres password:
meilisearch: api_url: http://docker.for.mac.host.internal:7700 api_key: insert_size: 1000 insert_interval: 10sync: - table: games index: games_index full: true fields: id:
— Reply to this email directly, view it on GitHub https://github.com/long2ice/meilisync/issues/76#issuecomment-2126711870, or unsubscribe https://github.com/notifications/unsubscribe-auth/ARTTFFXOTPTZ5SHBGHHV5SDZDW47BAVCNFSM6AAAAABCPTYT32VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMRWG4YTCOBXGA . You are receiving this because you were mentioned.Message ID: @.***>
Hi, I am also got a similar issue. I got an error when running it for the first time with a Docker container. Then I tried running it on macOS, and it worked perfectly fine. I retried with Docker, and it worked normally. It seems this error only occurs when running it for the first time on Docker container.
hi,
I got the some err.
that is my config file
when I change the param 'full: false' , that will be ok, but I found I can not sync any data in meilisearch
bump
For anyone else having this problem with the official docker image - the official image (as of about 1 week prior to this message) was using version 0.1.2 - whereas this bug was seemingly fixed in 0.1.3.
I forked the repository, built the image myself and that seems to have fixed this issue.
For syncing databases with PostgreSQL and Meilisync,
I installed and configured Meilisync (windows 10) by following the steps in https://www.meilisearch.com/docs/learn/cookbooks/meilisync_postgresql Meilisync was well-configured: 1-
2- but for the Meilisync start, i received
TypeError: 'async for' requires an object with aiter method, got generator
returned from
C:\Python312\Lib\site-packages\meilisync\main.py:96 in │
│ │
│ 93 │ │ for sync in settings.sync: │
│ 94 │ │ │ if sync.full and not await meili.index_exists(sync.index_name): │
│ 95 │ │ │ │ count = 0 │
│ > 96 │ │ │ │ async for items in await source.get_full_data(sync, meili_settings.inser │
│ 97 │ │ │ │ │ count += len(items) │
│ 98 │ │ │ │ │ await meili.adddata(sync, items) │
│ 99 │ │ │ │ if count:
kindly, Any idea on how to solve this issue?