Merge branch 'devel' into modern-bundler-integration

This commit is contained in:
Nacho Codoñer
2025-06-25 18:16:02 +02:00
36 changed files with 684 additions and 184 deletions

190
.github/scripts/inactive-issues.js vendored Normal file
View File

@@ -0,0 +1,190 @@
module.exports = async ({ github, context }) => {
const daysToComment = 60;
const daysToLabel = 90;
const now = new Date();
const idleTimeComment = daysToComment * 24 * 60 * 60 * 1000; // 60 days in milliseconds
const idleTimeLabel = daysToLabel * 24 * 60 * 60 * 1000; // 90 days in milliseconds
// Function to fetch issues until we find recently updated ones
async function fetchAllIssues() {
let allIssues = [];
let page = 1;
let hasNextPage = true;
const now = new Date();
const minInactivity = idleTimeComment; // 60 days in milliseconds
while (hasNextPage) {
const response = await github.rest.issues.listForRepo({
owner: context.repo.owner,
repo: context.repo.repo,
state: 'open',
per_page: 100,
page: page,
sort: 'updated',
direction: 'asc' // Oldest updated first
});
// Check if the most recently updated issue on this page is too recent
let recentIssueFound = false;
if (response.data.length > 0) {
// Check the last issue on the page (most recently updated)
const lastIssue = response.data[response.data.length - 1];
const lastIssueUpdatedAt = new Date(lastIssue.updated_at);
const timeSinceLastIssueUpdate = now.getTime() - lastIssueUpdatedAt.getTime();
if (timeSinceLastIssueUpdate < minInactivity) {
// This page already has issues that are too recent, filter them out
const filteredIssues = response.data.filter(issue => {
const issueUpdatedAt = new Date(issue.updated_at);
const timeSinceUpdate = now.getTime() - issueUpdatedAt.getTime();
return timeSinceUpdate >= minInactivity;
});
allIssues = allIssues.concat(filteredIssues);
recentIssueFound = true;
hasNextPage = false;
} else {
// All issues on this page are old enough, keep them all
allIssues = allIssues.concat(response.data);
}
}
// Stop if we found recent issues or reached the end of pagination
if (recentIssueFound) {
hasNextPage = false;
} else if (response.data.length < 100) {
hasNextPage = false;
} else {
page++;
// Small delay to avoid hitting rate limits
await new Promise(resolve => setTimeout(resolve, 100));
}
}
return allIssues;
}
// Fetch all issues
const allIssues = await fetchAllIssues();
let processedCount = 0;
let commentedCount = 0;
let labeledCount = 0;
for (const issue of allIssues) {
processedCount++;
// Skip pull requests
if (issue.pull_request) {
continue;
}
// Skip issues that already have the idle label
if (issue.labels.some(label => label.name === 'idle')) {
continue;
}
// Get latest comment or update date
const issueUpdatedAt = new Date(issue.updated_at);
const timeSinceUpdate = now.getTime() - issueUpdatedAt.getTime();
// Handle 60-day idle issues (comment)
if (timeSinceUpdate > idleTimeComment && timeSinceUpdate <= idleTimeLabel) {
// Check if bot already commented to avoid duplicate comments
const comments = await github.rest.issues.listComments({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issue.number,
per_page: 100
});
// Check if there's a recent bot comment
const botCommented = comments.data.some(comment => {
const commentDate = new Date(comment.created_at);
const timeSinceComment = now.getTime() - commentDate.getTime();
const isBot = comment.user.login === 'github-actions[bot]';
const isRecent = timeSinceComment < idleTimeComment;
const hasRightContent = comment.body.includes('Is this issue still relevant?');
return isBot && isRecent && hasRightContent;
});
if (!botCommented) {
try {
const result = await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issue.number,
body: `👋 @${issue.user.login} This issue has been open for 60 days with no activity. Is this issue still relevant? If there is no response or activity within the next 30 days, this issue will be labeled as \`idle\`.`
});
commentedCount++;
} catch (error) {
// Add retry logic
try {
// Wait for 5 seconds before retrying
await new Promise(resolve => setTimeout(resolve, 5000));
const retryResult = await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issue.number,
body: `👋 @${issue.user.login} This issue has been open for 60 days with no activity. Is this issue still relevant? If there is no response or activity within the next 30 days, this issue will be labeled as \`idle\`.`
});
commentedCount++;
} catch (retryError) {
// Failed retry, continue with other issues
}
}
}
}
// Handle 90-day idle issues (add label)
else if (timeSinceUpdate > idleTimeLabel) {
// Check if the issue has the idle label
if (!issue.labels.some(label => label.name === 'idle')) {
try {
// Add the label
const labelResult = await github.rest.issues.addLabels({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issue.number,
labels: ['idle']
});
// Add a comment when labeling as idle
const commentResult = await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issue.number,
body: `This issue has been automatically labeled as \`idle\` due to 90 days of inactivity. If this issue is still relevant, please comment to reactivate it.`
});
labeledCount++;
} catch (error) {
// Add retry logic with exponential backoff
try {
// Wait for 5 seconds before retrying
await new Promise(resolve => setTimeout(resolve, 5000));
const retryLabelResult = await github.rest.issues.addLabels({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issue.number,
labels: ['idle']
});
// Retry adding comment
const retryCommentResult = await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issue.number,
body: `This issue has been automatically labeled as \`idle\` due to 90 days of inactivity. If this issue is still relevant, please comment to reactivate it.`
});
labeledCount++;
} catch (retryError) {
// Continue with other issues if retry fails
}
}
}
}
}
};

24
.github/workflows/inactive-issues.yml vendored Normal file
View File

@@ -0,0 +1,24 @@
name: Inactive Issues Management
on:
schedule:
# “At 01:00 on Saturday.”
- cron: '0 1 * * 6'
# Allows to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
manage-inactive-issues:
runs-on: ubuntu-latest
permissions:
issues: write
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Manage inactive issues
uses: actions/github-script@v6
with:
script: |
const script = require('./.github/scripts/inactive-issues.js')
await script({github, context})

View File

@@ -8,7 +8,7 @@
[//]: # (go to meteor/docs/generators/changelog/docs)
## v3.3.0, 2025-05-28
## v3.3.0, 2025-06-11
### Highlights
@@ -27,16 +27,16 @@
All Merged PRs@[GitHub PRs 3.3](https://github.com/meteor/meteor/pulls?q=is%3Apr+is%3Amerged+base%3Arelease-3.3)
React Packages Changelog: [react-meteor-data@4.0.0-beta.0](https://github.com/meteor/react-packages/blob/fb73eeb89ff59664a7a01769fa1c2c880e72a3e5/packages/react-meteor-data/CHANGELOG.md#v400-beta0-xxx)
React Packages Changelog: [react-meteor-data@4.0.0](https://github.com/meteor/react-packages/tree/master/packages/react-meteor-data/CHANGELOG.md#v400-2025-06-11)
#### Breaking Changes
- File watching strategy switched to `@parcel/watcher`
- Most setups should be fine, but if issues appear, like when using WSL with host, volumes, or remote setups—switch to polling.
- Set `METEOR_WATCH_FORCE_POLLING=true` to enable polling.
- Set `METEOR_WATCH_POLLING_INTERVAL_MS=1000` to adjust the interval.
- Most setups should be fine, but if issues appear, like when using WSL with host, volumes, or remote setups—switch to polling.
- Set `METEOR_WATCH_FORCE_POLLING=true` to enable polling.
- Set `METEOR_WATCH_POLLING_INTERVAL_MS=1000` to adjust the interval.
- `react-meteor-data@4.0.0-beta.0`
- `react-meteor-data@4.0.0`
- Independent from the core, only applies if upgraded manually.
- useFind describes no deps by default [PR#431](https://github.com/meteor/react-packages/pull/431)
@@ -51,13 +51,13 @@ React Packages Changelog: [react-meteor-data@4.0.0-beta.0](https://github.com/me
Please run the following command to update your project:
```bash
meteor update --release 3.3-beta.1
meteor update --release 3.3
```
To apply react-meteor-data changes:
```bash
meteor add react-meteor-data@4.0.0-beta.0
meteor add react-meteor-data@4.0.0
```
**Add this to your `package.json` to enable the new modern build stack:**
@@ -70,26 +70,34 @@ meteor add react-meteor-data@4.0.0-beta.0
> These settings are on by default for new apps.
On activate `modern` your app will be updated to use SWC transpiler. It will automatically fallback to Babel if your code can't be transpiled with SWC.
Check the docs for help with the SWC migration, especially if your project uses many Babel plugins.
[Modern Transpiler: SWC docs](https://docs.meteor.com/about/modern-build-stack/transpiler-swc.html)
If you find any issues, please report them to the [Meteor issues tracker](https://github.com/meteor/meteor).
#### Bumped Meteor Packages
- accounts-base@3.1.1-rc330.0
- accounts-password@3.2.0-rc330.0
- autoupdate@2.0.1-rc330.0
- babel-compiler@7.12.0-rc330.0
- boilerplate-generator@2.0.1-rc330.0
- ddp-client@3.1.1-rc330.0
- ecmascript@0.16.11-rc330.0
- ejson@1.1.5-rc330.0
- meteor@2.1.1-rc330.0
- minifier-js@3.0.2-rc330.0
- modern-browsers@0.2.2-rc330.0
- mongo@2.1.2-rc330.0
- server-render@0.4.3-rc330.0
- socket-stream-client@0.6.1-rc330.0
- standard-minifier-js@3.1.0-rc330.0
- typescript@5.6.4-rc330.0
- webapp@2.0.7-rc330.0
- meteor-tool@3.3.0-rc.0
- accounts-base@3.1.1
- accounts-password@3.2.0
- autoupdate@2.0.1
- babel-compiler@7.12.0
- boilerplate-generator@2.0.1
- ddp-client@3.1.1
- ecmascript@0.16.11
- ejson@1.1.5
- meteor@2.1.1
- minifier-js@3.0.2
- modern-browsers@0.2.2
- mongo@2.1.2
- server-render@0.4.3
- socket-stream-client@0.6.1
- standard-minifier-js@3.1.0
- typescript@5.6.4
- webapp@2.0.7
- meteor-tool@3.3.0
#### Bumped NPM Packages
@@ -99,9 +107,9 @@ meteor add react-meteor-data@4.0.0-beta.0
✨✨✨
- [@nachocodoner](https://github.com/nachocodoner)
- [@nachocodoner](https://github.com/nachocodoner)
- [@italojs](https://github.com/italojs)
- [@Grubba27](https://github.com/Grubba27)
- [@Grubba27](https://github.com/Grubba27)
- [@zodern](https://github.com/zodern)
- [@9Morello](https://github.com/9Morello)
- [@welkinwong](https://github.com/welkinwong)
@@ -111,7 +119,8 @@ meteor add react-meteor-data@4.0.0-beta.0
- [@ericm546](https://github.com/ericm546)
- [@StorytellerCZ](https://github.com/StorytellerCZ)
✨✨✨
✨✨✨
## v3.0.1, 2024-07-16

View File

@@ -1,7 +1,7 @@
const os = require('os');
const path = require('path');
const METEOR_LATEST_VERSION = '3.2';
const METEOR_LATEST_VERSION = '3.3';
const sudoUser = process.env.SUDO_USER || '';
function isRoot() {
return process.getuid && process.getuid() === 0;

View File

@@ -1,12 +1,12 @@
{
"name": "meteor",
"version": "3.2.0",
"version": "3.3.0",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "meteor",
"version": "3.2.0",
"version": "3.3.0",
"hasInstallScript": true,
"license": "MIT",
"dependencies": {

View File

@@ -1,6 +1,6 @@
{
"name": "meteor",
"version": "3.2.0",
"version": "3.3.0",
"description": "Install Meteor",
"main": "install.js",
"scripts": {

View File

@@ -1,6 +1,6 @@
Package.describe({
summary: "A user account system",
version: "3.1.1-rc330.0",
version: "3.1.1",
});
Package.onUse((api) => {

View File

@@ -5,7 +5,7 @@ Package.describe({
// 2.2.x in the future. The version was also bumped to 2.0.0 temporarily
// during the Meteor 1.5.1 release process, so versions 2.0.0-beta.2
// through -beta.5 and -rc.0 have already been published.
version: "3.2.0-rc330.0",
version: "3.2.0",
});
Npm.depends({

View File

@@ -1,6 +1,6 @@
Package.describe({
summary: 'Update the client when new client code is available',
version: '2.0.1-rc330.0',
version: '2.0.1',
});
Package.onUse(function(api) {

View File

@@ -1,7 +1,7 @@
Package.describe({
name: "babel-compiler",
summary: "Parser/transpiler for ECMAScript 2015+ syntax",
version: '7.12.0-rc330.0',
version: '7.12.0',
});
Npm.depends({

View File

@@ -1,6 +1,6 @@
Package.describe({
summary: "Generates the boilerplate html from program's manifest",
version: '2.0.1-rc330.0',
version: '2.0.1',
});
Npm.depends({

View File

@@ -1,6 +1,6 @@
Package.describe({
summary: "Meteor's latency-compensated distributed data client",
version: "3.1.1-rc330.0",
version: "3.1.1",
documentation: null,
});

View File

@@ -1,6 +1,6 @@
Package.describe({
name: 'ecmascript',
version: '0.16.11-rc330.0',
version: '0.16.11',
summary: 'Compiler plugin that supports ES2015+ in all .js files',
documentation: 'README.md',
});

View File

@@ -1,6 +1,6 @@
Package.describe({
summary: 'Extended and Extensible JSON library',
version: '1.1.5-rc330.0',
version: '1.1.5',
});
Package.onUse(function onUse(api) {

View File

@@ -1,6 +1,6 @@
Package.describe({
summary: "The Meteor command-line tool",
version: "3.3.0-rc.0",
version: "3.3.0",
});
Package.includeTool();

View File

@@ -2,7 +2,7 @@
Package.describe({
summary: "Core Meteor environment",
version: '2.1.1-rc330.0',
version: '2.1.1',
});
Package.registerBuildPlugin({

View File

@@ -1,6 +1,6 @@
Package.describe({
summary: "JavaScript minifier",
version: '3.0.2-rc330.0',
version: '3.0.2',
});
Npm.depends({

View File

@@ -1,6 +1,6 @@
Package.describe({
name: 'modern-browsers',
version: '0.2.2-rc330.0',
version: '0.2.2',
summary:
'API for defining the boundary between modern and legacy ' +
'JavaScript clients',

View File

@@ -11,6 +11,7 @@ import {
validateCollectionName
} from './collection_utils';
import { ReplicationMethods } from './methods_replication';
import { watchChangeStream } from './watch_change_stream';
/**
* @summary Namespace for MongoDB-related items
@@ -263,6 +264,10 @@ Mongo.Collection.ObjectID = Mongo.ObjectID;
*/
Meteor.Collection = Mongo.Collection;
// Allow deny stuff is now in the allow-deny package
Object.assign(Mongo.Collection.prototype, AllowDeny.CollectionPrototype);
// Só agora que Mongo.Collection existe, adicionamos o método ao prototype
Object.assign(Mongo.Collection.prototype, { watchChangeStream });

View File

@@ -0,0 +1,31 @@
/**
* @summary Watches the MongoDB collection using Change Streams.
* @locus Server
* @memberof Mongo.Collection
* @instance
* @param {Array} [pipeline] Optional aggregation pipeline to filter Change Stream events.
* @param {Object} [options] Optional settings for the Change Stream.
* @returns {ChangeStream} The MongoDB ChangeStream instance.
* @throws {Error} If called on a client/minimongo collection.
*
* @example
* const changeStream = MyCollection.watchChangeStream([
* { $match: { 'operationType': 'insert' } }
* ]);
* changeStream.on('change', (change) => {
* console.log('Change detected:', change);
* });
*/
export function watchChangeStream(pipeline = [], options = {}) {
// Only available on server
if (typeof Package === 'undefined' || !this.rawCollection) {
throw new Error('watchChangeStream is only available on server collections');
}
const raw = this.rawCollection();
if (!raw.watch) {
throw new Error('Underlying collection does not support watch (Change Streams)');
}
console.log('[watchChangeStream] Chamando raw.watch() com pipeline:', JSON.stringify(pipeline, null, 2), 'e options:', JSON.stringify(options, null, 2));
return raw.watch(pipeline, options);
}

View File

@@ -9,7 +9,7 @@
Package.describe({
summary: "Adaptor for using MongoDB and Minimongo over DDP",
version: "2.1.2-rc330.0",
version: "2.1.2",
});
Npm.depends({

View File

@@ -3,7 +3,7 @@ Package.describe({
summary: 'Compiler for CoffeeScript code, supporting the coffeescript package',
// This version of NPM `coffeescript` module, with _1, _2 etc.
// If you change this, make sure to also update ../coffeescript/package.js to match.
version: '2.4.2-rc330.0',
version: '2.4.2',
});
Npm.depends({

View File

@@ -6,12 +6,12 @@ Package.describe({
// so bumping the version of this package will be how they get newer versions
// of `coffeescript-compiler`. If you change this, make sure to also update
// ../coffeescript-compiler/package.js to match.
version: '2.7.3-rc330.0',
version: '2.7.3',
});
Package.registerBuildPlugin({
name: 'compile-coffeescript',
use: ['caching-compiler@2.0.1', 'ecmascript@0.16.11-rc330.0', 'coffeescript-compiler@2.4.2-rc330.0'],
use: ['caching-compiler@2.0.1', 'ecmascript@0.16.11', 'coffeescript-compiler@2.4.2'],
sources: ['compile-coffeescript.js'],
npmDependencies: {
// A breaking change was introduced in @babel/runtime@7.0.0-beta.56

View File

@@ -1,6 +1,6 @@
Package.describe({
name: "server-render",
version: '0.4.3-rc330.0',
version: '0.4.3',
summary: "Generic support for server-side rendering in Meteor apps",
documentation: "README.md"
});

View File

@@ -1,6 +1,6 @@
Package.describe({
name: "socket-stream-client",
version: '0.6.1-rc330.0',
version: '0.6.1',
summary: "Provides the ClientStream abstraction used by ddp-client",
documentation: "README.md"
});

View File

@@ -1,6 +1,6 @@
Package.describe({
name: 'standard-minifier-js',
version: '3.1.0-rc330.0',
version: '3.1.0',
summary: 'Standard javascript minifiers used with Meteor apps by default.',
documentation: 'README.md',
});

View File

@@ -1,6 +1,6 @@
Package.describe({
name: 'typescript',
version: '5.6.4-rc330.0',
version: '5.6.4',
summary:
'Compiler plugin that compiles TypeScript and ECMAScript in .ts and .tsx files',
documentation: 'README.md',

View File

@@ -1,6 +1,6 @@
Package.describe({
summary: "Serves a Meteor app over HTTP",
version: "2.0.7-rc330.0",
version: "2.0.7",
});
Npm.depends({

View File

@@ -1,6 +1,6 @@
{
"track": "METEOR",
"version": "3.2.2",
"version": "3.3",
"recommended": false,
"official": true,
"description": "The Official Meteor Distribution"

View File

@@ -141,5 +141,7 @@ npx meteor uninstall
If you installed Meteor using curl or as a fallback solution, run:
`rm -rf ~/.meteor`
`sudo rm /usr/local/bin/meteor`
```bash
rm -rf ~/.meteor
sudo rm /usr/local/bin/meteor
```

View File

@@ -92,11 +92,11 @@ Or exclude only specific files like `.jsx`:
}
```
You can also use `excludePackages`, `excludeNodeModules`, and `excludeLegacy` for finer control. See the [`modernTranspiler` config docs](#config-api) for more.
You can also use `excludePackages`, `excludeNodeModules`, and `excludeLegacy` for finer control. See the [`modern.transpiler` config docs](#config-api) for more.
When no plugin exists, these settings let you still get most of SWCs speed benefits by limiting fallback use.
Most apps will benefit just by enabling `modernTranspiler: true`. Most Meteor packages should work right away, except ones using nested imports. Node modules will mostly work too, since they follow common standards. Most app code should also work unless it depends on Babel-specific behavior.
Most apps will benefit just by enabling `modern: true`. Most Meteor packages should work right away, except ones using nested imports. Node modules will mostly work too, since they follow common standards. Most app code should also work unless it depends on Babel-specific behavior.
> Remember to turn off verbosity when you're done with optimizations.
@@ -110,7 +110,7 @@ You can also configure other options using the `.swcrc` format. One common case
{
"jsc": {
"parser": {
"syntax": "emcascript",
"syntax": "ecmascript",
"jsx": true
}
}
@@ -276,6 +276,6 @@ If you run into issues, try `meteor reset` or delete the `.meteor/local` folder
For help or to report issues, post on [GitHub](https://github.com/meteor/meteor/issues) or the [Meteor forums](https://forums.meteor.com). Were focused on making Meteor faster and your feedback helps.
You can compare performance before and after enabling `modernTranspiler` by running [`meteor profile`](../../cli/index.md#meteorprofile). Share your results to show progress to others.
You can compare performance before and after enabling `modern` by running [`meteor profile`](../../cli/index.md#meteorprofile). Share your results to show progress to others.
> **[Check out modern bundler options](bundler.md) to improve performance and access newer build features.**

View File

@@ -4,7 +4,7 @@ Describes the high-level features and actions for the Meteor project in the near
## Introduction
**Last updated: March 31th, 2025.**
**Last updated: June 16, 2025.**
The description of many items includes sentences and ideas from Meteor community members.
@@ -34,26 +34,42 @@ Contributors are encouraged to focus their efforts on work that aligns with the
**Goal:** Add a command([meteor profile](/cli/#meteorprofile)) to measure if our changes are actually making our builds faster and smaller.
#### Phase 2: External Transpiler Integration & Bundler Improvements
#### Phase 2: External Transpiler Integration
**Target Release:** 3.3
**Target Release:** 3.3
**Goal:** For this phase we want:
- Improve our current bundler performance, via optimizations so that any meteor user can get benefits from it; And an external bundler could get
the same benefits.
- To have an external transpiler working with Meteor and producing a bundle that is smaller or faster than the current Meteor bundle.
#### Phase 3: HMR Improvements
**Target Release:** 3.3.x ⏳
**Target Release:** 3.3
**Goal:** Improve the HMR performance, so that it is faster and more reliable on what needs to be changed.
#### Phase 4: Build Process Optimization
#### Phase 4: Bundler Improvements & feedback
**Target Release:** 3.3.x ⏳
**Goal:** Improve the build size and make meteor use less resources for building, decreasing even more build and rebuild time.
- Expanding compatibility and updates based on the feedback from the community, so that we can have a better experience with our new build tools, in this case SWC
#### Phase 5: External Bundler integration
**Target Release:** 3.4 ⏳
**Goal:** And an external bundler (like RSPack, ESBuild, or Rollup) working with Meteor and producing a bundle that is smaller or faster than the current Meteor bundle.
- This will also allow Meteor to have features like tree-shaking, code-splitting, and other optimizations that will make our apps leaner and faster.
#### Phase 6: Build Process Optimization
**Target Release:** 3.4.x ⏳
**Goal:** Improve the build size and make meteor use less resources for building, decreasing even more build and rebuild time.
- Expanding compatibility and updates based on the feedback from the community, so that we can have a better experience with our new build tools
#### Documentation Strategy

View File

@@ -1417,99 +1417,306 @@ This system allows forks of the meteor tool to be published as packages, letting
:::
## meteor test-packages {meteortestpackages}
## meteor test-packages {#meteortestpackages}
Test Meteor packages, either by name, or by directory. Not specifying an
argument will run tests for all local packages. The results are displayed in an
app that runs at `localhost:3000` by default. If you need to, you can pass the
`--settings` and `--port` arguments.
Run tests for Meteor packages.
If you want to filter the tests by name, you can use `--filter` or `-f`
followed by the name of the test you want to run, it supports regex's.
```bash
meteor test-packages [options] [package...]
```
```sh
### Description
Runs unit tests for one or more packages. Test results appear in a browser dashboard that updates whenever relevant source files are modified.
::: tip Package Specification
Packages can be specified by:
- **Name**: Resolved using the standard package search algorithm
- **Path**: Any argument containing a '/' is loaded from that directory path
:::
If no packages are specified, all available packages will be tested.
### Options
| Option | Description |
|-------------------------------|-----------------------------------------------------------------|
| `--port`, `-p <port>` | Port to listen on (default: 3000). Also uses ports N+1 and N+2 |
| `--open`, `-o` | Opens a browser window when the app starts |
| `--inspect[-brk][=<port>]` | Enable server-side debugging (default port: 9229) |
| `--settings`, `-s <file>` | Set optional data for Meteor.settings on the server |
| `--production` | Simulate production mode (minify and bundle CSS, JS files) |
| `--driver-package <package>` | Test driver package to use (e.g., `meteortesting:mocha`) |
| `--filter`, `-f` | Filter the tests by name |
| `--verbose` | Print all output from build logs |
| `--no-lint` | Skip running linters on every test app rebuild |
| `--extra-packages <packages>` | Run with additional packages (comma separated) |
| `--test-app-path <path>` | Set directory for temporary test app (default: system temp dir) |
#### Mobile Testing Options
| Option | Description |
|--------|-------------|
| `--ios`, `--android` | Run tests in an emulator |
| `--ios-device`, `--android-device` | Run tests on a connected device |
| `--mobile-server <url>` | Server location for mobile builds (default: local IP and port) |
| `--cordova-server-port <port>` | Local port where Cordova will serve content |
### Examples
#### Test specific packages by name
```bash
meteor test-packages accounts-base accounts-password
```
#### Test a package by path
```bash
meteor test-packages ./packages/my-package
```
#### Test with custom settings
```bash
meteor test-packages --settings settings.json
```
#### Test with Mocha test driver
```bash
meteor test-packages --driver-package meteortesting:mocha
```
#### Test with filter
```bash
meteor test-packages --filter myTestName
```
this command will run only the tests that have `myTestName` in their name.
Alternatively, you can use the `TINYTEST_FILTER` environment variable to filter:
```sh
```bash
TINYTEST_FILTER=myTestName meteor test-packages
```
Has the same effect as the previous command.
## meteor admin {meteoradmin}
#### Test on mobile device
Catch-all for miscellaneous commands that require authorization to use.
```bash
meteor test-packages --ios-device
```
Some example uses of `meteor admin` include adding and removing package
maintainers and setting a homepage for a package. It also includes various
helpful functions for managing a Meteor release. Run `meteor help admin` for
more information.
## meteor admin {#meteoradmin}
## meteor shell {meteorshell}
Administrative commands for official Meteor services.
When `meteor shell` is executed in an application directory where a server
is already running, it connects to the server and starts an interactive
shell for evaluating server-side code.
```bash
meteor admin <command> [args]
```
Multiple shells can be attached to the same server. If no server is
currently available, `meteor shell` will keep trying to connect until it
succeeds.
::: warning Authorization Required
These commands require authorization to use.
:::
Exiting the shell does not terminate the server. If the server restarts
because a change was made in server code, or a fatal exception was
encountered, the shell will restart along with the server. This behavior
can be simulated by typing `.reload` in the shell.
### Available Commands
The shell supports tab completion for global variables like `Meteor`,
`Mongo`, and `Package`. Try typing `Meteor.is` and then pressing tab.
| Command | Description |
|---------|-------------|
| `maintainers` | View or change package maintainers |
| `recommend-release` | Recommend a previously published release |
| `change-homepage` | Change the homepage URL of a package |
| `list-organizations` | List the organizations of which you are a member |
| `members` | View or change the members of an organization |
| `get-machine` | Open an SSH shell to a machine in the Meteor build farm |
The shell maintains a persistent history across sessions. Previously-run
commands can be accessed by pressing the up arrow.
### Usage Examples
## meteor npm {meteornpm}
```bash
# View or change package maintainers
meteor admin maintainers packagename [add/remove] [username]
The `meteor npm` command calls the
[`npm`](https://docs.npmjs.com/getting-started/what-is-npm) version bundled
with Meteor itself.
# Change a package homepage
meteor admin change-homepage packagename [url]
Additional parameters can be passed in the same way as the `npm` command
(e.g. `meteor npm rebuild`, `meteor npm ls`, etc.) and the
[npm documentation](https://docs.npmjs.com/) should be consulted for the
full list of commands and for a better understanding of their usage.
# List your organizations
meteor admin list-organizations
For example, executing `meteor npm install lodash --save` would install `lodash`
from npm to your `node_modules` directory and save its usage in your
[`package.json`](https://docs.npmjs.com/files/package.json) file.
# Manage organization members
meteor admin members organization-name [add/remove] [username]
```
Using the `meteor npm ...` commands in place of traditional `npm ...` commands
is particularly important when using Node.js modules that have binary
dependencies that make native C calls (like [`bcrypt`](https://www.npmjs.com/package/bcrypt))
because doing so ensures that they are built using the same libraries.
::: tip Detailed Help
For more information on any admin command, run:
```bash
meteor help admin <command>
```
:::
Additionally, this access to the npm that comes with Meteor avoids the need to
download and install npm separately.
## meteor shell {#meteorshell}
## meteor node {meteornode}
Start an interactive JavaScript shell for evaluating server-side code.
The `meteor node` command calls the
[`node`](https://nodejs.org) version bundled with Meteor itself.
```bash
meteor shell
```
> This is not to be confused with [`meteor shell`](#meteor-shell), which provides
> an almost identical experience but also gives you access to the "server" context
> of a Meteor application. Typically, `meteor shell` will be preferred.
### Description
Additional parameters can be passed in the same way as the `node` command, and
the [Node.js documentation](https://nodejs.org/dist/latest-v4.x/docs/api/cli.html)
should be consulted for the full list of commands and for a better understanding
of their usage.
The `meteor shell` command connects to a running Meteor server and provides an interactive JavaScript REPL (Read-Eval-Print Loop) for executing server-side code.
For example, executing `meteor node` will enter the Node.js
[Read-Eval-Print-Loop (REPL)](https://nodejs.org/dist/latest-v4.x/docs/api/repl.html)
interface and allow you to interactively run JavaScript and see the results.
::: tip Connection Behavior
- Requires a running Meteor server in the application directory
- If no server is available, it will keep trying to connect until successful
- Multiple shells can be attached to the same server simultaneously
:::
Executing `meteor node -e "console.log(process.versions)"` would
run `console.log(process.versions)` in the version of `node` bundled with Meteor.
### Features
#### Server Integration
- Exiting the shell does not terminate the server
- If the server restarts (due to code changes or errors), the shell will automatically restart with it
- You can manually trigger a reload by typing `.reload` in the shell
#### Developer Experience
| Feature | Description |
|---------|-------------|
| **Tab Completion** | Built-in tab completion for global variables like `Meteor`, `Mongo`, and `Package` |
| **Persistent History** | Command history is maintained across sessions |
| **Command Recall** | Access previously-run commands using the up arrow key |
### Example Usage
```bash
# Start a Meteor server in one terminal
meteor run
# Connect a shell in another terminal
meteor shell
# Now you can run server-side code interactively:
> Meteor.users.find().count()
> Package.mongo.Mongo.Collection.prototype
> Meteor.isServer
true
> .reload # Manually restart the shell
```
::: details Advanced Example
```js
// Query the database
> db = Package.mongo.MongoInternals.defaultRemoteCollectionDriver().mongo.db
> db.collection('users').find().toArray()
// Access Meteor settings
> Meteor.settings.public
// Inspect publications
> Object.keys(Meteor.server.publish_handlers)
```
:::
## meteor npm {#meteornpm}
Run npm commands using Meteor's bundled npm version.
```bash
meteor npm <command> [args...]
```
### Description
The `meteor npm` command executes [npm](https://docs.npmjs.com/) commands using the version bundled with Meteor itself.
::: tip Benefits of Using Meteor's npm
1. Ensures compatibility with Meteor's Node.js version
2. Crucial for packages with native dependencies (like `bcrypt`)
3. No need to install npm separately
4. Consistent behavior across development environments
:::
### Common Commands
| Command | Description |
|---------|-------------|
| `meteor npm install` | Install all dependencies listed in `package.json` |
| `meteor npm install <package> --save` | Install and save a package as a dependency |
| `meteor npm install <package> --save-dev` | Install and save a package as a development dependency |
| `meteor npm update` | Update all packages to their latest allowed versions |
| `meteor npm ls` | List installed packages |
| `meteor npm rebuild` | Rebuild packages that have native dependencies |
### Examples
```bash
# Install a package and save to dependencies
meteor npm install lodash --save
# Install packages from package.json
meteor npm install
# Run an npm script defined in package.json
meteor npm run start
# View package information
meteor npm info react
```
::: warning Native Dependencies
Using `meteor npm` instead of regular `npm` is especially important when working with packages that have binary dependencies making native C calls (like `bcrypt`). This ensures they're built with the same libraries used by Meteor.
:::
## meteor node {#meteornode}
Run Node.js commands using Meteor's bundled Node.js version.
```bash
meteor node [options] [script.js] [arguments]
```
::: info Alternative
Consider using [`meteor shell`](#meteorshell) instead, which provides similar functionality plus access to your Meteor application's server context.
:::
### Description
The `meteor node` command runs [Node.js](https://nodejs.org/) using the version bundled with Meteor itself.
### Common Uses
| Command | Description |
|---------|-------------|
| `meteor node` | Start an interactive Node.js REPL |
| `meteor node script.js` | Execute a JavaScript file |
| `meteor node -e "<code>"` | Execute a line of JavaScript |
| `meteor node --version` | Show Node.js version |
### Examples
```bash
# Start an interactive REPL
meteor node
# Execute inline JavaScript
meteor node -e "console.log(process.versions)"
# Run a script with arguments
meteor node scripts/migrate.js --force
# Check installed Node.js version
meteor node --version
```
::: details Running a Simple Script
Create `hello.js`:
```js
console.log('Hello from Node.js version', process.version);
console.log('Arguments:', process.argv.slice(2));
```
Run it:
```bash
meteor node hello.js arg1 arg2
```
:::

View File

@@ -1,4 +1,4 @@
## v3.3.0, 2025-05-28
## v3.3.0, 2025-06-11
### Highlights
@@ -17,7 +17,7 @@
All Merged PRs@[GitHub PRs 3.3](https://github.com/meteor/meteor/pulls?q=is%3Apr+is%3Amerged+base%3Arelease-3.3)
React Packages Changelog: [react-meteor-data@4.0.0-beta.0](https://github.com/meteor/react-packages/blob/fb73eeb89ff59664a7a01769fa1c2c880e72a3e5/packages/react-meteor-data/CHANGELOG.md#v400-beta0-xxx)
React Packages Changelog: [react-meteor-data@4.0.0](https://github.com/meteor/react-packages/tree/master/packages/react-meteor-data/CHANGELOG.md#v400-2025-06-11)
#### Breaking Changes
@@ -26,7 +26,7 @@ React Packages Changelog: [react-meteor-data@4.0.0-beta.0](https://github.com/me
- Set `METEOR_WATCH_FORCE_POLLING=true` to enable polling.
- Set `METEOR_WATCH_POLLING_INTERVAL_MS=1000` to adjust the interval.
- `react-meteor-data@4.0.0-beta.0`
- `react-meteor-data@4.0.0`
- Independent from the core, only applies if upgraded manually.
- useFind describes no deps by default [PR#431](https://github.com/meteor/react-packages/pull/431)
@@ -41,13 +41,13 @@ React Packages Changelog: [react-meteor-data@4.0.0-beta.0](https://github.com/me
Please run the following command to update your project:
```bash
meteor update --release 3.3-beta.1
meteor update --release 3.3
```
To apply react-meteor-data changes:
```bash
meteor add react-meteor-data@4.0.0-beta.0
meteor add react-meteor-data@4.0.0
```
**Add this to your `package.json` to enable the new modern build stack:**
@@ -60,26 +60,34 @@ meteor add react-meteor-data@4.0.0-beta.0
> These settings are on by default for new apps.
On activate `modern` your app will be updated to use SWC transpiler. It will automatically fallback to Babel if your code can't be transpiled wit SWC.
Check the docs for help with the SWC migration, especially if your project uses many Babel plugins.
[Modern Transpiler: SWC docs](https://docs.meteor.com/about/modern-build-stack/transpiler-swc.html)
If you find any issues, please report them to the [Meteor issues tracker](https://github.com/meteor/meteor).
#### Bumped Meteor Packages
- accounts-base@3.1.1-rc330.0
- accounts-password@3.2.0-rc330.0
- autoupdate@2.0.1-rc330.0
- babel-compiler@7.12.0-rc330.0
- boilerplate-generator@2.0.1-rc330.0
- ddp-client@3.1.1-rc330.0
- ecmascript@0.16.11-rc330.0
- ejson@1.1.5-rc330.0
- meteor@2.1.1-rc330.0
- minifier-js@3.0.2-rc330.0
- modern-browsers@0.2.2-rc330.0
- mongo@2.1.2-rc330.0
- server-render@0.4.3-rc330.0
- socket-stream-client@0.6.1-rc330.0
- standard-minifier-js@3.1.0-rc330.0
- typescript@5.6.4-rc330.0
- webapp@2.0.7-rc330.0
- meteor-tool@3.3.0-rc.0
- accounts-base@3.1.1
- accounts-password@3.2.0
- autoupdate@2.0.1
- babel-compiler@7.12.0
- boilerplate-generator@2.0.1
- ddp-client@3.1.1
- ecmascript@0.16.11
- ejson@1.1.5
- meteor@2.1.1
- minifier-js@3.0.2
- modern-browsers@0.2.2
- mongo@2.1.2
- server-render@0.4.3
- socket-stream-client@0.6.1
- standard-minifier-js@3.1.0
- typescript@5.6.4
- webapp@2.0.7
- meteor-tool@3.3.0
#### Bumped NPM Packages

View File

@@ -10,7 +10,7 @@ This is a complete history of changes for Meteor releases.
[//]: # (go to meteor/docs/generators/changelog/docs)
## v3.3.0, 2025-05-28
## v3.3.0, 2025-06-11
### Highlights
@@ -29,16 +29,16 @@ This is a complete history of changes for Meteor releases.
All Merged PRs@[GitHub PRs 3.3](https://github.com/meteor/meteor/pulls?q=is%3Apr+is%3Amerged+base%3Arelease-3.3)
React Packages Changelog: [react-meteor-data@4.0.0-beta.0](https://github.com/meteor/react-packages/blob/fb73eeb89ff59664a7a01769fa1c2c880e72a3e5/packages/react-meteor-data/CHANGELOG.md#v400-beta0-xxx)
React Packages Changelog: [react-meteor-data@4.0.0](https://github.com/meteor/react-packages/tree/master/packages/react-meteor-data/CHANGELOG.md#v400-2025-06-11)
#### Breaking Changes
- File watching strategy switched to `@parcel/watcher`
- Most setups should be fine, but if issues appear, like when using WSL with host, volumes, or remote setups—switch to polling.
- Set `METEOR_WATCH_FORCE_POLLING=true` to enable polling.
- Set `METEOR_WATCH_POLLING_INTERVAL_MS=1000` to adjust the interval.
- Most setups should be fine, but if issues appear, like when using WSL with host, volumes, or remote setups—switch to polling.
- Set `METEOR_WATCH_FORCE_POLLING=true` to enable polling.
- Set `METEOR_WATCH_POLLING_INTERVAL_MS=1000` to adjust the interval.
- `react-meteor-data@4.0.0-beta.0`
- `react-meteor-data@4.0.0`
- Independent from the core, only applies if upgraded manually.
- useFind describes no deps by default [PR#431](https://github.com/meteor/react-packages/pull/431)
@@ -53,13 +53,13 @@ React Packages Changelog: [react-meteor-data@4.0.0-beta.0](https://github.com/me
Please run the following command to update your project:
```bash
meteor update --release 3.3-beta.1
meteor update --release 3.3
```
To apply react-meteor-data changes:
```bash
meteor add react-meteor-data@4.0.0-beta.0
meteor add react-meteor-data@4.0.0
```
**Add this to your `package.json` to enable the new modern build stack:**
@@ -72,26 +72,34 @@ meteor add react-meteor-data@4.0.0-beta.0
> These settings are on by default for new apps.
On activate `modern` your app will be updated to use SWC transpiler. It will automatically fallback to Babel if your code can't be transpiled wit SWC.
Check the docs for help with the SWC migration, especially if your project uses many Babel plugins.
[Modern Transpiler: SWC docs](https://docs.meteor.com/about/modern-build-stack/transpiler-swc.html)
If you find any issues, please report them to the [Meteor issues tracker](https://github.com/meteor/meteor).
#### Bumped Meteor Packages
- accounts-base@3.1.1-rc330.0
- accounts-password@3.2.0-rc330.0
- autoupdate@2.0.1-rc330.0
- babel-compiler@7.12.0-rc330.0
- boilerplate-generator@2.0.1-rc330.0
- ddp-client@3.1.1-rc330.0
- ecmascript@0.16.11-rc330.0
- ejson@1.1.5-rc330.0
- meteor@2.1.1-rc330.0
- minifier-js@3.0.2-rc330.0
- modern-browsers@0.2.2-rc330.0
- mongo@2.1.2-rc330.0
- server-render@0.4.3-rc330.0
- socket-stream-client@0.6.1-rc330.0
- standard-minifier-js@3.1.0-rc330.0
- typescript@5.6.4-rc330.0
- webapp@2.0.7-rc330.0
- meteor-tool@3.3.0-rc.0
- accounts-base@3.1.1
- accounts-password@3.2.0
- autoupdate@2.0.1
- babel-compiler@7.12.0
- boilerplate-generator@2.0.1
- ddp-client@3.1.1
- ecmascript@0.16.11
- ejson@1.1.5
- meteor@2.1.1
- minifier-js@3.0.2
- modern-browsers@0.2.2
- mongo@2.1.2
- server-render@0.4.3
- socket-stream-client@0.6.1
- standard-minifier-js@3.1.0
- typescript@5.6.4
- webapp@2.0.7
- meteor-tool@3.3.0
#### Bumped NPM Packages
@@ -101,9 +109,9 @@ meteor add react-meteor-data@4.0.0-beta.0
✨✨✨
- [@nachocodoner](https://github.com/nachocodoner)
- [@nachocodoner](https://github.com/nachocodoner)
- [@italojs](https://github.com/italojs)
- [@Grubba27](https://github.com/Grubba27)
- [@Grubba27](https://github.com/Grubba27)
- [@zodern](https://github.com/zodern)
- [@9Morello](https://github.com/9Morello)
- [@welkinwong](https://github.com/welkinwong)
@@ -113,7 +121,7 @@ meteor add react-meteor-data@4.0.0-beta.0
- [@ericm546](https://github.com/ericm546)
- [@StorytellerCZ](https://github.com/StorytellerCZ)
✨✨✨
✨✨✨
## v3.2.2, 2025-05-02

View File

@@ -1,5 +1,5 @@
---
meteor_version: 3.1.0
meteor_version: 3.3
node_version: 22.16.0
npm_version: 10.9.2
---