Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ---------------------------------------------------------------------------
- TypeError Traceback (most recent call last)
- Cell In[3], line 1
- ----> 1 get_ipython().run_cell_magic('manim', '-qm HelloCircle', '\nclass HelloCircle(Scene):\n def construct(self):\n # blue_circle = Circle(color=BLUE, fill_opacity=0.5)\n # We can also create a "plain" circle and add the desired attributes via set methods:\n circle = Circle()\n blue_circle = circle.set_color(BLUE).set_opacity(0.5)\n \n label = Text("A wild circle appears!")\n label.next_to(blue_circle, DOWN, buff=0.5)\n \n self.play(Create(blue_circle), Write(label))\n self.wait()\n')
- File /usr/local/lib/python3.11/site-packages/IPython/core/interactiveshell.py:2541, in InteractiveShell.run_cell_magic(self, magic_name, line, cell)
- 2539 with self.builtin_trap:
- 2540 args = (magic_arg_s, cell)
- -> 2541 result = fn(*args, **kwargs)
- 2543 # The code below prevents the output from being displayed
- 2544 # when using magics with decorator @output_can_be_silenced
- 2545 # when the last Python token in the expression is a ';'.
- 2546 if getattr(fn, magic.MAGIC_OUTPUT_CAN_BE_SILENCED, False):
- File /usr/local/lib/python3.11/site-packages/manim/utils/ipython_magic.py:129, in ManimMagic.manim(self, line, cell, local_ns)
- 126 return
- 128 modified_args = self.add_additional_args(args)
- --> 129 args = main(modified_args, standalone_mode=False, prog_name="manim")
- 130 with tempconfig(local_ns.get("config", {})):
- 131 config.digest_args(args)
- File /usr/local/lib/python3.11/site-packages/click/core.py:1157, in BaseCommand.__call__(self, *args, **kwargs)
- 1155 def __call__(self, *args: t.Any, **kwargs: t.Any) -> t.Any:
- 1156 """Alias for :meth:`main`."""
- -> 1157 return self.main(*args, **kwargs)
- File /usr/local/lib/python3.11/site-packages/click/core.py:1078, in BaseCommand.main(self, args, prog_name, complete_var, standalone_mode, windows_expand_args, **extra)
- 1076 try:
- 1077 with self.make_context(prog_name, args, **extra) as ctx:
- -> 1078 rv = self.invoke(ctx)
- 1079 if not standalone_mode:
- 1080 return rv
- File /usr/local/lib/python3.11/site-packages/click/core.py:1686, in MultiCommand.invoke(self, ctx)
- 1684 ctx.invoked_subcommand = cmd_name
- 1685 super().invoke(ctx)
- -> 1686 sub_ctx = cmd.make_context(cmd_name, args, parent=ctx)
- 1687 with sub_ctx:
- 1688 return _process_result(sub_ctx.command.invoke(sub_ctx))
- File /usr/local/lib/python3.11/site-packages/click/core.py:943, in BaseCommand.make_context(self, info_name, args, parent, **extra)
- 938 ctx = self.context_class(
- 939 self, info_name=info_name, parent=parent, **extra # type: ignore
- 940 )
- 942 with ctx.scope(cleanup=False):
- --> 943 self.parse_args(ctx, args)
- 944 return ctx
- File /usr/local/lib/python3.11/site-packages/cloup/constraints/_support.py:183, in ConstraintMixin.parse_args(self, ctx, args)
- 180 for constr in self.all_constraints:
- 181 constr.check_consistency()
- --> 183 args = super().parse_args(ctx, args) # type: ignore
- 185 # Skip constraints checking if the user wants to see --help for subcommand
- 186 # or if resilient parsing is enabled
- 187 should_show_subcommand_help = isinstance(ctx.command, click.Group) and any(
- 188 help_flag in args for help_flag in ctx.help_option_names
- 189 )
- File /usr/local/lib/python3.11/site-packages/click/core.py:1408, in Command.parse_args(self, ctx, args)
- 1405 opts, args, param_order = parser.parse_args(args=args)
- 1407 for param in iter_params_for_processing(param_order, self.get_params(ctx)):
- -> 1408 value, args = param.handle_parse_result(ctx, opts, args)
- 1410 if args and not ctx.allow_extra_args and not ctx.resilient_parsing:
- 1411 ctx.fail(
- 1412 ngettext(
- 1413 "Got unexpected extra argument ({args})",
- (...)
- 1416 ).format(args=" ".join(map(str, args)))
- 1417 )
- File /usr/local/lib/python3.11/site-packages/click/core.py:2400, in Parameter.handle_parse_result(self, ctx, opts, args)
- 2397 ctx.set_parameter_source(self.name, source) # type: ignore
- 2399 try:
- -> 2400 value = self.process_value(ctx, value)
- 2401 except Exception:
- 2402 if not ctx.resilient_parsing:
- File /usr/local/lib/python3.11/site-packages/click/core.py:2356, in Parameter.process_value(self, ctx, value)
- 2355 def process_value(self, ctx: Context, value: t.Any) -> t.Any:
- -> 2356 value = self.type_cast_value(ctx, value)
- 2358 if self.required and self.value_is_missing(value):
- 2359 raise MissingParameter(ctx=ctx, param=self)
- File /usr/local/lib/python3.11/site-packages/click/core.py:2344, in Parameter.type_cast_value(self, ctx, value)
- 2341 if self.multiple:
- 2342 return tuple(convert(x) for x in check_iter(value))
- -> 2344 return convert(value)
- File /usr/local/lib/python3.11/site-packages/click/core.py:2316, in Parameter.type_cast_value.<locals>.convert(value)
- 2315 def convert(value: t.Any) -> t.Any:
- -> 2316 return self.type(value, param=self, ctx=ctx)
- File /usr/local/lib/python3.11/site-packages/click/types.py:83, in ParamType.__call__(self, value, param, ctx)
- 76 def __call__(
- 77 self,
- 78 value: t.Any,
- 79 param: t.Optional["Parameter"] = None,
- 80 ctx: t.Optional["Context"] = None,
- 81 ) -> t.Any:
- 82 if value is not None:
- ---> 83 return self.convert(value, param, ctx)
- File /usr/local/lib/python3.11/site-packages/click/types.py:300, in Choice.convert(self, value, param, ctx)
- 293 return normed_choices[normed_value]
- 295 choices_str = ", ".join(map(repr, self.choices))
- 296 self.fail(
- 297 ngettext(
- 298 "{value!r} is not {choice}.",
- 299 "{value!r} is not one of {choices}.",
- --> 300 len(self.choices),
- 301 ).format(value=value, choice=choices_str, choices=choices_str),
- 302 param,
- 303 ctx,
- 304 )
- TypeError: object of type 'list_reverseiterator' has no len()
Add Comment
Please, Sign In to add comment