On Sun, 7 Mar 2021 20:38:30 -0800
Dan Stromberg wrote:
> I sometimes do things like:
>
> try:
> import rtoml as toml
> except ImportError:
> import toml
>
Also a possibility. Thanks.
> ...but I don't like it very much, because it tends to confuse static
> analyzers like pyflakes and p
On 06/03/2021 12:00, Manfred Lotz wrote:
Let us say I have a package which reads a TOML file.
I want to give the user of my package the choice to decide if he wants
to use the toml, tomlkit or rtoml package.
So, in case the user chose to use rtoml then there should be an import
only for rtoml,
On 2021-03-07, Manfred Lotz wrote:
> On Sat, 6 Mar 2021 15:40:41 - (UTC)
> Grant Edwards wrote:
>
>> On 2021-03-06, Manfred Lotz wrote:
>> > Let us say I have a package which reads a TOML file.
>> >
>> > I want to give the user of my package the choice to decide if he
>> > wants to use the
I sometimes do things like:
try:
import rtoml as toml
except ImportError:
import toml
...but I don't like it very much, because it tends to confuse static
analyzers like pyflakes and pylint. Maybe mypy will deal with it better?
Not sure yet.
On Sat, Mar 6, 2021 at 3:05 AM Manfred Lotz
On Sat, 6 Mar 2021 15:40:41 - (UTC)
Grant Edwards wrote:
> On 2021-03-06, Manfred Lotz wrote:
> > Let us say I have a package which reads a TOML file.
> >
> > I want to give the user of my package the choice to decide if he
> > wants to use the toml, tomlkit or rtoml package.
>
> Why wo
On 2021-03-06, Manfred Lotz wrote:
> Let us say I have a package which reads a TOML file.
>
> I want to give the user of my package the choice to decide if he wants
> to use the toml, tomlkit or rtoml package.
Why would the user choose one over the other? Does the user get
different functions/
On Sat, 6 Mar 2021 14:06:27 +0100
Peter Otten <__pete...@web.de> wrote:
> On 06/03/2021 12:43, Manfred Lotz wrote:
> > On Sat, 6 Mar 2021 12:00:33 +0100
> > Manfred Lotz wrote:
> >
> >> Let us say I have a package which reads a TOML file.
> >>
> >> I want to give the user of my package the cho
On 06/03/2021 12:43, Manfred Lotz wrote:
On Sat, 6 Mar 2021 12:00:33 +0100
Manfred Lotz wrote:
Let us say I have a package which reads a TOML file.
I want to give the user of my package the choice to decide if he wants
to use the toml, tomlkit or rtoml package.
So, in case the user chose to
On Sat, 6 Mar 2021 12:00:33 +0100
Manfred Lotz wrote:
> Let us say I have a package which reads a TOML file.
>
> I want to give the user of my package the choice to decide if he wants
> to use the toml, tomlkit or rtoml package.
>
> So, in case the user chose to use rtoml then there should be
Let us say I have a package which reads a TOML file.
I want to give the user of my package the choice to decide if he wants
to use the toml, tomlkit or rtoml package.
So, in case the user chose to use rtoml then there should be an import
only for rtoml, aso.
How could I achieve this?
--
Than
10 matches
Mail list logo