Passing lambdas into child models allow them to execute arbitrary parent model code
まだ誰も着手していません。
評価
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 初心者へのやさしさ
- 25/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 停滞
- 技術スタック
- scala
調査の方向性
ソースファイル、テスト、エントリーポイントは指定されていません。まず、複数の子モデルを使ってリンク先の匿名プロシージャの例を再現し、プロシージャがどのように渡され、並列実行がどのように調整されているかを調べます。選択した安全性ポリシーが強制され、回帰テストでカバーされれば完了です。
索引モデルが issue の本文から書いたものです。
説明
See https://stackoverflow.com/a/54369364/145080.
That's a pretty awesome use, but it will also break bad when running multiple children simultaneously. Child models, by default, run in parallel, which means there's no way to control what order they will run code in (even with random-seed). Normally, this is fine, since child models can't directly affect each other. But passing procedures in mean order matters, so the results of the above code will be unpredictable, even if you use random-seed. Worse, child models don't synchronize on the same object (otherwise parallelism would be pointless), and global variables are not effectively marked volatile, if two child models run
set foo foo + 1
in the parent, they may both read the un-updated foo before the other hasn't finished its update, resulting in foo being incremented once, not twice.
The other reason why this isn't supposed to work is more philosophical. All inter-level logic is supposed to live in the parent. Allowing any child to talk directly to any other child results in code that is very difficult to reason about and debug.
The safest option here is to just block anonymous procedures from being passed around (as I thought they were). Another option, which addresses the technical concern, but not the philosophical, is to disable parallelism if anonymous procedures are being passed around.
- 主要言語
- Scala
- スター
- 20
- フォーク
- 8
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
NetLogo/LevelSpace のほかの issue
-
enhancement
難易度 4/5 3〜5日 初心者へのやさしさ 55/100
NetLogo/LevelSpace#151 · リアクション 1 件 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
NetLogo/LevelSpace#146 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 45/100
NetLogo/LevelSpace#141 ·
-
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
NetLogo/LevelSpace#134 · コメント 2 件 ·
-
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
NetLogo/LevelSpace#132 · コメント 3 件 ·
NetLogo/LevelSpace の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
メンテナーはふだん 1 日以内に返信
-
bug triage
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
propensive/soundness#2266 ·
メンテナーはふだん 1 日以内に返信
-
Module: Form Builder
難易度 2/5 1〜3時間 初心者へのやさしさ 66/100
orbeon/orbeon-forms#7943 ·
メンテナーはふだん 2 日以内に返信
-
bbb-web: concurrent joins lose RegisterUserReqMsg (HashMap race in Meeting.userCustomData)対応中かも @Tainan404 が 1 日前に担当しました。 オープンmodule: core
難易度 2/5 1〜3時間 初心者へのやさしさ 77/100
bigbluebutton/bigbluebutton#26028 · コメント 2 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信