input: from typing import Dict, List
  
  def blockchain_system(data_list: List[Dict[str, str]]) -> str:
      """
      Implement a basic blockchain system in Python. Given a list of dictionaries containing 'timestamp' and 'data',
      create a blockchain with blocks containing these data. Each block should be linked with a previous block via hash.
      The function should return the blockchain in a JSON format.
      
      Example:
      for blockchain_system([{'timestamp': '2023-01-01', 'data': 'BlockData 1'}, {'timestamp': '2023-01-02', 'data': 'BlockData 2'}])
      
      Output:
      '[
        {
          "index": 0,
          "timestamp": "2023-01-01",
          "data": "BlockData 1",
          "previous_hash": null,
          "hash": "some_hash_value"
        },
        {
          "index": 1,
          "timestamp": "2023-01-02",
          "data": "BlockData 2",
          "previous_hash": "some_previous_hash_value",
          "hash": "some_other_hash_value"
        }
      ]'
      """
output:     
      import hashlib
      import json
  
      def calculate_hash(block):
          block_string = json.dumps(block, sort_keys=True).encode()
          return hashlib.sha256(block_string).hexdigest()
  
      blockchain = []
      previous_hash = None
  
      for index, data in enumerate(data_list):
          block = {
              "index": index,
              "timestamp": data['timestamp'],
              "data": data['data'],
              "previous_hash": previous_hash
          }
          block['hash'] = calculate_hash(block)
          previous_hash = block['hash']
          blockchain.append(block)
  
      return json.dumps(blockchain, indent=2)
  