Python uses mvc to design web application athletemodel.py does not display data

Today, I continue to study python, and when I see a web application designed with mvc, copy athletemodel.py and click save. Click Run (press F5)

At this time, I reopened an IDLE, I clicked close, and I continued to operate in the original IDLE. I wrote dir() first, and the display result was normal, but the downward operation was abnormal.

>>> dir()

['AthleteList', '__annotations__', '__builtins__', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__spec__', 'athl', 'athletemodel', 'athlist', 'data', 'data11', 'get_coach_data', 'get_from_store', 'pickle', 'put_to_store', 'the_files']

>>> from athletemodel import put_to_store

>>> the_files = ['sarah.txt', 'julie.txt', 'mikey.txt', 'james.txt']

>>> data11 = put_to_store(the_files)

>>> data11

Nothing is displayed below~~~Why?

Check google, find Du Niang, the code is word-for-word, and finally after pressing F5 to run, I wrote the above code again in the new IDLE that was opened, and the final result appeared! Is it because of refresh compilation issues?

Python 3.6.2 (v3.6.2:5fd33b5, Jul  8 2017, 04:57:36) [MSC v.1900 64 bit (AMD64)] on win32

Type "copyright", "credits" or "license()" for more information.

>>> 

==================== RESTART: C:\Python36\athletemodel.py ====================

>>> dir()

['AthleteList', '__annotations__', '__builtins__', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__spec__', 'get_coach_data', 'get_from_store', 'pickle', 'put_to_store']

>>> the_files = ['sarah.txt', 'julie.txt', 'mikey.txt', 'james.txt']

>>> data11 = put_to_store(the_files)

>>> data11

{'Sarah Sweeney': ['2:58', '2.58', '2:39', '2-25', '2-55', '2:54', '2.18', '2:55', '2:55', '2:22', '2-21', '2.22'], 'Julie Jones': ['2.59', '2.11', '2:11', '2:23', '3-10', '2-23', '3:10', '3.21', '3-21', '3.01', '3.02', '2:59'], 'Mikey McManus': ['2:22', '3.01', '3:01', '3.02', '3:02', '3.02', '3:22', '2.49', '2:38', '2:40', '2.22', '2-31'], 'James Lee': ['2-34', '3:21', '2.34', '2.45', '3.01', '2:01', '2:01', '3:10', '2-22', '2-01', '2.01', '2:16']}

>>> 

 

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326768939&siteId=291194637