From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on starla X-Spam-Level: X-Spam-Status: No, score=0.1 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_BL_SPAMCOP_NET,SPF_HELO_PASS, SPF_PASS autolearn=no autolearn_force=no version=3.4.6 Received: from nue.mailmanlists.eu (nue.mailmanlists.eu [94.130.110.93]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 8ED661F5CB for ; Thu, 26 Sep 2024 10:27:20 +0000 (UTC) Authentication-Results: dcvr.yhbt.net; dkim=pass (1024-bit key; unprotected) header.d=ml.ruby-lang.org header.i=@ml.ruby-lang.org header.a=rsa-sha256 header.s=mail header.b=nwIQoEP+; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=ruby-lang.org header.i=@ruby-lang.org header.a=rsa-sha256 header.s=s1 header.b=c+uh11Fa; dkim-atps=neutral DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ml.ruby-lang.org; s=mail; t=1727346407; bh=HVA3AdZlBCoVC8lYILG+ysCIW7yffVRZk2POTHeF/K8=; h=Date:References:To:Reply-To:Subject:List-Id:List-Archive: List-Help:List-Owner:List-Post:List-Subscribe:List-Unsubscribe: From:Cc:From; b=nwIQoEP+jieskh1HYep/6ldKr8iuiwFIStBWeAXypGPTUJ15NmTv6/SRxYuDPOr7v J2vpau5hgi1Qk/twKug6+J9/pvOsONq5rAoctoyK8Q7AqFj9SlNfJ25sFEqANMgB4Q lU3qh5Yb4JOvFc8t1n9flIZ5Q/vU7KCXXy2EZPXU= Received: from nue.mailmanlists.eu (localhost [IPv6:::1]) by nue.mailmanlists.eu (Postfix) with ESMTP id A12BA43EA9 for ; Thu, 26 Sep 2024 10:26:47 +0000 (UTC) Authentication-Results: nue.mailmanlists.eu; dkim=pass (2048-bit key; unprotected) header.d=ruby-lang.org header.i=@ruby-lang.org header.a=rsa-sha256 header.s=s1 header.b=c+uh11Fa; dkim-atps=neutral Received: from s.wrqvtbkv.outbound-mail.sendgrid.net (s.wrqvtbkv.outbound-mail.sendgrid.net [149.72.123.24]) by nue.mailmanlists.eu (Postfix) with ESMTPS id D684D43D6D for ; Thu, 26 Sep 2024 10:26:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ruby-lang.org; h=from:references:subject:mime-version:content-type: content-transfer-encoding:list-id:to:cc:content-type:from:subject:to; s=s1; bh=5otFvap9z2iel/X0sHMxjR3fQBJ+GTBczfmxtODXnfA=; b=c+uh11FaQiThYHqn+Ee1IVgOe5393NdHW5acDU8BaTkX6hGABcvGl1MMFqf+f2kUlxPP T8FCf7xK4Bx9RXQc1I31y4XQvuVR2xWRxlQpzMQwmMLTbgBH+k62UPyY6pf4cPidtCpaG7 EAdWT9dOLwR0/U68ipugP/bZShDjdIqp0KNy0iDfuJefmhkHj2yGmQZ1iTDDw7l85RjMkA 5mjN7qtlQLabj5tID6LdVNk8TYQrHYrUWJ6wyAVzvTsKVC2zp5JzRrDHaFr3z3F9wTHZWe eOmieIIuAGBqpUN8dtolZ1ly+SZhTdKUaKM20isX3bvgQ0oPPENJ6b+/MMnrXygw== Received: by recvd-76b48cd7f5-qvck4 with SMTP id recvd-76b48cd7f5-qvck4-1-66F536DC-8 2024-09-26 10:26:36.880148296 +0000 UTC m=+1182497.296689351 Received: from herokuapp.com (unknown) by geopod-ismtpd-19 (SG) with ESMTP id A8DZiZo0QSuaNfsitAYosw for ; Thu, 26 Sep 2024 10:26:36.869 +0000 (UTC) Date: Thu, 26 Sep 2024 10:26:36 +0000 (UTC) Message-ID: References: Mime-Version: 1.0 X-Redmine-Project: ruby-master X-Redmine-Issue-Tracker: Bug X-Redmine-Issue-Id: 20714 X-Redmine-Issue-Author: Earlopain X-Redmine-Issue-Assignee: hsbt X-Redmine-Issue-Priority: Normal X-Redmine-Sender: deivid X-Mailer: Redmine X-Redmine-Host: bugs.ruby-lang.org X-Redmine-Site: Ruby Issue Tracking System X-Auto-Response-Suppress: All Auto-Submitted: auto-generated X-Redmine-MailingListIntegration-Message-Ids: 95932 X-SG-EID: =?us-ascii?Q?u001=2EylzRTT3GG24XITUBroBe7Vu=2FcLwq5cTmVTMQhzlQkRs17HzFdvuwXQJs4?= =?us-ascii?Q?1gUmHQW7OnijYNkHuUORvf3qUg8TsxVxh3oro35?= =?us-ascii?Q?O33UBhH0LAYaCV7XZNBNRwQZC6q6CMFvVzGoMkk?= =?us-ascii?Q?xc1=2Fbg8=2FXF1x4F7ncS0w8iAU8UktmzjJa617Yip?= =?us-ascii?Q?Nr+gJAaGflAyCxwEy4OsgRcu7E3Eit6kLIBIeBq?= =?us-ascii?Q?LhHc2ycGs6SPYxV6GG5cYQuxQD+VIYEo5Cjo3E1?= =?us-ascii?Q?+E4c?= To: ruby-core@ml.ruby-lang.org X-Entity-ID: u001.I8uzylDtAfgbeCOeLBYDww== Message-ID-Hash: UGHAJLC25S6VINMANH5SRJ3LSGFLR5VQ X-Message-ID-Hash: UGHAJLC25S6VINMANH5SRJ3LSGFLR5VQ X-MailFrom: bounces+313651-b711-ruby-core=ml.ruby-lang.org@em5188.ruby-lang.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.9 Precedence: list Reply-To: Ruby developers Subject: [ruby-core:119297] [Ruby master Bug#20714] Handle optional dependencies in `bundled_gems.rb` List-Id: Ruby developers Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: deivid via ruby-core Cc: deivid Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Issue #20714 has been updated by deivid (David Rodr=EDguez). @hsbt found an issue with the simpler approach. It will no longer show info= rmation about bundled gem extraction "after the fact". So, it for example k= eeps warning that `csv` will no longer be part of Ruby starting from Ruby 3= .4 when using Ruby 3.3, but once users upgrade to Ruby 3.4, they will start= getting an standard load error instead of the current message "csv is not = part of the default gems starting from Ruby 3.4.0". I _think_ the more complicated approach proposed here does not have that is= sue, but it does happen the thread safety concerns raised. I think the issue found by @hsbt may be an acceptable compromise, but I'm n= ot sure. ---------------------------------------- Bug #20714: Handle optional dependencies in `bundled_gems.rb` https://bugs.ruby-lang.org/issues/20714#change-109909 * Author: Earlopain (A S) * Status: Assigned * Assignee: hsbt (Hiroshi SHIBATA) * ruby -v: 3.3.5 * Backport: 3.1: UNKNOWN, 3.2: UNKNOWN, 3.3: UNKNOWN ---------------------------------------- I've encountered a few places around bundled gems where the library doesn't= care if the gem is available, but will still provide some functionallity i= f it is. The way to accomplish that right now seems to be by setting `$VERBOSE =3D n= il` and resetting it later again to not bother the user with the warning ab= out the gem. However, this has the effect of silencing the warning about ot= her gems as well, that may not be prepared about the bundling.=20 >>From `ruby/reline` for example: https://github.com/ruby/reline/blob/c90f08f= 7e308d2f1cdd7cfaf9939fe45ce546fd2/lib/reline/terminfo.rb#L1-L15 Or the `logging` gem: https://github.com/TwP/logging/blob/df41715364f7eb8c6= 5098cd3c3316677ef1f3784/lib/logging.rb#L9-L15 I propose to simply delay the warning to the next require. GitHub PR at https://github.com/ruby/ruby/pull/11545 --=20 https://bugs.ruby-lang.org/ ______________________________________________ ruby-core mailing list -- ruby-core@ml.ruby-lang.org To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org ruby-core info -- https://ml.ruby-lang.org/mailman3/lists/ruby-core.ml.rub= y-lang.org/