Python 3.7 beta previews

in python •  7 years ago 

                                                  python.png


You can download and run Python 3.7.0b1, the first of four planned beta release previews:
https://www.python.org/downloads/release/python-370b1/

The new features in Python 3.7 compared to 3.6:
https://docs.python.org/dev/whatsnew/3.7.html

Discussion on the current stable release:
https://www.sololearn.com/Discuss/942832/?ref=app


                                         Some new features of Python 3.7

New @dataclass decorator makes instantiating data classes easier in 3.7

@dataclass
class User():
 name: str
 user_id: int
 just_joined: bool=True

Instead of the common style:

class User():
def __init(self, name, user_id, just_joined=True):
 self.name = name
 self.id = user_id
 self.just_joined = just_joined


PEP 538: Legacy C Locale Coercion:
   Python 3 series has been determining a sensible default strategy for handling the “7-bit ASCII” text encoding assumption currently implied by the use of the default C locale on non-Windows platforms. On documentation


New Development Mode: -X dev:
   Add a new “development mode”: -X dev command line option and PYTHONDEVMODE environment variable to enable CPython’s “development mode”, introducing additional runtime checks which are too expensive to be enabled by default. See -X dev documentation for the effects of the development mode. On documentation


PEP 564: Add new time functions with nanosecond resolution.
   With this they added six new “nanosecond” variants of existing functions to the time module: On documentation

  • time.clock_gettime_ns()
  • time.clock_settime_ns()
  • time.monotonic_ns()
  • time.perf_counter_ns()
  • time.process_time_ns()
  • time.time_ns()

Changes in Python behavior:
   PEP 479 is enabled for all code in Python 3.7, meaning that StopIteration exceptions raised directly or indirectly in coroutines and generators are transformed into RuntimeError exceptions. On documentation

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE STEEM!
Sort Order:  

Hey @raqux, great post! I enjoyed your content. Keep up the good work! It's always nice to see good content here on Steemit! Cheers :)

Thank you. I will

Thank you

Congratulations @raqux! You received a personal award!

Happy Birthday! - You are on the Steem blockchain for 1 year!

You can view your badges on your Steem Board and compare to others on the Steem Ranking

Do not miss the last post from @steemitboard:

3 years on Steem - The distribution of commemorative badges has begun!
Happy Birthday! The Steem blockchain is running for 3 years.
Vote for @Steemitboard as a witness to get one more award and increased upvotes!