Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
how to do a bytes f-string?
#5
my suggestion is for bytes formatting getting a non-bytes unicode character to raise an exception.

the other thing i have a need for is a non-literal f-string. that is, a way to process a regular string that has contents that would be work in a literal f-string, but do it with that non-literal string value.
Tradition is peer pressure from dead people

What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
Reply


Messages In This Thread
how to do a bytes f-string? - by Skaperen - Jul-15-2020, 05:34 AM
RE: how to do a bytes f-string? - by menator01 - Jul-15-2020, 07:16 AM
RE: how to do a bytes f-string? - by Skaperen - Jul-16-2020, 02:47 AM
RE: how to do a bytes f-string? - by bowlofred - Jul-16-2020, 04:19 AM
RE: how to do a bytes f-string? - by Skaperen - Jul-16-2020, 11:25 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Error on import: SyntaxError: source code string cannot contain null bytes kirkwilliams2049 7 7,679 Aug-03-2023, 06:00 PM
Last Post: Gribouillis
  bytes f-string ? Skaperen 5 4,463 Jun-10-2021, 10:21 PM
Last Post: Gribouillis
  TypeError: int() argument must be a string, a bytes-like object or a number, not 'Non Anldra12 2 5,355 May-02-2021, 03:45 PM
Last Post: Anldra12
  Why, TypeError: expected string or bytes-like object ? JohnnyCoffee 3 18,742 May-08-2020, 04:26 AM
Last Post: bowlofred
  printing a bytes string Skaperen 2 2,453 Jul-21-2019, 03:42 AM
Last Post: Skaperen
  replace bytes with other byte or bytes BigOldArt 1 10,793 Feb-02-2019, 11:00 PM
Last Post: snippsat
  portion of the bytes to string ricardons 1 2,673 Mar-02-2018, 12:00 PM
Last Post: Gribouillis

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020