Skip to content
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

[WIP] Update/meteor v3.0 #484

Open
wants to merge 31 commits into
base: master
Choose a base branch
from

Conversation

bhunjadi
Copy link
Contributor

@bhunjadi bhunjadi commented Feb 19, 2024

I started working on Meteor 3.0 and managed to make some progress on the server-side. I started with links and also started adding types and use them in JS files which might help with this migration.

I managed to get the 4 tests in linker.tests.js working and will update progress here as I continue the work.

I'm replacing all calls to their *Async equivalents so I had to bump the minimal Meteor version to 2.8.1.

Tests todos:

  • Links
  • Exposures
  • Queries
  • Named queries
  • Reactive counts
  • GraphQL
  • Client tests

3rd party deps:

Other:

  • Update types
  • Setup lint
  • API changes docs

Compatibility with Meteor v2

  • getLink, add, set, etc functions in links should get Async suffix, client should stay the same

How to test

# v3
meteor create --release 3.0-beta.0 --bare test
cd test 
meteor npm i --save [email protected] [email protected] [email protected] chai

# then we also need to add packages that are not published yet
mkdir packages
cd packages

# mongo-collection-instances
git clone -b migration/3.0 https://github.com/Meteor-Community-Packages/mongo-collection-instances.git

# meteortesting:mocha
git clone -b migrate/3.0 https://github.com/Meteor-Community-Packages/meteor-mocha.git meteor-mocha-repo
# copy package into packages
cp -R ./meteor-mocha-repo/package ./meteor-mocha

Package.json in test (see scripts for convenience methods)

{
  "name": "test",
  "private": true,
  "scripts": {
    "start": "meteor run",
    "test": "MONGO_URL= METEOR_PACKAGE_DIRS=\"../:packages\" TEST_BROWSER_DRIVER=chrome meteor test-packages --driver-package meteortesting:mocha --once  --port 3010 ../",
    "test:server": "TEST_CLIENT=0 MONGO_URL= METEOR_PACKAGE_DIRS=\"../:packages\" TEST_BROWSER_DRIVER=chrome meteor test-packages --driver-package meteortesting:mocha --once  --port 3010 ../",
    "test:server:watch": "TEST_CLIENT=0 MONGO_URL= METEOR_PACKAGE_DIRS=\"../:packages\" TEST_BROWSER_DRIVER=chrome meteor test-packages --driver-package meteortesting:mocha  --port 3010 ../"
  },
  "dependencies": {
    "@babel/runtime": "^7.23.5",
    "chai": "^5.1.0",
    "chromedriver": "^2.36.0",
    "meteor-node-stubs": "^1.2.7",
    "selenium-webdriver": "^3.6.0",
    "simpl-schema": "^1.13.1"
  }
}

@StorytellerCZ
Copy link
Collaborator

This is most likely going to be a major version update, so minimum version of Meteor 2.8.1 is fine.

@StorytellerCZ StorytellerCZ linked an issue Feb 20, 2024 that may be closed by this pull request
@StorytellerCZ
Copy link
Collaborator

I'm going to release v1.5 in the coming days, most likely (pester me if I don't). After that the only releases I will do on the 1.x branch will be dependencies updates.

@StorytellerCZ StorytellerCZ added this to the V2.0 milestone Feb 28, 2024
@bhunjadi
Copy link
Contributor Author

@StorytellerCZ I think this is mostly ready to be released as v2 beta.
Todo from my side is to resolve conflicts with master.

Also, we would need denormalize to be published, see the PR here

@gothicn
Copy link

gothicn commented Aug 11, 2024

Yay! Its wonderful to get back to Meteor and see this amazing package be (almost) ready right away!

@StorytellerCZ
Copy link
Collaborator

@bhunjadi thank you very much for your efforts. I will release a beta shortly.

@StorytellerCZ
Copy link
Collaborator

Published cultofcoders:[email protected]

@StorytellerCZ
Copy link
Collaborator

@bhunjadi I'm unable to push to your branch. Can you please give me the permissions, to make things easier. Thanks!

@bhunjadi
Copy link
Contributor Author

@StorytellerCZ
I have checked this flag "Allow edits and ...".
image

Is there anything else that I need to do to allow you to push?

@fidelsam1992
Copy link

There is an issue with the latest release of grapher package with Meteor 3.x

Steps to reproduce

meteor create simple-todos-react --typescript
cd simple-todos-react
npm run start

Application running normally ✅

meteor add cultofcoders:grapher
npm run start

The list of tasks is not loaded anymore ❌

@StorytellerCZ
Copy link
Collaborator

@fidelsam1992 are you talking about the beta or regular release?

@vparpoil
Copy link
Contributor

vparpoil commented Jan 16, 2025

@StorytellerCZ @fidelsam1992 I tried to reproduce using Meteor 3.1 and I wasn't able to reproduce the issue. I only had to do some changes in denormalize chai version

@fidelsam1992
Copy link

fidelsam1992 commented Jan 19, 2025

Here are my steps to reproduce the issue

Node version: v20.17.0
Npm version: 10.8.2

meteor create simple-todos-react --typescript --release 3.1
cd simple-todos-react
npm run start

List of links rendered ✅
image

meteor add cultofcoders:grapher
npm run start

Installed grapher version: cultofcoders:[email protected]

List of links loading ❌
Links are not published to minimongo
image

My versions file:

@vparpoil
Copy link
Contributor

Hi @fidelsam1992, Thanks for the more detailled issue and sorry for missing the point. I fixed it here : bhunjadi#1
@bhunjadi could you merge it please?

The scoping added here c79edca broke classic Meteor.publish because of the lack of return

fix: scoping of publication break classical Meteor.publish
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Grapher 2.0 to support Meteor 3.0
5 participants